pub trait ConversationStorage:
Send
+ Sync
+ 'static {
// Required methods
fn create_conversation<'life0, 'async_trait>(
&'life0 self,
input: NewConversation,
) -> Pin<Box<dyn Future<Output = Result<Conversation, ConversationStorageError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_conversation<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 ConversationId,
) -> Pin<Box<dyn Future<Output = Result<Option<Conversation>, ConversationStorageError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn update_conversation<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 ConversationId,
metadata: Option<Map<String, Value>>,
) -> Pin<Box<dyn Future<Output = Result<Option<Conversation>, ConversationStorageError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn delete_conversation<'life0, 'life1, 'async_trait>(
&'life0 self,
id: &'life1 ConversationId,
) -> Pin<Box<dyn Future<Output = Result<bool, ConversationStorageError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}Expand description
Trait describing the CRUD interface for conversation storage backends