Skip to main content

AgentStateServiceClient

Struct AgentStateServiceClient 

Source
pub struct AgentStateServiceClient<T> { /* private fields */ }
Expand description

Client-facing gateway service for agent state operations. The gateway generates execution plans locally and routes to data nodes.

Implementations§

Source§

impl AgentStateServiceClient<Channel>

Source

pub async fn connect<D>(dst: D) -> Result<Self, Error>
where D: TryInto<Endpoint>, D::Error: Into<StdError>,

Attempt to create a new client by connecting to a given endpoint.

Source§

impl<T> AgentStateServiceClient<T>
where T: GrpcService<BoxBody>, T::Error: Into<StdError>, T::ResponseBody: Body<Data = Bytes> + Send + 'static, <T::ResponseBody as Body>::Error: Into<StdError> + Send,

Source

pub fn new(inner: T) -> Self

Source

pub fn with_origin(inner: T, origin: Uri) -> Self

Source

pub fn with_interceptor<F>( inner: T, interceptor: F, ) -> AgentStateServiceClient<InterceptedService<T, F>>
where F: Interceptor, T::ResponseBody: Default, T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>, <T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,

Source

pub fn send_compressed(self, encoding: CompressionEncoding) -> Self

Compress requests with the given encoding.

This requires the server to support it otherwise it might respond with an error.

Source

pub fn accept_compressed(self, encoding: CompressionEncoding) -> Self

Enable decompressing responses.

Source

pub fn max_decoding_message_size(self, limit: usize) -> Self

Limits the maximum size of a decoded message.

Default: 4MB

Source

pub fn max_encoding_message_size(self, limit: usize) -> Self

Limits the maximum size of an encoded message.

Default: usize::MAX

Source

pub async fn fork( &mut self, request: impl IntoRequest<AgentForkRequest>, ) -> Result<Response<AgentForkResponse>, Status>

── Branch (fork) operations ─────────────────────────────────────────

Source

pub async fn merge_branch( &mut self, request: impl IntoRequest<AgentMergeBranchRequest>, ) -> Result<Response<AgentMergeBranchResponse>, Status>

Source

pub async fn discard_branch( &mut self, request: impl IntoRequest<AgentDiscardBranchRequest>, ) -> Result<Response<AgentDiscardBranchResponse>, Status>

Source

pub async fn list_branches( &mut self, request: impl IntoRequest<AgentListBranchesRequest>, ) -> Result<Response<AgentListBranchesResponse>, Status>

Source

pub async fn branch_put( &mut self, request: impl IntoRequest<AgentBranchPutRequest>, ) -> Result<Response<AgentBranchPutResponse>, Status>

Source

pub async fn branch_get( &mut self, request: impl IntoRequest<AgentBranchGetRequest>, ) -> Result<Response<AgentBranchGetResponse>, Status>

Source

pub async fn add_step( &mut self, request: impl IntoRequest<AgentAddStepRequest>, ) -> Result<Response<AgentAddStepResponse>, Status>

── Causal graph operations ──────────────────────────────────────────

Source

pub async fn add_edge( &mut self, request: impl IntoRequest<AgentAddEdgeRequest>, ) -> Result<Response<AgentAddEdgeResponse>, Status>

Source

pub async fn get_step( &mut self, request: impl IntoRequest<AgentGetStepRequest>, ) -> Result<Response<AgentGetStepResponse>, Status>

Source

pub async fn get_content( &mut self, request: impl IntoRequest<AgentGetContentRequest>, ) -> Result<Response<AgentGetContentResponse>, Status>

Source

pub async fn get_edges( &mut self, request: impl IntoRequest<AgentGetEdgesRequest>, ) -> Result<Response<AgentGetEdgesResponse>, Status>

Source

pub async fn traverse( &mut self, request: impl IntoRequest<AgentTraverseRequest>, ) -> Result<Response<AgentTraverseResponse>, Status>

Source

pub async fn find_similar_chains( &mut self, request: impl IntoRequest<AgentFindSimilarChainsRequest>, ) -> Result<Response<AgentFindSimilarChainsResponse>, Status>

