QueueMetrics class

Comprehensive queue metrics with detailed statistics

Constructors

QueueMetrics()

Properties

averageProcessingTime Duration
Average processing time
no setter
averageQueueDepth double
Average queue depth (from snapshots)
no setter
averageWorkerUtilization double
Average worker utilization (0.0 to 1.0)
no setter
completedByPriority Map<JobPriority, int>
final
completedByType Map<String, int>
final
currentlyProcessing int
getter/setter pair
currentQueueDepth int
Current queue depth (most recent snapshot)
no setter
currentWorkerUtilization double
Current worker utilization
no setter
failedByPriority Map<JobPriority, int>
final
failedByType Map<String, int>
final
failureRate double
Failure rate (0.0 to 1.0)
no setter
hashCode int
The hash code for this object.
no setterinherited
lastActivity DateTime?
getter/setter pair
maxProcessingTime Duration
Max processing time
no setter
minProcessingTime Duration
Min processing time
no setter
p50ProcessingTime Duration
Median processing time (P50)
no setter
p95ProcessingTime Duration
P95 processing time
no setter
p999ProcessingTime Duration
P999 processing time
no setter
p99ProcessingTime Duration
P99 processing time
no setter
peakQueueDepth int
Peak queue depth
no setter
peakWorkerUtilization double
Peak worker utilization
no setter
queuedByPriority Map<JobPriority, int>
final
queuedByType Map<String, int>
final
retriedByType Map<String, int>
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
startTime DateTime?
getter/setter pair
stdDevProcessingTime Duration
Standard deviation of processing times
no setter
successRate double
Success rate (0.0 to 1.0)
no setter
throughput double
Throughput (jobs per second)
no setter
timeoutRate double
Timeout rate (0.0 to 1.0)
no setter
totalCompleted int
getter/setter pair
totalFailed int
getter/setter pair
totalProcessingTimeByType Map<String, Duration>
final
totalQueued int
getter/setter pair
totalRetried int
getter/setter pair
totalStarted int
getter/setter pair
totalTimedOut int
getter/setter pair
uptime Duration
Uptime since metrics started
no setter

Methods

averageProcessingTimeForType(String jobType) Duration
Get average processing time for a specific job type
jobCompleted(String jobType, Duration processingTime, {JobPriority? priority}) → void
Record job completed
jobFailed(String jobType, {JobPriority? priority}) → void
Record job failed
jobQueued(String jobType, {JobPriority? priority}) → void
Record job queued
jobRetried(String jobType) → void
Record job retried
jobStarted() → void
Record job started
jobTimedOut(String jobType) → void
Record job timed out
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
recordQueueDepth(int depth) → void
Record queue depth snapshot
recordWorkerUtilization(int activeWorkers, int totalWorkers) → void
Record worker utilization
reset() → void
Reset all metrics
toJson() Map<String, dynamic>
Export metrics as JSON
toPrometheusFormat({String prefix = 'queue'}) String
Export metrics in Prometheus format
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited