cleanup
This commit is contained in:
+7
-7
@@ -9,6 +9,13 @@ pub type Database = SqlitePool;
|
||||
pub type DeviceCounts = DashMap<String, Arc<AtomicUsize>>;
|
||||
pub type Registry = DashMap<(String, String), RegistryEntry>;
|
||||
|
||||
pub struct AppState {
|
||||
pub database: Database,
|
||||
pub registry: Arc<Registry>,
|
||||
pub device_counts: Arc<DeviceCounts>,
|
||||
pub config: Arc<Config>,
|
||||
}
|
||||
|
||||
pub struct RegistryEntry {
|
||||
pub sender: mpsc::Sender<PendingExec>,
|
||||
pub in_flight: Arc<AtomicUsize>,
|
||||
@@ -26,10 +33,3 @@ pub struct PendingExec {
|
||||
pub command: String,
|
||||
pub reply: oneshot::Sender<ExecResult>,
|
||||
}
|
||||
|
||||
pub struct AppState {
|
||||
pub database: Database,
|
||||
pub registry: Arc<Registry>,
|
||||
pub device_counts: Arc<DeviceCounts>,
|
||||
pub config: Arc<Config>,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user