Source

pub async fn cas_put( &mut self, request: impl IntoRequest<AgentCasPutRequest>, ) -> Result<Response<AgentCasPutResponse>, Status>

── Reactive state operations ────────────────────────────────────────

Source

pub async fn txn_commit( &mut self, request: impl IntoRequest<AgentTxnCommitRequest>, ) -> Result<Response<AgentTxnCommitResponse>, Status>

Source

pub async fn claim( &mut self, request: impl IntoRequest<AgentClaimRequest>, ) -> Result<Response<AgentClaimResponse>, Status>

── Coordination primitives (claim / lease / renew / release) ───────── Native etcd/Consul/Zookeeper-style coordination: a claim is an atomic SetIfNotExists(claim_key, agent_id); a lease is the same with a TTL so an un-renewed holder auto-expires; renew/release are fenced so only the live holder can extend/drop the key. See issue #691.

Source

pub async fn lease( &mut self, request: impl IntoRequest<AgentLeaseRequest>, ) -> Result<Response<AgentLeaseResponse>, Status>

Source

pub async fn renew( &mut self, request: impl IntoRequest<AgentRenewRequest>, ) -> Result<Response<AgentRenewResponse>, Status>

Source

pub async fn release( &mut self, request: impl IntoRequest<AgentReleaseRequest>, ) -> Result<Response<AgentReleaseResponse>, Status>

Source

pub async fn expire_edge( &mut self, request: impl IntoRequest<AgentExpireEdgeRequest>, ) -> Result<Response<AgentExpireEdgeResponse>, Status>

── Temporal graph operations ────────────────────────────────────────

Source

pub async fn edge_history( &mut self, request: impl IntoRequest<AgentEdgeHistoryRequest>, ) -> Result<Response<AgentEdgeHistoryResponse>, Status>

Source

pub async fn query_provenance( &mut self, request: impl IntoRequest<AgentQueryProvenanceRequest>, ) -> Result<Response<AgentQueryProvenanceResponse>, Status>

