From 30722179708ddc2a53f433f07ecbb00ad5c6046a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nuno=20G=C3=B3is?= Date: Fri, 6 Dec 2024 11:21:00 +0000 Subject: [PATCH] refactor: remove unused, fix client_api tests --- server/src/client_api.rs | 1 - server/src/http/broadcaster.rs | 1 - server/src/http/feature_refresher.rs | 1 - server/src/http/unleash_client.rs | 1 - 4 files changed, 4 deletions(-) diff --git a/server/src/client_api.rs b/server/src/client_api.rs index c646d92e..348e7bea 100644 --- a/server/src/client_api.rs +++ b/server/src/client_api.rs @@ -338,7 +338,6 @@ pub fn configure_experimental_post_features( mod tests { use crate::http::broadcaster::Broadcaster; - use crate::internal_backstage::features; use crate::metrics::client_metrics::{ApplicationKey, MetricsBatch, MetricsKey}; use crate::types::{TokenType, TokenValidationStatus}; use std::collections::HashMap; diff --git a/server/src/http/broadcaster.rs b/server/src/http/broadcaster.rs index 16c1d52c..c09cd817 100644 --- a/server/src/http/broadcaster.rs +++ b/server/src/http/broadcaster.rs @@ -84,7 +84,6 @@ impl Broadcaster { /// Removes all non-responsive clients from broadcast list. async fn remove_stale_clients(&self) { - //let clients = self.inner.lock().clients.clone(); let active_connections = self.inner.lock().active_connections.clone(); for (_query, mut group) in active_connections { diff --git a/server/src/http/feature_refresher.rs b/server/src/http/feature_refresher.rs index 516ab36a..3af77a18 100644 --- a/server/src/http/feature_refresher.rs +++ b/server/src/http/feature_refresher.rs @@ -2,7 +2,6 @@ use std::collections::HashSet; use std::{sync::Arc, time::Duration}; use actix_web::http::header::EntityTag; -use actix_web_lab::sse::Data; use chrono::Utc; use dashmap::DashMap; use eventsource_client::Client; diff --git a/server/src/http/unleash_client.rs b/server/src/http/unleash_client.rs index 631fdbbe..6397e842 100644 --- a/server/src/http/unleash_client.rs +++ b/server/src/http/unleash_client.rs @@ -500,7 +500,6 @@ mod tests { http::header::EntityTag, web, App, HttpResponse, }; - use capture_logger::{begin_capture, pop_captured}; use chrono::Duration; use unleash_types::client_features::{ClientFeature, ClientFeatures};