Skip to main content

GrpcHexastoreClients

Struct GrpcHexastoreClients 

Source
pub struct GrpcHexastoreClients { /* private fields */ }
Expand description

Tonic clients for all three hexastore axes.

Implementations§

Source§

impl GrpcHexastoreClients

Source

pub async fn connect(config: &ClusterConfig) -> Result<Self, ComputeError>

Connect to S, P, and O from config.

Trait Implementations§

Source§

impl Clone for GrpcHexastoreClients

Source§

fn clone(&self) -> GrpcHexastoreClients

Returns a duplicate of the value. Read more
1.0.0 · Source§

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

Performs copy-assignment from source. Read more
Source§

impl Debug for GrpcHexastoreClients

Source§

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

Formats the value using the given formatter. Read more
Source§

impl HexastoreAdmin for GrpcHexastoreClients

Source§

async fn describe( &self, axis: PartitionAxis, ) -> Result<HexastoreDescribe, Status>

Identity and operational metrics for axis.
Source§

impl HexastoreAxisHeadStats for GrpcHexastoreClients

Source§

async fn axis_head_max_commit_ts( &self, permutation: IndexPermutation, head_prefixes: &[Vec<u8>], ) -> Result<u64, Status>

Max commit_ts among the versioned keys whose slot-0 head term falls under head_prefixes. Every version counts — liveness is not evaluated — so the result only ever overestimates the true bound, which is safe for the geo upgrade’s stage-1 swap timestamp.
Source§

impl HexastoreCatalog for GrpcHexastoreClients

Source§

async fn list_named_graphs( &self, snapshot: SnapshotId, ) -> Result<Vec<EncodedTerm>, Status>

Named-node graph IRIs visible at snapshot.
Source§

async fn add_named_graph( &self, graph: &EncodedTerm, commit_ts: CommitTs, ) -> Result<(), Status>

Insert an empty named graph, or no-op if already Present.
Source§

impl HexastoreCompact for GrpcHexastoreClients

Source§

async fn compact_range(&self, axis: PartitionAxis) -> Result<(), Status>

Ask axis to compact both column families (no-op on memory backends).
Source§

impl HexastoreFlush for GrpcHexastoreClients

Source§

async fn flush_memtables(&self, axis: PartitionAxis) -> Result<(), Status>

Ask axis to flush its RocksDB MemTables (no-op on memory backends).
Source§

impl HexastoreGeo for GrpcHexastoreClients

Source§

async fn rebuild_geo_index(&self) -> Result<(bool, bool, u64), Status>

Begin the O-axis geo index rebuild: take the lease and wipe the CF. Returns (started, already_in_progress, upgrade_ts) — the upgrade ts is the partition’s max commit_ts at lease take and is the ts every ReplaceQuads row of this rebuild must carry; the CALLING compute then drives the walk and finishes (unlike temporal, the walk is not partition-owned).
Source§

async fn renew_geo_rebuild_lease(&self) -> Result<(), Status>

Refresh the geo rebuild lease (the driver calls this per batch so a slow walk is not taken over).
Source§

async fn finish_geo_index_rebuild(&self) -> Result<u64, Status>

Finish the geo index rebuild: stamp the partition’s max-seen commit_ts as the epoch and release the lease. Returns the epoch.
Source§

async fn put_geo_index(&self, puts: &[GeoIndexPut]) -> Result<u64, Status>

Apply geometry-index postings on the O partition.
Source§

async fn delete_geo_term(&self, term: &[u8]) -> Result<u64, Status>

Delete every posting of one encoded geo term (rebuild support).
Source§

async fn geo_candidate_scan( &self, intervals: &[GeoCellInterval], snapshot: SnapshotId, query_envelope: Option<GeoEnvelope>, limit: u64, ) -> Result<TermPageStream, Status>

Drain the merged cell-interval candidate scan as term pages. query_envelope enables the partition-side AABB reject; limit of 0 is unlimited (and is a per-drain cap, not a cursor).
Source§

async fn put_temporal_index( &self, puts: &[TemporalIndexPut], ) -> Result<u64, Status>

