pub trait EventQueueRecorder: Send + Sync {
// Required methods
fn queue_time(&self, waited: Duration);
fn processing_time(&self, took: Duration);
fn operation_started(&self);
fn operation_timed_out(&self);
fn idle_time(&self, idle: Duration);
}Expand description
Receives the engine loop’s event-queue measurements. Every method is called from the engine task, so an implementation must not block.
Required Methods§
Sourcefn queue_time(&self, waited: Duration)
fn queue_time(&self, waited: Duration)
A command waited waited between its send and the turn that started
it: Kafka’s EventQueueTimeMs.
Sourcefn processing_time(&self, took: Duration)
fn processing_time(&self, took: Duration)
An event ran for took, to its commit reply for a write: Kafka’s
EventQueueProcessingTimeMs.
Sourcefn operation_started(&self)
fn operation_started(&self)
The loop started an event: Kafka’s EventQueueOperationsStartedCount.
Sourcefn operation_timed_out(&self)
fn operation_timed_out(&self)
The loop reached a command whose caller had already stopped waiting
for the reply: Kafka’s EventQueueOperationsTimedOutCount. Kafka drops
an event whose deadline passed in the queue; the engine still runs the
command, so it also counts as started.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".