pub struct ManifestAuthCookieCacheConfig {
pub enabled: bool,
pub max_age: u64,
pub claims: Vec<String>,
}Expand description
Cookie-cache settings. When enabled, the session cookie carries
a signed JWT-style envelope including the claims listed in
claims (defaults to is_admin + tenant_id). Cookie reads
resolve identity without touching the session store, at the cost
of staleness up to max_age seconds.
Fields§
§enabled: bool§max_age: u64Max age of the cached claims in seconds. After this, the cookie envelope is treated as expired and the session store is consulted again. Default 5 minutes — same as better-auth.
claims: Vec<String>Auth-context fields baked into the cookie envelope. Always
includes user_id; the operator opts in to anything else.
Trait Implementations§
Source§impl Clone for ManifestAuthCookieCacheConfig
impl Clone for ManifestAuthCookieCacheConfig
Source§fn clone(&self) -> ManifestAuthCookieCacheConfig
fn clone(&self) -> ManifestAuthCookieCacheConfig
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<'de> Deserialize<'de> for ManifestAuthCookieCacheConfig
impl<'de> Deserialize<'de> for ManifestAuthCookieCacheConfig
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 ManifestAuthCookieCacheConfig
impl PartialEq for ManifestAuthCookieCacheConfig
Source§fn eq(&self, other: &ManifestAuthCookieCacheConfig) -> bool
fn eq(&self, other: &ManifestAuthCookieCacheConfig) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for ManifestAuthCookieCacheConfig
impl StructuralPartialEq for ManifestAuthCookieCacheConfig
Auto Trait Implementations§
impl Freeze for ManifestAuthCookieCacheConfig
impl RefUnwindSafe for ManifestAuthCookieCacheConfig
impl Send for ManifestAuthCookieCacheConfig
impl Sync for ManifestAuthCookieCacheConfig
impl Unpin for ManifestAuthCookieCacheConfig
impl UnsafeUnpin for ManifestAuthCookieCacheConfig
impl UnwindSafe for ManifestAuthCookieCacheConfig
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