pub struct L2CacheConfig {
pub max_entries: usize,
pub max_disk_bytes: u64,
pub default_ttl: u64,
pub cache_dir: PathBuf,
pub enable_compression: bool,
pub cleanup_interval: u64,
pub enable_background_cleanup: bool,
}Expand description
L2 (disk) cache configuration
Fields§
§max_entries: usizeMaximum number of entries in L2 cache
max_disk_bytes: u64Maximum disk usage in bytes
default_ttl: u64Default TTL for L2 entries (in seconds)
cache_dir: PathBufCache directory path
enable_compression: boolEnable compression for disk storage
cleanup_interval: u64Cleanup interval (in seconds)
enable_background_cleanup: boolEnable background cleanup
Trait Implementations§
Source§impl Clone for L2CacheConfig
impl Clone for L2CacheConfig
Source§fn clone(&self) -> L2CacheConfig
fn clone(&self) -> L2CacheConfig
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 L2CacheConfig
impl Debug for L2CacheConfig
Source§impl Default for L2CacheConfig
impl Default for L2CacheConfig
Source§impl<'de> Deserialize<'de> for L2CacheConfig
impl<'de> Deserialize<'de> for L2CacheConfig
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
Auto Trait Implementations§
impl Freeze for L2CacheConfig
impl RefUnwindSafe for L2CacheConfig
impl Send for L2CacheConfig
impl Sync for L2CacheConfig
impl Unpin for L2CacheConfig
impl UnwindSafe for L2CacheConfig
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