Struct job_queue::WorkerBuilder
source · pub struct WorkerBuilder {
pub max_connections: u32,
pub min_connections: u32,
pub worker_count: u32,
pub retry_after: i64,
pub queue: String,
}Fields§
§max_connections: u32§min_connections: u32§worker_count: u32§retry_after: i64§queue: StringImplementations§
source§impl WorkerBuilder
impl WorkerBuilder
pub fn new() -> Self
pub fn max_connections(self, max_connections: u32) -> Self
pub fn min_connections(self, min_connections: u32) -> Self
pub fn worker_count(self, worker_count: u32) -> Self
pub fn retry_after(self, retry_after: i64) -> Self
pub async fn connect(self, database_url: &str) -> Result<Worker, Error>
Trait Implementations§
source§impl Debug for WorkerBuilder
impl Debug for WorkerBuilder
source§impl Default for WorkerBuilder
impl Default for WorkerBuilder
source§fn default() -> WorkerBuilder
fn default() -> WorkerBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl RefUnwindSafe for WorkerBuilder
impl Send for WorkerBuilder
impl Sync for WorkerBuilder
impl Unpin for WorkerBuilder
impl UnwindSafe for WorkerBuilder
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