pub struct AgentStateGetRequest {
pub cf_name: String,
pub key: Vec<u8>,
pub role: u32,
pub entity_id: u64,
pub system: bool,
pub snapshot_seq: u64,
}Expand description
Which agent column family to read. A NAME, not an id: the agent CFs are created directly on the shared DB, so their physical ids are a node-local detail that a coordinator must not have to know (and must not be able to guess wrong — naming the CF is what makes the allowlist check possible).
Fields§
§cf_name: String§key: Vec<u8>§role: u32Logical row address. When role is non-zero the server builds the physical
key itself from (entity_id, role, key-as-suffix) and cf_name is
ignored.
Prefer this over a raw key. Whether a row lives in the collapsed causal CF
under an [entity_id][role][suffix] key or in a legacy per-role CF under
the bare suffix is SERVER state (collapsed_active()), and it differs
between stores. A coordinator that hand-built physical keys would have to
track the storage layout to stay correct — which is exactly the coupling
that keeps agent semantics stuck inside the storage process. Addressing a
row logically leaves layout where it belongs.
CausalRole tag byte; 0 = address by raw key instead
entity_id: u64ignored unless role is set
system: booladdress the SYSTEM_ENTITY namespace, not entity_id
snapshot_seq: u64Snapshot-bounded read: resolve the row as of this engine sequence, ignoring every version committed after it. 0 = read the latest committed version.
Required for an optimistic transaction driven from outside the storage process. Such a transaction baselines its read set on ONE snapshot; reading “latest” instead would let a write committed after the snapshot leak into the decision while the read set still claims the older baseline — the value and the version it is validated against would describe different instants.
Trait Implementations§
Source§impl Clone for AgentStateGetRequest
impl Clone for AgentStateGetRequest
Source§fn clone(&self) -> AgentStateGetRequest
fn clone(&self) -> AgentStateGetRequest
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for AgentStateGetRequest
impl Debug for AgentStateGetRequest
Source§impl Default for AgentStateGetRequest
impl Default for AgentStateGetRequest
Source§impl Message for AgentStateGetRequest
impl Message for AgentStateGetRequest
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.Source§impl PartialEq for AgentStateGetRequest
impl PartialEq for AgentStateGetRequest
impl StructuralPartialEq for AgentStateGetRequest
Auto Trait Implementations§
impl Freeze for AgentStateGetRequest
impl RefUnwindSafe for AgentStateGetRequest
impl Send for AgentStateGetRequest
impl Sync for AgentStateGetRequest
impl Unpin for AgentStateGetRequest
impl UnsafeUnpin for AgentStateGetRequest
impl UnwindSafe for AgentStateGetRequest
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request