pub struct CiseauxSingle { /* private fields */ }Expand description
A connections pool to a single Redis instance
Implementations§
Source§impl CiseauxSingle
impl CiseauxSingle
Sourcepub fn builder(client: Client) -> SingleInit
pub fn builder(client: Client) -> SingleInit
Shortcut to SingleInit::new
Sourcepub fn init(client: Client) -> SingleInit
pub fn init(client: Client) -> SingleInit
Shortcut to SingleInit::new
Sourcepub async fn new(client: Client) -> Result<CiseauxSingle, RedisError>
pub async fn new(client: Client) -> Result<CiseauxSingle, RedisError>
Create a new pool using defaults settings
Sourcepub async fn query<C: QueryAble, T: FromRedisValue>(
&self,
cmd: C,
) -> Result<T, RedisError>
pub async fn query<C: QueryAble, T: FromRedisValue>( &self, cmd: C, ) -> Result<T, RedisError>
Asynchronously query QueryAble (trait, implemented for redis::Cmd and redis::Pipeline), but in case of network error, will try to reconnect once to the same database (by default), or follow the reconnect_behavior you provided
Trait Implementations§
Source§impl Clone for CiseauxSingle
impl Clone for CiseauxSingle
Source§fn clone(&self) -> CiseauxSingle
fn clone(&self) -> CiseauxSingle
Returns a duplicate 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 moreAuto Trait Implementations§
impl Freeze for CiseauxSingle
impl !RefUnwindSafe for CiseauxSingle
impl Send for CiseauxSingle
impl Sync for CiseauxSingle
impl Unpin for CiseauxSingle
impl !UnwindSafe for CiseauxSingle
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