HierarchicalTaskMetrics

Trait HierarchicalTaskMetrics 

Source
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§

Source

fn increment_issued(&self)

Increment issued task counter

Source

fn increment_started(&self)

Increment started task counter

Source

fn increment_success(&self)

Increment success counter

Source

fn increment_cancelled(&self)

Increment cancelled counter

Source

fn increment_failed(&self)

Increment failed counter

Source

fn increment_rejected(&self)

Increment rejected counter

Source

fn issued(&self) -> u64

Get current issued count (local to this tracker)

Source

fn started(&self) -> u64

Get current started count (local to this tracker)

Source

fn success(&self) -> u64

Get current success count (local to this tracker)

Source

fn cancelled(&self) -> u64

Get current cancelled count (local to this tracker)

Source

fn failed(&self) -> u64

Get current failed count (local to this tracker)

Source

fn rejected(&self) -> u64

Get current rejected count (local to this tracker)

Provided Methods§

Source

fn total_completed(&self) -> u64

Get total completed tasks (success + cancelled + failed + rejected)

Source

fn pending(&self) -> u64

Get number of pending tasks (issued - completed)

Source

fn active(&self) -> u64

Get the number of tasks that are currently active (started - completed)

Source

fn queued(&self) -> u64

Get number of tasks queued in scheduler (issued - started)

Implementors§