pub trait HierarchicalTaskMetrics:
Send
+ Sync
+ Debug {
Show 16 methods
// Required methods
fn increment_issued(&self);
fn increment_started(&self);
fn increment_success(&self);
fn increment_cancelled(&self);
fn increment_failed(&self);
fn increment_rejected(&self);
fn issued(&self) -> u64;
fn started(&self) -> u64;
fn success(&self) -> u64;
fn cancelled(&self) -> u64;
fn failed(&self) -> u64;
fn rejected(&self) -> u64;
// Provided methods
fn total_completed(&self) -> u64 { ... }
fn pending(&self) -> u64 { ... }
fn active(&self) -> u64 { ... }
fn queued(&self) -> u64 { ... }
}
Expand description
Trait for hierarchical task metrics that supports aggregation up the tracker tree
This trait provides different implementations for root and child trackers:
- Root trackers integrate with Prometheus metrics for observability
- Child trackers chain metric updates up to their parents for aggregation
- All implementations maintain thread-safe atomic operations
Required Methods§
Sourcefn increment_issued(&self)
fn increment_issued(&self)
Increment issued task counter
Sourcefn increment_started(&self)
fn increment_started(&self)
Increment started task counter
Sourcefn increment_success(&self)
fn increment_success(&self)
Increment success counter
Sourcefn increment_cancelled(&self)
fn increment_cancelled(&self)
Increment cancelled counter
Sourcefn increment_failed(&self)
fn increment_failed(&self)
Increment failed counter
Sourcefn increment_rejected(&self)
fn increment_rejected(&self)
Increment rejected counter
Provided Methods§
Sourcefn total_completed(&self) -> u64
fn total_completed(&self) -> u64
Get total completed tasks (success + cancelled + failed + rejected)