pub struct InMemoryTaskStore { /* private fields */ }Expand description
In-process task store with TTL expiry and LRU capacity eviction.
Implementations§
Source§impl InMemoryTaskStore
impl InMemoryTaskStore
Sourcepub fn with_config(config: InMemoryTaskStoreConfig) -> Self
pub fn with_config(config: InMemoryTaskStoreConfig) -> Self
Create a store with explicit TTL and capacity settings.
Trait Implementations§
Source§impl Debug for InMemoryTaskStore
impl Debug for InMemoryTaskStore
Source§impl Default for InMemoryTaskStore
impl Default for InMemoryTaskStore
Source§impl TaskStore for InMemoryTaskStore
impl TaskStore for InMemoryTaskStore
Source§fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
task_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Task>, A2AError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get<'life0, 'life1, 'async_trait>(
&'life0 self,
task_id: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<Task>, A2AError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Fetch a task by its identifier.
Source§fn put<'life0, 'life1, 'async_trait>(
&'life0 self,
task: &'life1 Task,
) -> Pin<Box<dyn Future<Output = Result<(), A2AError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn put<'life0, 'life1, 'async_trait>(
&'life0 self,
task: &'life1 Task,
) -> Pin<Box<dyn Future<Output = Result<(), A2AError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Insert or replace a task snapshot.
Source§fn list<'life0, 'life1, 'async_trait>(
&'life0 self,
req: &'life1 ListTasksRequest,
) -> Pin<Box<dyn Future<Output = Result<ListTasksResponse, A2AError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn list<'life0, 'life1, 'async_trait>(
&'life0 self,
req: &'life1 ListTasksRequest,
) -> Pin<Box<dyn Future<Output = Result<ListTasksResponse, A2AError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Implementations should reject invalid pagination inputs or delegate to
ListTasksRequest::validate() before applying query semantics.Auto Trait Implementations§
impl !Freeze for InMemoryTaskStore
impl !RefUnwindSafe for InMemoryTaskStore
impl Send for InMemoryTaskStore
impl Sync for InMemoryTaskStore
impl Unpin for InMemoryTaskStore
impl UnsafeUnpin for InMemoryTaskStore
impl UnwindSafe for InMemoryTaskStore
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more