Trait reool::instrumentation::Instrumentation [−][src]
pub trait Instrumentation {}Show 19 methods
fn pool_added(&self, pool: PoolId); fn pool_removed(&self, pool: PoolId); fn checked_out_connection(
&self,
idle_for: Duration,
time_since_checkout_request: Duration,
pool: PoolId
); fn checked_in_returned_connection(
&self,
flight_time: Duration,
pool: PoolId
); fn checked_in_new_connection(&self, pool: PoolId); fn connection_dropped(
&self,
flight_time: Option<Duration>,
lifetime: Duration,
pool: PoolId
); fn connection_created(
&self,
connected_after: Duration,
total_time: Duration,
pool: PoolId
); fn idle_inc(&self, pool: PoolId); fn idle_dec(&self, pool: PoolId); fn in_flight_inc(&self, pool: PoolId); fn in_flight_dec(&self, pool: PoolId); fn reservation_added(&self, pool: PoolId); fn reservation_fulfilled(
&self,
reservation_time: Duration,
checkout_request_time: Duration,
pool: PoolId
); fn reservation_not_fulfilled(
&self,
reservation_time: Duration,
checkout_request_time: Duration,
pool: PoolId
); fn reservation_limit_reached(&self, pool: PoolId); fn connection_factory_failed(&self, pool: PoolId); fn internal_message_received(&self, latency: Duration, pool: PoolId); fn checkout_message_received(&self, latency: Duration, pool: PoolId); fn relevant_message_processed(
&self,
processing_time: Duration,
pool: PoolId
);
Expand description
A trait with methods that get called by the pool on certain events.
Required methods
fn pool_added(&self, pool: PoolId)
fn pool_removed(&self, pool: PoolId)
fn checked_out_connection(
&self,
idle_for: Duration,
time_since_checkout_request: Duration,
pool: PoolId
)
fn checked_out_connection(
&self,
idle_for: Duration,
time_since_checkout_request: Duration,
pool: PoolId
)
A connection was checked out
fn checked_in_returned_connection(&self, flight_time: Duration, pool: PoolId)
fn checked_in_returned_connection(&self, flight_time: Duration, pool: PoolId)
A connection that was previously checked out was checked in again
fn checked_in_new_connection(&self, pool: PoolId)
fn checked_in_new_connection(&self, pool: PoolId)
A newly created connection was checked in
A connection was dropped because it was marked as defect
fn connection_created(
&self,
connected_after: Duration,
total_time: Duration,
pool: PoolId
)
fn connection_created(
&self,
connected_after: Duration,
total_time: Duration,
pool: PoolId
)
A new connection was created
fn in_flight_inc(&self, pool: PoolId)
fn in_flight_inc(&self, pool: PoolId)
The number of in flight connections increased by 1
fn in_flight_dec(&self, pool: PoolId)
fn in_flight_dec(&self, pool: PoolId)
The number of in flight connections decreased by 1
fn reservation_added(&self, pool: PoolId)
fn reservation_added(&self, pool: PoolId)
A reservation has been enqueued
fn reservation_fulfilled(
&self,
reservation_time: Duration,
checkout_request_time: Duration,
pool: PoolId
)
fn reservation_fulfilled(
&self,
reservation_time: Duration,
checkout_request_time: Duration,
pool: PoolId
)
A reservation was fulfilled. A connection was available in time.
fn reservation_not_fulfilled(
&self,
reservation_time: Duration,
checkout_request_time: Duration,
pool: PoolId
)
fn reservation_not_fulfilled(
&self,
reservation_time: Duration,
checkout_request_time: Duration,
pool: PoolId
)
A reservation was not fulfilled. A connection was mostly not available in time.
fn reservation_limit_reached(&self, pool: PoolId)
fn reservation_limit_reached(&self, pool: PoolId)
The reservation queue has a limit and that limit was just reached. This means a checkout has instantaneously failed.
fn connection_factory_failed(&self, pool: PoolId)
fn connection_factory_failed(&self, pool: PoolId)
The connection factory was asked to create a new connection but it failed to do so.
fn internal_message_received(&self, latency: Duration, pool: PoolId)
fn internal_message_received(&self, latency: Duration, pool: PoolId)
A pool internal message was received