redux of the worker queue
This commit is contained in:
@@ -225,7 +225,10 @@ pub struct TaskRef {
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Deserialize)]
|
||||
pub struct PipelineRef {
|
||||
#[serde(default)]
|
||||
pub task_ids: Vec<String>,
|
||||
#[serde(default)]
|
||||
pub pipeline_id: Option<String>,
|
||||
}
|
||||
|
||||
// --- Status ---
|
||||
@@ -246,6 +249,10 @@ pub struct Status {
|
||||
pub tasks: Vec<TaskInfo>,
|
||||
#[serde(default)]
|
||||
pub scheduled: Option<ScheduledTasks>,
|
||||
#[serde(default)]
|
||||
pub work_queue: Option<WorkQueueStats>,
|
||||
#[serde(default)]
|
||||
pub scheduler: Option<serde_json::Value>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Deserialize)]
|
||||
@@ -254,6 +261,22 @@ pub struct ScheduledTasks {
|
||||
pub next_monitor: Option<String>,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Deserialize)]
|
||||
pub struct WorkQueueCounts {
|
||||
pub pending: u64,
|
||||
pub running: u64,
|
||||
pub completed: u64,
|
||||
pub failed: u64,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Deserialize)]
|
||||
pub struct WorkQueueStats {
|
||||
pub download: WorkQueueCounts,
|
||||
pub index: WorkQueueCounts,
|
||||
pub tag: WorkQueueCounts,
|
||||
pub organize: WorkQueueCounts,
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone, PartialEq, Deserialize)]
|
||||
pub struct LibrarySummary {
|
||||
pub total_items: u64,
|
||||
|
||||
Reference in New Issue
Block a user