Apply temporal-index postings on the O partition.
Source§

async fn temporal_candidate_scan( &self, intervals: &[TemporalCellInterval], snapshot: SnapshotId, predicate: TemporalQueryPredicate, limit: u64, ) -> Result<TermPageStream, Status>

Drain the merged key-interval candidate scan as term pages. The exact-interval predicate rejects postings partition-side; limit of 0 is unlimited (and is a per-drain cap, not a cursor).
Source§

async fn rebuild_temporal_index( &self, config: DyadicCovererConfig, ) -> Result<(bool, bool), Status>

Trigger the O-axis temporal index rebuild. Returns (started, already_in_progress) — see the proto contract; concurrent callers poll Describe for the epoch instead of blocking here.
Source§

async fn put_text_index(&self, docs: &[TextIndexDoc]) -> Result<u64, Status>

Append text-index documents on the O partition (text plugin). Sent BEFORE the three axis InsertQuads calls, so a visible row never lacks its document. The partition commits and reloads its reader before acknowledging.
Source§

async fn text_candidate_scan( &self, request: &TextSearchRequest, snapshot: SnapshotId, ) -> Result<TermPageStream, Status>

Drain one text candidate request as term pages. One RPC drains the whole distinct candidate set; limit of 0 is unlimited (and is a per-drain guard that errors, not a cursor).
Source§

async fn text_subject_scan( &self, request: &TextSubjectRequest, snapshot: SnapshotId, ) -> Result<SubjectRowStream, Status>

Resolve one text search to DISTINCT subjects on the O partition. Read more
Source§

async fn rebuild_text_index( &self, analyzer: &str, seed_chars: u32, fingerprint: &str, wipe: bool, ) -> Result<(bool, bool, u64), Status>

Open-or-create the text index with an explicit config, optionally wipe, and take the rebuild lease. Returns (started, already_in_progress, lease_token) — the token is the caller’s proof of lease ownership (non-zero exactly when started); every renew / finish must carry it. The calling compute drives the walk and finishes with Self::finish_text_index_rebuild.
Source§

async fn renew_text_rebuild_lease(&self, lease_token: u64) -> Result<(), Status>

Refresh the text rebuild lease (driver keepalive per batch). Rejected unless lease_token identifies the current fresh lease.
Source§

async fn finish_text_index_rebuild( &self, lease_token: u64, stamp: bool, ) -> Result<u64, Status>

Finish the text index rebuild: release the lease, and — when stamp — stamp the partition’s max-seen commit_ts as the epoch. stamp = false releases without stamping (the index stays untrusted). Returns the stamped epoch (0 when not stamping). Rejected unless lease_token identifies the current fresh lease.
Source§

impl HexastoreInsert for GrpcHexastoreClients

Source§

async fn insert_quads( &self, axis: PartitionAxis, versions: &[QuadVersion], ) -> Result<u64, Status>

Apply versions on axis (asserted in the request for axis isolation).
Source§

async fn replace_quads( &self, pairs: &[ReplacePair], commit_ts: CommitTs, ) -> Result<u64, Status>

Atomically replace object terms on EVERY axis (the migration primitive; see the proto contract). Returns the summed replaced count across S/P/O.
Source§

impl HexastoreScan for GrpcHexastoreClients

Source§

async fn scan_pattern( &self, axis: PartitionAxis, pattern: &EncodedTriplePattern, snapshot: SnapshotId, limit: u64, permutation: Option<IndexPermutation>, filter: Option<&BroadcastFilter>, graph_filter: Option<&GraphFilter>, start_after: Option<&EncodedQuad>, merge_default_graph: bool, iri_only: IriOnlyMask, omitted: u8, verdict_wanted: bool, ) -> Result<ScanPage, Status>

Encoded rows matching pattern; limit of 0 is unlimited. Read more
Source§

async fn scan_pattern_with_comparisons( &self, axis: PartitionAxis, pattern: &EncodedTriplePattern, snapshot: SnapshotId, limit: u64, permutation: Option<IndexPermutation>, filter: Option<&BroadcastFilter>, graph_filter: Option<&GraphFilter>, start_after: Option<&EncodedQuad>, merge_default_graph: bool, iri_only: IriOnlyMask, comparisons: &[SlotComparison], omitted: u8, verdict_wanted: bool, ) -> Result<ScanPage, Status>

