[−][src]Trait nakadion::instrumentation::Instruments
An interface on which Nakadion
exposes metrics
An implementor of this interface can be used with
Instrumentation::new
Required methods
fn stream_connect_attempt_success(&self, time: Duration)
Triggered when a single connect attempt for a stream was successful
time
is the time for the request
fn stream_connect_attempt_failed(&self, time: Duration)
Triggered when a single connect attempt for a stream failed
time
is the time for the request
fn stream_connected(&self, time: Duration)
Triggered when a stream was finally connect after maybe multiple attempts
time
is the time for the whole cycle until a connection was made
fn stream_not_connected(&self, time: Duration, err: &ConnectError)
Triggered when connecting to a stream finally failed after maybe multiple attempts
time
is the time for the whole cycle until a connection attempts finally failed
fn stream_chunk_received(&self, n_bytes: usize)
A chunk of data with n_bytes
was received over the network
fn stream_frame_completed(&self, n_bytes: usize, time: Duration)
Chunks have been assembled to a complete frame containing all required data
fn stream_tick_emitted(&self)
An internal tick signal has been emitted
fn info_frame_received(
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
The controller received a frame which contained info data
The time it took from receiving the first chunk until it reached the controller are passed along with the complete bytes of the frame
fn keep_alive_frame_received(
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
The controller received a frame which contained no events
The time it took from receiving the first chunk until it reached the controller are passed along with the complete bytes of the frame
fn batch_frame_received(
&self,
frame_started_at: Instant,
frame_completed_at: Instant,
events_bytes: usize
)
&self,
frame_started_at: Instant,
frame_completed_at: Instant,
events_bytes: usize
)
A partition which was formerly not known to be active was sent data on The controller received a frame which contained events
The time it took from receiving the first chunk until it reached the controller are passed along with the complete bytes of the frame
fn batch_frame_gap(&self, gap: Duration)
The time elapsed between the reception of 2 batches with events
fn no_frames_warning(&self, no_frames_for: Duration)
No frames have been received for the given time and the warning has already threshold elapsed
fn no_events_warning(&self, no_events_for: Duration)
No events have been received for the given time and the warning threshold has already elapsed
fn stream_dead(&self, after: Duration)
fn stream_error(&self, err: &EventStreamError)
The stream was aborted due to a streaming related error
fn batches_in_flight_inc(&self)
Triggered when a new batch with events was received
fn batches_in_flight_dec(&self)
Triggered when a batch with events was processed
fn batches_in_flight_dec_by(&self, by: usize)
Usually triggered when there are still batches in flight and the stream aborts.
This is a correction for the inflight metrics.
fn event_type_partition_activated(&self)
fn event_type_partition_deactivated(&self, active_for: Duration)
A partition did not receive data for some time is is therefore considered inactive.
fn batch_processing_started(
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
fn batch_processed(&self, n_bytes: usize, time: Duration)
Events were processed.
fn batch_processed_n_events(&self, n_events: usize)
Events were processed.
fn batch_deserialized(&self, n_bytes: usize, time: Duration)
Events have been deserialized.
The amount of bytes deserialized and the time it took are passed.
fn cursor_to_commit_received(
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
Cursors to be committed have reached the commit stage.
The time it took from receiving the first chunk until it reached the commit stage are passed
fn cursors_commit_triggered(&self, trigger: CommitTrigger)
Cursors commit was triggered.
fn cursors_committed(&self, n_cursors: usize, time: Duration)
Cursors were successfully committed.
The time request took is passed
fn cursors_not_committed(
&self,
n_cursors: usize,
time: Duration,
err: &CommitError
)
&self,
n_cursors: usize,
time: Duration,
err: &CommitError
)
Cursors were not successfully committed.
The time request took is passed
fn commit_cursors_attempt_failed(&self, n_cursors: usize, time: Duration)
An attempt to commit cursors failed. There might still be a retry
The time request took is passed
Implementors
impl Instruments for Metrix
[src]
fn stream_connect_attempt_success(&self, time: Duration)
[src]
fn stream_connect_attempt_failed(&self, time: Duration)
[src]
fn stream_connected(&self, time: Duration)
[src]
fn stream_not_connected(&self, time: Duration, _err: &ConnectError)
[src]
fn stream_chunk_received(&self, n_bytes: usize)
[src]
fn stream_frame_completed(&self, n_bytes: usize, time: Duration)
[src]
fn stream_tick_emitted(&self)
[src]
fn info_frame_received(
&self,
_frame_started_at: Instant,
frame_completed_at: Instant
)
[src]
&self,
_frame_started_at: Instant,
frame_completed_at: Instant
)
fn keep_alive_frame_received(
&self,
_frame_started_at: Instant,
frame_completed_at: Instant
)
[src]
&self,
_frame_started_at: Instant,
frame_completed_at: Instant
)
fn batch_frame_received(
&self,
_frame_started_at: Instant,
frame_completed_at: Instant,
events_bytes: usize
)
[src]
&self,
_frame_started_at: Instant,
frame_completed_at: Instant,
events_bytes: usize
)
fn batch_frame_gap(&self, gap: Duration)
[src]
fn no_frames_warning(&self, no_frames_for: Duration)
[src]
fn no_events_warning(&self, no_events_for: Duration)
[src]
fn stream_dead(&self, after: Duration)
[src]
fn stream_error(&self, err: &EventStreamError)
[src]
fn batches_in_flight_inc(&self)
[src]
fn batches_in_flight_dec(&self)
[src]
fn batches_in_flight_dec_by(&self, by: usize)
[src]
fn event_type_partition_activated(&self)
[src]
fn event_type_partition_deactivated(&self, active_for: Duration)
[src]
fn batch_processing_started(
&self,
_frame_started_at: Instant,
frame_completed_at: Instant
)
[src]
&self,
_frame_started_at: Instant,
frame_completed_at: Instant
)
fn batch_processed(&self, n_bytes: usize, time: Duration)
[src]
fn batch_processed_n_events(&self, n_events: usize)
[src]
fn batch_deserialized(&self, n_bytes: usize, time: Duration)
[src]
fn cursor_to_commit_received(
&self,
_frame_started_at: Instant,
frame_completed_at: Instant
)
[src]
&self,
_frame_started_at: Instant,
frame_completed_at: Instant
)
fn cursors_commit_triggered(&self, trigger: CommitTrigger)
[src]
fn cursors_committed(&self, n_cursors: usize, time: Duration)
[src]
fn cursors_not_committed(
&self,
n_cursors: usize,
time: Duration,
_err: &CommitError
)
[src]
&self,
n_cursors: usize,
time: Duration,
_err: &CommitError
)
fn commit_cursors_attempt_failed(&self, n_cursors: usize, time: Duration)
[src]
impl Instruments for Instrumentation
[src]
fn stream_connect_attempt_success(&self, time: Duration)
[src]
fn stream_connect_attempt_failed(&self, time: Duration)
[src]
fn stream_connected(&self, time: Duration)
[src]
fn stream_not_connected(&self, time: Duration, err: &ConnectError)
[src]
fn stream_chunk_received(&self, n_bytes: usize)
[src]
fn stream_frame_completed(&self, n_bytes: usize, time: Duration)
[src]
fn stream_tick_emitted(&self)
[src]
fn info_frame_received(
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
[src]
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
fn keep_alive_frame_received(
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
[src]
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
fn batch_frame_received(
&self,
frame_started_at: Instant,
frame_completed_at: Instant,
events_bytes: usize
)
[src]
&self,
frame_started_at: Instant,
frame_completed_at: Instant,
events_bytes: usize
)
fn batch_frame_gap(&self, gap: Duration)
[src]
fn no_frames_warning(&self, no_frames_for: Duration)
[src]
fn no_events_warning(&self, no_events_for: Duration)
[src]
fn stream_dead(&self, after: Duration)
[src]
fn stream_error(&self, err: &EventStreamError)
[src]
fn batches_in_flight_inc(&self)
[src]
fn batches_in_flight_dec(&self)
[src]
fn batches_in_flight_dec_by(&self, by: usize)
[src]
fn event_type_partition_activated(&self)
[src]
fn event_type_partition_deactivated(&self, active_for: Duration)
[src]
fn batch_processing_started(
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
[src]
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
fn batch_processed(&self, n_bytes: usize, time: Duration)
[src]
fn batch_processed_n_events(&self, n_events: usize)
[src]
fn batch_deserialized(&self, n_bytes: usize, time: Duration)
[src]
fn cursor_to_commit_received(
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
[src]
&self,
frame_started_at: Instant,
frame_completed_at: Instant
)
fn cursors_commit_triggered(&self, trigger: CommitTrigger)
[src]
fn cursors_committed(&self, n_cursors: usize, time: Duration)
[src]
fn cursors_not_committed(
&self,
n_cursors: usize,
time: Duration,
err: &CommitError
)
[src]
&self,
n_cursors: usize,
time: Duration,
err: &CommitError
)