Skip to navigation

Generated from cargo doc --no-deps -p nemo-relay-builtins -p nemo-relay-diagnostics -p nemo-relay-logging -p nemo-relay-plugin-host -p nemo-relay-codecs -p nemo-relay -p nemo-relay-runtime -p nemo-relay-model-pricing -p nemo-relay-resource-metrics -p nemo-relay-observability -p nemo-relay-adaptive -p nemo-relay-pii-redaction -p nemo-relay-ffi -p nemo-relay-types -p nemo-relay-plugin -p nemo-relay-worker-proto -p nemo-relay-worker.

pub trait StorageBackend:
Send
+ Sync
+ 'static {
// Required methods
fn store_run(
&self,
record: &RunRecord,
) -> impl Future<Output = Result<()>> + Send;
fn load_plan(
&self,
agent_id: &str,
) -> impl Future<Output = Result<Option<ExecutionPlan>>> + Send;
fn list_runs(
&self,
agent_id: &str,
) -> impl Future<Output = Result<Vec<RunRecord>>> + Send;
}

Referenced types: Send, Sync, RunRecord, Future, Result, (), str, Option, ExecutionPlan, Vec

Minimal async storage interface required by the adaptive runtime.

Required Methods

store_run

fn store_run(
&self,
record: &RunRecord,
) -> impl Future<Output = Result<()>> + Send

Referenced types: RunRecord, Future, Result, (), Send

Persist one observed run.

load_plan

fn load_plan(
&self,
agent_id: &str,
) -> impl Future<Output = Result<Option<ExecutionPlan>>> + Send

Referenced types: str, Future, Result, Option, ExecutionPlan, Send

Load the current execution plan for an agent.

list_runs

fn list_runs(
&self,
agent_id: &str,
) -> impl Future<Output = Result<Vec<RunRecord>>> + Send

Referenced types: str, Future, Result, Vec, RunRecord, Send

List stored runs for an agent.

Dyn Compatibility

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called “object safety”, so this trait is not object safe.

Implementors

impl StorageBackend for RedisBackend

impl StorageBackend for RedisBackend

Referenced types: StorageBackend, RedisBackend

impl StorageBackend for InMemoryBackend

impl StorageBackend for InMemoryBackend

Referenced types: StorageBackend, InMemoryBackend