pub struct RedisConnectionManager { /* private fields */ }
Expand description
A bb8::ManageConnection
for redis::Client::get_async_connection
.
Implementations§
Source§impl RedisConnectionManager
impl RedisConnectionManager
Sourcepub fn new<T: IntoConnectionInfo>(info: T) -> Result<Self, RedisError>
pub fn new<T: IntoConnectionInfo>(info: T) -> Result<Self, RedisError>
Create a new RedisConnectionManager
.
See redis::Client::open
for a description of the parameter types.
Trait Implementations§
Source§impl Clone for RedisConnectionManager
impl Clone for RedisConnectionManager
Source§fn clone(&self) -> RedisConnectionManager
fn clone(&self) -> RedisConnectionManager
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for RedisConnectionManager
impl Debug for RedisConnectionManager
Source§impl ManageConnection for RedisConnectionManager
impl ManageConnection for RedisConnectionManager
Source§type Connection = MultiplexedConnection
type Connection = MultiplexedConnection
The connection type this manager deals with.
Source§type Error = RedisError
type Error = RedisError
The error type returned by
Connection
s.Source§async fn connect(&self) -> Result<Self::Connection, Self::Error>
async fn connect(&self) -> Result<Self::Connection, Self::Error>
Attempts to create a new connection.
Source§async fn is_valid(&self, conn: &mut Self::Connection) -> Result<(), Self::Error>
async fn is_valid(&self, conn: &mut Self::Connection) -> Result<(), Self::Error>
Determines if the connection is still connected to the database.
Source§fn has_broken(&self, _: &mut Self::Connection) -> bool
fn has_broken(&self, _: &mut Self::Connection) -> bool
Synchronously determine if the connection is no longer usable, if possible.
Auto Trait Implementations§
impl Freeze for RedisConnectionManager
impl RefUnwindSafe for RedisConnectionManager
impl Send for RedisConnectionManager
impl Sync for RedisConnectionManager
impl Unpin for RedisConnectionManager
impl UnwindSafe for RedisConnectionManager
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