feat: initial work on tenor gif searching
This commit is contained in:
committed by
Angelo Kontaxis
parent
bfe4018e43
commit
b0c977b324
23
crates/core/coalesced/src/config.rs
Normal file
23
crates/core/coalesced/src/config.rs
Normal file
@@ -0,0 +1,23 @@
|
||||
#[derive(Clone, PartialEq, Eq, Debug)]
|
||||
pub struct CoalescionServiceConfig {
|
||||
/// How many tasks are running at once
|
||||
pub max_concurrent: Option<usize>,
|
||||
/// Whether to queue tasks once `max_concurrent` is reached
|
||||
#[cfg(feature = "queue")]
|
||||
pub queue_requests: bool,
|
||||
/// Max amount of tasks in the buffer queue
|
||||
#[cfg(feature = "queue")]
|
||||
pub max_queue: Option<usize>,
|
||||
}
|
||||
|
||||
impl Default for CoalescionServiceConfig {
|
||||
fn default() -> Self {
|
||||
Self {
|
||||
max_concurrent: Some(100),
|
||||
#[cfg(feature = "queue")]
|
||||
queue_requests: true,
|
||||
#[cfg(feature = "queue")]
|
||||
max_queue: Some(100)
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user