pub struct MemoryConfig {
pub max_jobs: Option<usize>,
pub auto_cleanup: bool,
pub cleanup_interval: Option<Duration>,
}
Expand description
Configuration for in-memory storage
Fields§
§max_jobs: Option<usize>
Maximum number of jobs to keep in memory
auto_cleanup: bool
Whether to enable auto-cleanup of completed jobs
cleanup_interval: Option<Duration>
Interval for cleanup operations
Implementations§
Source§impl MemoryConfig
impl MemoryConfig
Sourcepub fn with_max_jobs(self, max_jobs: usize) -> Self
pub fn with_max_jobs(self, max_jobs: usize) -> Self
Set the maximum number of jobs to keep in memory
Sourcepub fn with_auto_cleanup(self, enabled: bool) -> Self
pub fn with_auto_cleanup(self, enabled: bool) -> Self
Enable auto-cleanup of completed jobs
Sourcepub fn with_cleanup_interval(self, interval: Duration) -> Self
pub fn with_cleanup_interval(self, interval: Duration) -> Self
Set the cleanup interval
Trait Implementations§
Source§impl Clone for MemoryConfig
impl Clone for MemoryConfig
Source§fn clone(&self) -> MemoryConfig
fn clone(&self) -> MemoryConfig
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 moreSource§impl Debug for MemoryConfig
impl Debug for MemoryConfig
Source§impl Default for MemoryConfig
impl Default for MemoryConfig
Source§impl<'de> Deserialize<'de> for MemoryConfig
impl<'de> Deserialize<'de> for MemoryConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for MemoryConfig
impl PartialEq for MemoryConfig
Source§impl Serialize for MemoryConfig
impl Serialize for MemoryConfig
impl Eq for MemoryConfig
impl StructuralPartialEq for MemoryConfig
Auto Trait Implementations§
impl Freeze for MemoryConfig
impl RefUnwindSafe for MemoryConfig
impl Send for MemoryConfig
impl Sync for MemoryConfig
impl Unpin for MemoryConfig
impl UnwindSafe for MemoryConfig
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.