Skip to main content

Crate waratah_proto

Crate waratah_proto 

Source
Expand description

Waratah wire contract (waratah.v1).

Three services, owned by different processes of the local-dev cluster:

ServiceRPCsServed by
Hexastoredata-plane plus Health / DescribeS / P / O partitions (ListNamedGraphs / AddNamedGraph are S-axis only; DomainScan / AxisHeadScan accept only permutations owned by the serving axis; others return UNIMPLEMENTED)
StringRegistryRegisterStrings, ResolveStrings, FlushMemtables, CompactRange, Health, Describestring-registry process
ComputeHealth, Describe (identity + advertised HTTP URLs + routing table; no storage probes)compute coordinator

Hexastore payloads carry encoded terms only (waratah_storage::StrHash references and inline small terms); raw strings appear solely on the registry service, which compute calls for final output bindings.

Re-exports§

pub use pb::compute_client::ComputeClient;
pub use pb::compute_server::Compute;
pub use pb::compute_server::ComputeServer;
pub use pb::hexastore_client::HexastoreClient;
pub use pb::hexastore_server::Hexastore;
pub use pb::hexastore_server::HexastoreServer;
pub use pb::string_registry_client::StringRegistryClient;
pub use pb::string_registry_server::StringRegistry;
pub use pb::string_registry_server::StringRegistryServer;

Modules§

pb
Generated waratah.v1 messages, clients, and server traits.

Structs§

QuadVersion
One decoded hexastore record: quad plus its Phase 2b version metadata.

Enums§

PatternSlot
Which pattern slot a broadcast filter applies to.
ProtoError
Failure decoding a waratah.v1 message into storage-layer types.

Constants§

GRPC_MAX_MESSAGE_SIZE
Maximum size of one gRPC message, pinned explicitly on every client endpoint and server service in the cluster (tonic’s default is the same 4 MiB today; setting it keeps the ceiling deterministic across tonic upgrades). Unary responses that could exceed it — an unlimited ScanPattern over a large prefix — must use ScanPatternStream instead; every streaming batch stays comfortably below it.
OMIT_GRAPH
omitted_slots bit for the graph slot.
OMIT_NONE
No slot omitted.
OMIT_OBJECT
omitted_slots bit for the object slot.
OMIT_PREDICATE
omitted_slots bit for the predicate slot.
OMIT_SUBJECT
omitted_slots bit for the subject slot.
SCAN_STREAM_FRAME_ROWS
Rows per streaming frame of a ScanPatternStream response. This is the wire-chunking unit of a scan (the partition packs a walk into frames of this many rows and pauses on channel backpressure) — it is not a compute-side demand: clients request a row count per RPC and the response arrives as ceil(n / SCAN_STREAM_FRAME_ROWS) frames, reassembled by the client-side drainer. Compute consumers therefore never see frame boundaries; the constant matters here on the wire and as the transport floor for compute-side page demands.
WORST_CASE_QUAD_WIRE
Worst-case serialized bytes one row contributes to a ScanPatternResponse, dividing GRPC_MAX_MESSAGE_SIZE into the maximum row count a unary scan response may carry. Worked from the term-encoding invariant and proto framing, per row:

Functions§

add_named_graph_request
Build an AddNamedGraph request (S-axis catalog; NamedNode only).
axis_from_proto
Map a wire axis value; UNSPECIFIED means “caller did not assert an axis”.
axis_to_proto
Map a partition axis onto its wire enum value.
blocking_join_error
Map a spawn_blocking join failure (handler panic or runtime shutdown) to a tonic::Status.
count_mode_from_proto
Map a wire domain-count mode; ROWS is the zero default.
count_mode_to_proto
Map a storage domain-count mode onto its wire enum value.
insert_request
Build an InsertQuads request asserting the target axis.
list_named_graphs_request
Build a ListNamedGraphs request (S-axis catalog; includes empty graphs).
op_from_proto
Map a wire operation value; UNSPECIFIED is rejected.
op_to_proto
Map a storage operation onto its wire enum value.
pattern_from_proto
Decode a partially-bound pattern from the wire.
pattern_slot_from_proto
Map a wire pattern slot; UNSPECIFIED is None.
pattern_slot_to_proto
Encode a pattern slot for the wire.
pattern_to_proto
Encode a partially-bound pattern for the wire.
permutation_from_proto
Map a wire permutation value; UNSPECIFIED lets the partition choose.
permutation_to_proto
Map an index permutation onto its wire enum value.
quad_from_proto
Decode a quad from the wire.
quad_from_proto_omitting
Decode a quad whose slots may have been omitted, reassembling them exactly.
quad_to_proto
Encode a quad for the wire.
quad_version_from_proto
Decode a quad version from the wire.
quad_version_to_proto
Encode a versioned record for the wire.
register_request
Build a RegisterStrings request from (hash, raw) pairs.
replace_pair_from_proto
Decode one replace pair from the wire.
replace_pair_to_proto
Decode a versioned record from the wire. Encode one replace pair for the wire.
resolve_request
Build a ResolveStrings request.
scan_exhaustion_from_proto
Map a present wire scan-exhaustion verdict. Unknown NON-ZERO values (a future enum addition this client does not know) read as Limited — the safe “stopped at a demand boundary; resume or infer” reading, never a terminal claim. The zero placeholder is handled one layer up by scan_exhaustion_from_proto_opt, which maps it to absence per the wire contract.
scan_exhaustion_from_proto_opt
Map an optional wire verdict: unset — or an explicit UNSPECIFIED zero, the placeholder the wire contract says “reads as no verdict” — means no verdict was purchased and nothing is claimed. Without this filter, a zero from a future peer would collapse through the safe fallback into Some(Limited), contradicting the contract and making “a purchased Limited” indistinguishable from “nothing claimed”.
scan_exhaustion_to_proto
Map a storage scan-exhaustion verdict onto its wire enum value.
scan_request
Build a ScanPattern / CountPattern request.
scan_request_filtered
Build a ScanPattern request with an optional broadcast filter set.
scan_request_page
Build a ScanPattern request with an exclusive start_after cursor.
slot_comparison_from_proto
Decode one slot comparison.
slot_comparison_to_proto
Encode one slot comparison for the wire.
slot_comparisons_from_proto
Decode a comparison list.
slot_comparisons_to_proto
Encode a comparison list for the wire.
slot_mask_from_wire
Validate an omitted_slots field: only the four slot bits may be set.
str_hash_from_bytes
Decode a 16-byte big-endian StrHash.
str_hash_to_bytes
Serialize a StrHash as 16 big-endian bytes.
term_from_bytes
Decode exactly one encoded term; empty input is the default graph.
term_to_bytes
Serialize one encoded term. The default graph serializes to zero bytes.
text_index_doc_from_proto
Decode one text-index document from the wire.
text_index_doc_to_proto
Encode one text-index document for the wire.
with_comparisons
Attach slot comparisons to a scan request (ANDed in list order).
with_omitted_slots
Mark response slots the partition should leave empty.
with_verdict_wanted
Set the consumer’s exhaustion-verdict declaration (see the verdict_wanted field on ScanPatternRequest): true only when a full page would be followed by another request, so the walk should keep scanning past a full page to report an honest terminal verdict at exact limit boundaries. The proto default (false) stops the walk at the limit’th row.