pub struct StateLimits {
pub max_keys: usize,
pub max_value_bytes: usize,
pub max_history_len: usize,
pub lock_timeout: Duration,
}Expand description
Resource bounds for agent state (PRIMITIVES_CONTRACT §3).
Fields§
§max_keys: usizeMaximum number of keys allowed in state. Default: 10_000.
max_value_bytes: usizeMaximum size in bytes for a single serialized value. Default: 1_048_576 (1 MiB).
max_history_len: usizeMaximum number of history snapshots to retain. Default: 100.
lock_timeout: DurationTimeout for acquiring state locks. Default: 5 s.
Trait Implementations§
Source§impl Clone for StateLimits
impl Clone for StateLimits
Source§fn clone(&self) -> StateLimits
fn clone(&self) -> StateLimits
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 StateLimits
impl Debug for StateLimits
Source§impl Default for StateLimits
impl Default for StateLimits
Source§impl<'de> Deserialize<'de> for StateLimits
impl<'de> Deserialize<'de> for StateLimits
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 StateLimits
impl RefUnwindSafe for StateLimits
impl Send for StateLimits
impl Sync for StateLimits
impl Unpin for StateLimits
impl UnsafeUnpin for StateLimits
impl UnwindSafe for StateLimits
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