Self::scan_pattern with slot comparison pushdown. Read more
Source§

async fn scan_pattern_stream( &self, axis: PartitionAxis, pattern: &EncodedTriplePattern, snapshot: SnapshotId, limit: u64, permutation: Option<IndexPermutation>, filter: Option<&BroadcastFilter>, graph_filter: Option<&GraphFilter>, start_after: Option<&EncodedQuad>, merge_default_graph: bool, iri_only: IriOnlyMask, omitted: u8, verdict_wanted: bool, ) -> Result<QuadPageStream, Status>

Storage-driven drain of pattern as a QuadPageStream. Read more
Source§

async fn scan_pattern_stream_with_comparisons( &self, axis: PartitionAxis, pattern: &EncodedTriplePattern, snapshot: SnapshotId, limit: u64, permutation: Option<IndexPermutation>, filter: Option<&BroadcastFilter>, graph_filter: Option<&GraphFilter>, start_after: Option<&EncodedQuad>, merge_default_graph: bool, iri_only: IriOnlyMask, comparisons: &[SlotComparison], omitted: u8, verdict_wanted: bool, ) -> Result<QuadPageStream, Status>

Self::scan_pattern_stream with slot comparison pushdown. Read more
Source§

async fn count_pattern( &self, axis: PartitionAxis, pattern: &EncodedTriplePattern, snapshot: SnapshotId, limit: u64, permutation: Option<IndexPermutation>, filter: Option<&BroadcastFilter>, graph_filter: Option<&GraphFilter>, merge_default_graph: bool, ) -> Result<u64, Status>

Count matching quads without returning rows; limit of 0 is unlimited. Read more
Source§

async fn scan_domain( &self, permutation: IndexPermutation, constraints: &[EncodedTerm], snapshot: SnapshotId, limit: u64, start_after_constraint: Option<&EncodedTerm>, start_after_term: Option<&EncodedTerm>, graph_name: Option<&EncodedTerm>, graph_filter: Option<&GraphFilter>, iri_only_head: bool, ) -> Result<Vec<DomainScanHit>, Status>

Constrained domain scan: distinct slot-1 head terms under each slot-0 constraint of permutation (POSG predicates→objects, SPOG subjects→predicates, SOPG subjects→objects, OPSG objects→predicates). Read more
Source§

async fn scan_domain_counts( &self, permutation: IndexPermutation, constraints: &[EncodedTerm], snapshot: SnapshotId, limit: u64, start_after_constraint: Option<&EncodedTerm>, start_after_term: Option<&EncodedTerm>, graph_name: Option<&EncodedTerm>, graph_filter: Option<&GraphFilter>, iri_only_head: bool, merge_default_graph: bool, mode: DomainCountMode, ) -> Result<Vec<DomainScanCountHit>, Status>

Constrained domain count scan: run lengths of slot-1 head terms under each slot-0 constraint of permutation — the same constraint/head families and cursor semantics as Self::scan_domain, but the graph window applies per row (a head in n graphs of the window counts n) unless merge_default_graph is set. Merge counts distinct S/P/O prefixes and seeks past extra G. Zero-count runs are not emitted, and each hit carries the multiplicity of its (constraint, head) pair.
Source§

async fn scan_axis_head( &self, permutation: IndexPermutation, snapshot: SnapshotId, limit: u64, start_after_term: Option<&EncodedTerm>, graph_name: Option<&EncodedTerm>, graph_filter: Option<&GraphFilter>, iri_only_head: bool, head_prefixes: &[Vec<u8>], ) -> Result<Vec<EncodedTerm>, Status>

Bare axis head scan: distinct slot-0 head terms of the whole CF for permutation (SPOG subjects, PSOG predicates, OPSG objects, TSG classes). No anchor terms; same graph-window semantics and exclusive single-term cursor as Self::scan_domain. head_prefixes are opaque seek-union byte ranges: when non-empty, only heads whose encoded bytes start with one of them are visited (empty = unfiltered).
Source§

