pub struct EnvConnection;
Expand description
Default env-configured Redis connection manager
Trait Implementations§
Source§impl ConnectionManagerContext for EnvConnection
impl ConnectionManagerContext for EnvConnection
type ConnectionInfo = RedisDB<EnvConnection>
fn connection_manager() -> &'static ConnectionManager<RedisDB<EnvConnection>>
fn state_cache() -> &'static LocalKey<RefCell<Cache<&'static ArcSwapOption<ConnectionState>, Option<Arc<ConnectionState>>>>>
fn get_connection() -> ManagedConnection<Self>
fn client() -> &'static RedisResult<Client>
fn get_db() -> i64
fn with_state<T>(with_fn: fn(&Option<Arc<ConnectionState>>) -> T) -> T
Source§impl ServiceURL for EnvConnection
impl ServiceURL for EnvConnection
fn service_url() -> Result<Url, ParseError>
Auto Trait Implementations§
impl Freeze for EnvConnection
impl RefUnwindSafe for EnvConnection
impl Send for EnvConnection
impl Sync for EnvConnection
impl Unpin for EnvConnection
impl UnwindSafe for EnvConnection
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more