Skip to main content

RuntimeEntityPort

Trait RuntimeEntityPort 

Source
pub trait RuntimeEntityPort {
Show 16 methods // Required methods fn create_row( &self, input: CreateRowInput, ) -> RedDBResult<CreateEntityOutput>; fn create_rows_batch( &self, input: CreateRowsBatchInput, ) -> RedDBResult<Vec<CreateEntityOutput>>; fn create_rows_batch_prevalidated( &self, input: CreateRowsBatchInput, ) -> RedDBResult<usize>; fn create_rows_batch_prevalidated_columnar( &self, collection: String, column_names: Arc<Vec<String>>, rows: Vec<Vec<Value>>, ) -> RedDBResult<usize>; fn create_rows_batch_columnar( &self, collection: String, column_names: Arc<Vec<String>>, rows: Vec<Vec<Value>>, ) -> RedDBResult<usize>; fn create_rows_batch_columnar_with_outputs( &self, collection: String, column_names: Arc<Vec<String>>, rows: Vec<Vec<Value>>, ) -> RedDBResult<Vec<CreateEntityOutput>>; fn create_node( &self, input: CreateNodeInput, ) -> RedDBResult<CreateEntityOutput>; fn create_edge( &self, input: CreateEdgeInput, ) -> RedDBResult<CreateEntityOutput>; fn create_vector( &self, input: CreateVectorInput, ) -> RedDBResult<CreateEntityOutput>; fn create_document( &self, input: CreateDocumentInput, ) -> RedDBResult<CreateEntityOutput>; fn create_kv(&self, input: CreateKvInput) -> RedDBResult<CreateEntityOutput>; fn create_timeseries_point( &self, input: CreateTimeSeriesPointInput, ) -> RedDBResult<CreateEntityOutput>; fn get_kv( &self, collection: &str, key: &str, ) -> RedDBResult<Option<(Value, EntityId)>>; fn delete_kv(&self, collection: &str, key: &str) -> RedDBResult<bool>; fn patch_entity( &self, input: PatchEntityInput, ) -> RedDBResult<CreateEntityOutput>; fn delete_entity( &self, input: DeleteEntityInput, ) -> RedDBResult<DeleteEntityOutput>;
}

Required Methods§

Source

fn create_row(&self, input: CreateRowInput) -> RedDBResult<CreateEntityOutput>

Source

fn create_rows_batch( &self, input: CreateRowsBatchInput, ) -> RedDBResult<Vec<CreateEntityOutput>>

Source

fn create_rows_batch_prevalidated( &self, input: CreateRowsBatchInput, ) -> RedDBResult<usize>

Pre-validated bulk insert — caller has already checked column types and uniqueness. Server skips normalize_row_fields_for_contract, enforce_row_uniqueness, and enforce_row_batch_uniqueness. Returns the row count. Used by MSG_BULK_INSERT_PREVALIDATED.

Source

fn create_rows_batch_prevalidated_columnar( &self, collection: String, column_names: Arc<Vec<String>>, rows: Vec<Vec<Value>>, ) -> RedDBResult<usize>

Columnar pre-validated bulk insert — the wire handler decoded straight into Vec<Vec<Value>> + a shared column- name vector, no per-cell (String, Value) tuples allocated. Avoids ~N×ncols String clones vs the tuple path. The schema is shared across every row as a single Arc<Vec<String>>.

Source

fn create_rows_batch_columnar( &self, collection: String, column_names: Arc<Vec<String>>, rows: Vec<Vec<Value>>, ) -> RedDBResult<usize>

Columnar bulk insert with full contract validation — wire handler shape (one Arc<Vec<String>> schema shared across every row, Vec<Vec<Value>> row payload). Equivalent to create_rows_batch semantically but skips the per-row (String, Value) tuple materialisation in the wire decoder. When the collection has no contract (or no declared columns) fast-paths to create_rows_batch_prevalidated_columnar; otherwise falls back to the tuple path so contract normalisation can run.

Source

fn create_rows_batch_columnar_with_outputs( &self, collection: String, column_names: Arc<Vec<String>>, rows: Vec<Vec<Value>>, ) -> RedDBResult<Vec<CreateEntityOutput>>

Columnar bulk insert that also returns assigned entity ids. Kept separate from Self::create_rows_batch_columnar so bulk wire callers can retain their count-only contract.

Source

fn create_node(&self, input: CreateNodeInput) -> RedDBResult<CreateEntityOutput>

Source

fn create_edge(&self, input: CreateEdgeInput) -> RedDBResult<CreateEntityOutput>

Source

fn create_vector( &self, input: CreateVectorInput, ) -> RedDBResult<CreateEntityOutput>

Source

fn create_document( &self, input: CreateDocumentInput, ) -> RedDBResult<CreateEntityOutput>

Source

fn create_kv(&self, input: CreateKvInput) -> RedDBResult<CreateEntityOutput>

Source

fn create_timeseries_point( &self, input: CreateTimeSeriesPointInput, ) -> RedDBResult<CreateEntityOutput>

Source

fn get_kv( &self, collection: &str, key: &str, ) -> RedDBResult<Option<(Value, EntityId)>>

Source

fn delete_kv(&self, collection: &str, key: &str) -> RedDBResult<bool>

Source

fn patch_entity( &self, input: PatchEntityInput, ) -> RedDBResult<CreateEntityOutput>

Source

fn delete_entity( &self, input: DeleteEntityInput, ) -> RedDBResult<DeleteEntityOutput>

Implementors§