async fn count_axis_heads( &self, permutation: IndexPermutation, snapshot: SnapshotId, graph_name: Option<&EncodedTerm>, graph_filter: Option<&GraphFilter>, iri_only_head: bool, ) -> Result<u64, Status>

Axis head count, TOTAL mode: the number of distinct slot-0 head terms of the whole CF for permutation.
Source§

async fn scan_axis_head_counts( &self, permutation: IndexPermutation, snapshot: SnapshotId, limit: u64, start_after_term: Option<&EncodedTerm>, graph_name: Option<&EncodedTerm>, graph_filter: Option<&GraphFilter>, iri_only_head: bool, ) -> Result<Vec<AxisHeadCountHit>, Status>

Axis head count, PER_HEAD mode: per-head distinct slot-1 counts, paged at head boundaries with an exclusive resume cursor.
Source§

fn scan_pattern_detached( &self, axis: PartitionAxis, pattern: &EncodedTriplePattern, snapshot: SnapshotId, limit: u64, permutation: Option<IndexPermutation>, filter: Option<&BroadcastFilter>, graph_filter: Option<&GraphFilter>, start_after: Option<&EncodedQuad>, merge_default_graph: bool, iri_only: IriOnlyMask, omitted: u8, verdict_wanted: bool, ) -> JoinHandle<Result<(Vec<EncodedQuad>, Option<ScanExhaustion>), Status>>

Fetch up to limit rows in a detached task that owns a clone of the client; the returned handle completes with the rows and the walk’s verdict once the task finishes. Read more
Source§

fn scan_pattern_detached_with_comparisons( &self, axis: PartitionAxis, pattern: &EncodedTriplePattern, snapshot: SnapshotId, limit: u64, permutation: Option<IndexPermutation>, filter: Option<&BroadcastFilter>, graph_filter: Option<&GraphFilter>, start_after: Option<&EncodedQuad>, merge_default_graph: bool, iri_only: IriOnlyMask, comparisons: &[SlotComparison], omitted: u8, verdict_wanted: bool, ) -> JoinHandle<Result<(Vec<EncodedQuad>, Option<ScanExhaustion>), Status>>

Self::scan_pattern_detached with slot comparison pushdown. Read more
Source§

impl HexastoreStats for GrpcHexastoreClients

Source§

async fn stats_profile(&self, axis: PartitionAxis) -> Result<Vec<u8>, Status>

Serialized CORE waratah_stats::StatsProfile blob from axis (geo/temporal sections empty — each rides its own frame below).
Source§

async fn geo_histogram( &self, axis: PartitionAxis, section: GeoHistogramSection, ) -> Result<Vec<u8>, Status>

ONE geo cell-count histogram frame from axis: self-versioned GeoCellHistogram section bytes carrying exactly the requested map (the unrequested maps empty — subset-populated sections are valid merge inputs on their own).
Source§

async fn temporal_histogram( &self, axis: PartitionAxis, ) -> Result<Vec<u8>, Status>

The temporal tick histogram frame from axis: self-versioned TickHistogram section bytes (bounded by construction, untrimmed).
Source§

async fn text_seed_sketch(&self, axis: PartitionAxis) -> Result<Vec<u8>, Status>

The text seed-population sketch frame from axis: self-versioned TextSeedSketch section bytes, wire-trimmed deepest-first at the partition. Empty bytes = no trusted sketch (never built, wiped, or undecodable) — the caller keeps its unpriced estimate.

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<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.

§

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

§

fn from_ref(input: &T) -> T

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

impl<T> Instrument for T

§

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

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

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.

§

impl<T> IntoRequest<T> for T

§

fn into_request(self) -> Request<T>

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

impl<L> LayerExt<L> for L

§

fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>
where L: Layer<S>,

Applies the layer to a service and wraps it in [Layered].
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
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.
§

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

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

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
§

fn with_current_subscriber(self) -> WithDispatch<Self>

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

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

§

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

§

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