Struct svc_scheduler::tasks::pool::TaskPool
source · pub struct TaskPool { /* private fields */ }
Expand description
Represents a pool of connections to a Redis server.
The TaskPool
struct provides a managed pool of connections to a Redis server.
It allows clients to acquire and release connections from the pool and handles
connection management, such as connection pooling and reusing connections.
Implementations§
Trait Implementations§
source§impl RedisPool for TaskPool
impl RedisPool for TaskPool
source§fn new_task<'life0, 'life1, 'async_trait>(
&'life0 mut self,
task: &'life1 Task,
priority: FlightPriority,
expiry: DateTime<Utc>
) -> Pin<Box<dyn Future<Output = Result<i64, CacheError>> + Send + 'async_trait>>
fn new_task<'life0, 'life1, 'async_trait>( &'life0 mut self, task: &'life1 Task, priority: FlightPriority, expiry: DateTime<Utc> ) -> Pin<Box<dyn Future<Output = Result<i64, CacheError>> + Send + 'async_trait>>
Creates a new task and returns the task_id for it
source§fn update_task<'life0, 'life1, 'async_trait>(
&'life0 mut self,
task_id: i64,
task: &'life1 Task,
expiry: DateTime<Utc>
) -> Pin<Box<dyn Future<Output = Result<(), CacheError>> + Send + 'async_trait>>
fn update_task<'life0, 'life1, 'async_trait>( &'life0 mut self, task_id: i64, task: &'life1 Task, expiry: DateTime<Utc> ) -> Pin<Box<dyn Future<Output = Result<(), CacheError>> + Send + 'async_trait>>
Updates task information
Auto Trait Implementations§
impl !RefUnwindSafe for TaskPool
impl Send for TaskPool
impl Sync for TaskPool
impl Unpin for TaskPool
impl !UnwindSafe for TaskPool
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
§impl<T> CloneAny for T
impl<T> CloneAny for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request