pub enum ClientState {
Negotiating,
Authenticating,
Idle,
InTransaction,
Waiting,
}Expand description
High-level phase a client is in at a point in time. Used for admin display and for counting clients by state in the metrics gauge.
Waiting and InTransaction are defined now but only transitioned to
in later phases — Phase 1 only exercises the Negotiating → Authenticating → Idle path.
Variants§
Negotiating
Pre-startup: reading the initial message, handling SSL or cancel requests.
Authenticating
SCRAM exchange is in progress.
Idle
Connected and ready; either between transactions (transaction mode) or holding an open session (session mode).
InTransaction
Actively forwarding inside a transaction. Reserved for Phase 2.
Waiting
Blocked on pool checkout waiting for a server connection to become available. Reserved for Phase 2.
Implementations§
Trait Implementations§
Source§impl Clone for ClientState
impl Clone for ClientState
impl Copy for ClientState
Source§impl Debug for ClientState
impl Debug for ClientState
impl Eq for ClientState
Source§impl PartialEq for ClientState
impl PartialEq for ClientState
impl StructuralPartialEq for ClientState
Auto Trait Implementations§
impl Forget for ClientState
impl Freeze for ClientState
impl Move for ClientState
impl RefUnwindSafe for ClientState
impl Send for ClientState
impl Sync for ClientState
impl Unpin for ClientState
impl UnsafeUnpin for ClientState
impl UnwindSafe for ClientState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.