1
1
use std:: sync:: Arc ;
2
2
3
- use bittorrent_tracker_core:: announce_handler:: AnnounceHandler ;
4
3
use bittorrent_tracker_core:: container:: TrackerCoreContainer ;
5
- use bittorrent_tracker_core:: scrape_handler:: ScrapeHandler ;
6
- use bittorrent_tracker_core:: whitelist;
7
4
use tokio:: sync:: RwLock ;
8
5
use torrust_tracker_configuration:: { Core , UdpTracker } ;
9
6
@@ -14,12 +11,7 @@ use crate::services::scrape::ScrapeService;
14
11
use crate :: { event, statistics, MAX_CONNECTION_ID_ERRORS_PER_IP } ;
15
12
16
13
pub struct UdpTrackerCoreContainer {
17
- // todo: replace with TrackerCoreContainer
18
- pub core_config : Arc < Core > ,
19
- pub announce_handler : Arc < AnnounceHandler > ,
20
- pub scrape_handler : Arc < ScrapeHandler > ,
21
- pub whitelist_authorization : Arc < whitelist:: authorization:: WhitelistAuthorization > ,
22
-
14
+ pub tracker_core_container : Arc < TrackerCoreContainer > ,
23
15
pub udp_tracker_config : Arc < UdpTracker > ,
24
16
pub udp_core_stats_event_sender : Arc < Option < Box < dyn event:: sender:: Sender > > > ,
25
17
pub udp_core_stats_repository : Arc < statistics:: repository:: Repository > ,
@@ -58,11 +50,7 @@ impl UdpTrackerCoreContainer {
58
50
) ) ;
59
51
60
52
Arc :: new ( UdpTrackerCoreContainer {
61
- core_config : tracker_core_container. core_config . clone ( ) ,
62
- announce_handler : tracker_core_container. announce_handler . clone ( ) ,
63
- scrape_handler : tracker_core_container. scrape_handler . clone ( ) ,
64
- whitelist_authorization : tracker_core_container. whitelist_authorization . clone ( ) ,
65
-
53
+ tracker_core_container : tracker_core_container. clone ( ) ,
66
54
udp_tracker_config : udp_tracker_config. clone ( ) ,
67
55
udp_core_stats_event_sender : udp_core_stats_event_sender. clone ( ) ,
68
56
udp_core_stats_repository : udp_core_stats_repository. clone ( ) ,
0 commit comments