Struct mongodb::ServerInfo
source · [−]pub struct ServerInfo<'a> { /* private fields */ }Expand description
A description of the most up-to-date information known about a server. Further details can be found in the Server Discovery and Monitoring specification.
Implementations
sourceimpl<'a> ServerInfo<'a>
impl<'a> ServerInfo<'a>
sourcepub fn address(&self) -> &ServerAddress
pub fn address(&self) -> &ServerAddress
Gets the address of the server.
sourcepub fn average_round_trip_time(&self) -> Option<Duration>
pub fn average_round_trip_time(&self) -> Option<Duration>
Gets the weighted average of the time it has taken for a server check to round-trip from the driver to the server.
This is the value that the driver uses internally to determine the latency window as part of server selection.
sourcepub fn last_update_time(&self) -> Option<DateTime>
pub fn last_update_time(&self) -> Option<DateTime>
Gets the last time that the driver’s monitoring thread for the server updated the internal information about the server.
sourcepub fn max_wire_version(&self) -> Option<i32>
pub fn max_wire_version(&self) -> Option<i32>
Gets the maximum wire version that the server supports.
sourcepub fn min_wire_version(&self) -> Option<i32>
pub fn min_wire_version(&self) -> Option<i32>
Gets the minimum wire version that the server supports.
sourcepub fn replica_set_name(&self) -> Option<&str>
pub fn replica_set_name(&self) -> Option<&str>
Gets the name of the replica set that the server is part of.
sourcepub fn replica_set_version(&self) -> Option<i32>
pub fn replica_set_version(&self) -> Option<i32>
Gets the version of the replica set that the server is part of.
sourcepub fn server_type(&self) -> ServerType
pub fn server_type(&self) -> ServerType
Get the type of the server.
Gets the tags associated with the server.
Trait Implementations
sourceimpl<'a> Clone for ServerInfo<'a>
impl<'a> Clone for ServerInfo<'a>
sourcefn clone(&self) -> ServerInfo<'a>
fn clone(&self) -> ServerInfo<'a>
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more