── Memory-scope provenance audit (#697 phase 4) ────────────────────── Gated by ManageMemoryScope; the gateway authorizes then forwards to the data node that owns the _agent_provenance CF.

Source

pub async fn agent_manage_team_grant( &mut self, request: impl IntoRequest<AgentManageTeamGrantRequest>, ) -> Result<Response<AgentManageTeamGrantResponse>, Status>

── Memory-scope team-membership admin (#697 phase 2c / #794) ───────── Grant/revoke an agent’s team membership; gated by ManageMemoryScope. The gateway authorizes then applies a durable metadata-Raft op so the change immediately affects Team-scope reads after the next internal-token refresh.

Source

pub async fn agent_team_snapshot_local( &mut self, request: impl IntoRequest<TeamSnapshotLocalRequest>, ) -> Result<Response<TeamSnapshotLocalResponse>, Status>

── Team time-travel (#787) — gateway facade fan-out/fence/merge ──────

Source

pub async fn agent_team_diff_local( &mut self, request: impl IntoRequest<TeamDiffLocalRequest>, ) -> Result<Response<TeamDiffLocalResponse>, Status>

Source

pub async fn cascade_expire( &mut self, request: impl IntoRequest<AgentCascadeExpireRequest>, ) -> Result<Response<AgentCascadeExpireResponse>, Status>

Cascade-expire a fact and its derived dependents (#693).

Source

pub async fn supersede_fact( &mut self, request: impl IntoRequest<AgentSupersedeFactRequest>, ) -> Result<Response<AgentSupersedeFactResponse>, Status>

Supersede a fact with a replacement, optionally cascading (#693 phase 4).

Source

pub async fn memory_ingest( &mut self, request: impl IntoRequest<AgentMemoryIngestRequest>, ) -> Result<Response<AgentMemoryIngestResponse>, Status>

Transactional memory ingest (#780): forwarded to the owning data node’s AgentMemoryIngest (atomic, snapshot-isolated dedup/create/supersede).

Source

pub async fn belief_query( &mut self, request: impl IntoRequest<AgentBeliefQueryRequest>, ) -> Result<Response<AgentBeliefQueryResponse>, Status>

── Bitemporal belief queries (“who believed what, when”) ─────────────

Source

pub async fn belief_divergence( &mut self, request: impl IntoRequest<AgentBeliefDivergenceRequest>, ) -> Result<Response<AgentBeliefDivergenceResponse>, Status>

Source

pub async fn start_run( &mut self, request: impl IntoRequest<AgentStartRunRequest>, ) -> Result<Response<AgentStartRunResponse>, Status>

── Durable agent execution (#846, epic #699 / sub-epic #792) ───────── Run-id-pinned routing: StartRun picks a shard by hashing run_key/agent_id through the ShardRouter and returns run_id = (shard_id << 40) | local_seq; every subsequent call extracts the owning shard as run_id >> 40 — no metadata lookup needed to route. The gateway resolves that shard’s leader and retries on NotLeader.

Source

pub async fn run_step( &mut self, request: impl IntoRequest<AgentRunStepRequest>, ) -> Result<Response<AgentRunStepResponse>, Status>

Source

pub async fn complete_step( &mut self, request: impl IntoRequest<AgentCompleteStepRequest>, ) -> Result<Response<AgentCompleteStepResponse>, Status>

Source

pub async fn checkpoint_get( &mut self, request: impl IntoRequest<AgentCheckpointGetRequest>, ) -> Result<Response<AgentCheckpointGetResponse>, Status>

Source

pub async fn checkpoint_latest( &mut self, request: impl IntoRequest<AgentCheckpointLatestRequest>, ) -> Result<Response<AgentCheckpointLatestResponse>, Status>

Source

pub async fn provenance_chain_query( &mut self, request: impl IntoRequest<AgentProvenanceChainQueryRequest>, ) -> Result<Response<AgentProvenanceChainQueryResponse>, Status>

Source

pub async fn resume_from_step( &mut self, request: impl IntoRequest<AgentResumeFromStepRequest>, ) -> Result<Response<AgentResumeFromStepResponse>, Status>

Source

pub async fn resume_semantic( &mut self, request: impl IntoRequest<AgentResumeSemanticRequest>, ) -> Result<Response<AgentResumeSemanticResponse>, Status>

Source

pub async fn get_run_status( &mut self, request: impl IntoRequest<AgentGetRunStatusRequest>, ) -> Result<Response<AgentGetRunStatusResponse>, Status>

Source

pub async fn fork_run( &mut self, request: impl IntoRequest<AgentForkRunRequest>, ) -> Result<Response<AgentForkRunResponse>, Status>

Phase 5 (#797): branch/time-travel resume. Routed by source_run_id >> 40 to the shard owning the source run; the child run is allocated on that same shard so its self-routing run_id stays addressable.

Source

pub async fn fork_across_candidates( &mut self, request: impl IntoRequest<AgentForkAcrossCandidatesRequest>, ) -> Result<Response<AgentForkAcrossCandidatesResponse>, Status>

Source

pub async fn artifact_put( &mut self, request: impl IntoRequest<AgentArtifactPutRequest>, ) -> Result<Response<AgentArtifactPutResponse>, Status>

Source

pub async fn artifact_get( &mut self, request: impl IntoRequest<AgentArtifactGetRequest>, ) -> Result<Response<AgentArtifactGetResponse>, Status>

Source

pub async fn artifact_resolve( &mut self, request: impl IntoRequest<AgentArtifactResolveRequest>, ) -> Result<Response<AgentArtifactResolveResponse>, Status>

Source

pub async fn watch_prefix( &mut self, request: impl IntoRequest<AgentWatchPrefixRequest>, ) -> Result<Response<Streaming<AgentWatchEventProto>>, Status>

── Streaming ops ────────────────────────────────────────────────────

Trait Implementations§

Source§

impl<T: Clone> Clone for AgentStateServiceClient<T>

Source§

fn clone(&self) -> AgentStateServiceClient<T>

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<T: Debug> Debug for AgentStateServiceClient<T>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> FromRef<T> for T
where T: Clone,

Source§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoRequest<T> for T

Source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more