pub trait IncrementalGraphStore: Send + Sync {
type Error: Error + Send + Sync + 'static;
Show 17 methods
// Required methods
fn upsert_entity<'life0, 'async_trait>(
&'life0 mut self,
entity: Entity,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn upsert_relationship<'life0, 'async_trait>(
&'life0 mut self,
relationship: Relationship,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn delete_entity<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity_id: &'life1 EntityId,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn delete_relationship<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 mut self,
source: &'life1 EntityId,
target: &'life2 EntityId,
relation_type: &'life3 str,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait;
fn apply_delta<'life0, 'async_trait>(
&'life0 mut self,
delta: GraphDelta,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn rollback_delta<'life0, 'life1, 'async_trait>(
&'life0 mut self,
delta_id: &'life1 UpdateId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_change_log<'life0, 'async_trait>(
&'life0 self,
since: Option<DateTime<Utc>>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ChangeRecord>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn begin_transaction<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<TransactionId>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn commit_transaction<'life0, 'async_trait>(
&'life0 mut self,
tx_id: TransactionId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn rollback_transaction<'life0, 'async_trait>(
&'life0 mut self,
tx_id: TransactionId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn batch_upsert_entities<'life0, 'async_trait>(
&'life0 mut self,
entities: Vec<Entity>,
_strategy: ConflictStrategy,
) -> Pin<Box<dyn Future<Output = Result<Vec<UpdateId>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn batch_upsert_relationships<'life0, 'async_trait>(
&'life0 mut self,
relationships: Vec<Relationship>,
_strategy: ConflictStrategy,
) -> Pin<Box<dyn Future<Output = Result<Vec<UpdateId>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn update_entity_embedding<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity_id: &'life1 EntityId,
embedding: Vec<f32>,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn bulk_update_embeddings<'life0, 'async_trait>(
&'life0 mut self,
updates: Vec<(EntityId, Vec<f32>)>,
) -> Pin<Box<dyn Future<Output = Result<Vec<UpdateId>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_pending_transactions<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<TransactionId>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_graph_statistics<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<GraphStatistics>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn validate_consistency<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<ConsistencyReport>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
Extended trait for incremental graph operations with production-ready features
Required Associated Types§
Required Methods§
Sourcefn upsert_entity<'life0, 'async_trait>(
&'life0 mut self,
entity: Entity,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn upsert_entity<'life0, 'async_trait>(
&'life0 mut self,
entity: Entity,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Upsert an entity (insert or update)
Sourcefn upsert_relationship<'life0, 'async_trait>(
&'life0 mut self,
relationship: Relationship,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn upsert_relationship<'life0, 'async_trait>(
&'life0 mut self,
relationship: Relationship,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Upsert a relationship
Sourcefn delete_entity<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity_id: &'life1 EntityId,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn delete_entity<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity_id: &'life1 EntityId,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Delete an entity and its relationships
Sourcefn delete_relationship<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 mut self,
source: &'life1 EntityId,
target: &'life2 EntityId,
relation_type: &'life3 str,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
fn delete_relationship<'life0, 'life1, 'life2, 'life3, 'async_trait>(
&'life0 mut self,
source: &'life1 EntityId,
target: &'life2 EntityId,
relation_type: &'life3 str,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
'life3: 'async_trait,
Delete a relationship
Sourcefn apply_delta<'life0, 'async_trait>(
&'life0 mut self,
delta: GraphDelta,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn apply_delta<'life0, 'async_trait>(
&'life0 mut self,
delta: GraphDelta,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Apply a batch of changes atomically
Sourcefn rollback_delta<'life0, 'life1, 'async_trait>(
&'life0 mut self,
delta_id: &'life1 UpdateId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn rollback_delta<'life0, 'life1, 'async_trait>(
&'life0 mut self,
delta_id: &'life1 UpdateId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Rollback a delta
Sourcefn get_change_log<'life0, 'async_trait>(
&'life0 self,
since: Option<DateTime<Utc>>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ChangeRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_change_log<'life0, 'async_trait>(
&'life0 self,
since: Option<DateTime<Utc>>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ChangeRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get change history
Sourcefn begin_transaction<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<TransactionId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn begin_transaction<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<TransactionId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Start a transaction for atomic operations
Sourcefn commit_transaction<'life0, 'async_trait>(
&'life0 mut self,
tx_id: TransactionId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn commit_transaction<'life0, 'async_trait>(
&'life0 mut self,
tx_id: TransactionId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Commit a transaction
Sourcefn rollback_transaction<'life0, 'async_trait>(
&'life0 mut self,
tx_id: TransactionId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn rollback_transaction<'life0, 'async_trait>(
&'life0 mut self,
tx_id: TransactionId,
) -> Pin<Box<dyn Future<Output = Result<()>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Rollback a transaction
Sourcefn batch_upsert_entities<'life0, 'async_trait>(
&'life0 mut self,
entities: Vec<Entity>,
_strategy: ConflictStrategy,
) -> Pin<Box<dyn Future<Output = Result<Vec<UpdateId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn batch_upsert_entities<'life0, 'async_trait>(
&'life0 mut self,
entities: Vec<Entity>,
_strategy: ConflictStrategy,
) -> Pin<Box<dyn Future<Output = Result<Vec<UpdateId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Batch upsert entities with conflict resolution
Sourcefn batch_upsert_relationships<'life0, 'async_trait>(
&'life0 mut self,
relationships: Vec<Relationship>,
_strategy: ConflictStrategy,
) -> Pin<Box<dyn Future<Output = Result<Vec<UpdateId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn batch_upsert_relationships<'life0, 'async_trait>(
&'life0 mut self,
relationships: Vec<Relationship>,
_strategy: ConflictStrategy,
) -> Pin<Box<dyn Future<Output = Result<Vec<UpdateId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Batch upsert relationships with conflict resolution
Sourcefn update_entity_embedding<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity_id: &'life1 EntityId,
embedding: Vec<f32>,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn update_entity_embedding<'life0, 'life1, 'async_trait>(
&'life0 mut self,
entity_id: &'life1 EntityId,
embedding: Vec<f32>,
) -> Pin<Box<dyn Future<Output = Result<UpdateId>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Update entity embeddings incrementally
Sourcefn bulk_update_embeddings<'life0, 'async_trait>(
&'life0 mut self,
updates: Vec<(EntityId, Vec<f32>)>,
) -> Pin<Box<dyn Future<Output = Result<Vec<UpdateId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn bulk_update_embeddings<'life0, 'async_trait>(
&'life0 mut self,
updates: Vec<(EntityId, Vec<f32>)>,
) -> Pin<Box<dyn Future<Output = Result<Vec<UpdateId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Bulk update embeddings for performance
Sourcefn get_pending_transactions<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<TransactionId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_pending_transactions<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<Vec<TransactionId>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get pending transactions
Sourcefn get_graph_statistics<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<GraphStatistics>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_graph_statistics<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<GraphStatistics>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Get graph statistics
Sourcefn validate_consistency<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<ConsistencyReport>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn validate_consistency<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<ConsistencyReport>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Validate graph consistency