pub struct CacheEntry {
pub key: String,
pub fingerprint: String,
pub json: String,
pub bytes: u64,
pub generation: i64,
pub last_used: i64,
pub hits: u64,
pub anchor: Option<String>,
pub anchor_state: AnchorState,
}Expand description
One entry in the cache tier, with its anchor resolved against the current graph.
Fields§
§key: StringThe cache key.
fingerprint: StringThe freshness witness stored with the payload.
json: StringThe cached payload.
bytes: u64The entry’s payload size — what the byte budget is spent on.
generation: i64The sweep generation this entry was written in.
last_used: i64The access tick it was last read or written at. A logical counter, never a clock.
hits: u64How many times it has been read back.
anchor: Option<String>The node key it is derived from, if any.
anchor_state: AnchorStateWhat that anchor is worth against the current graph. Computed on read; no column holds it.
Trait Implementations§
Source§impl Clone for CacheEntry
impl Clone for CacheEntry
Source§fn clone(&self) -> CacheEntry
fn clone(&self) -> CacheEntry
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 CacheEntry
impl Debug for CacheEntry
Source§impl<'de> Deserialize<'de> for CacheEntry
impl<'de> Deserialize<'de> for CacheEntry
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
impl Eq for CacheEntry
Source§impl PartialEq for CacheEntry
impl PartialEq for CacheEntry
Source§impl Serialize for CacheEntry
impl Serialize for CacheEntry
impl StructuralPartialEq for CacheEntry
Auto Trait Implementations§
impl Freeze for CacheEntry
impl RefUnwindSafe for CacheEntry
impl Send for CacheEntry
impl Sync for CacheEntry
impl Unpin for CacheEntry
impl UnsafeUnpin for CacheEntry
impl UnwindSafe for CacheEntry
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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.