pub trait RagTransport: Send + Sync {
// Required methods
fn push_docs<'life0, 'async_trait>(
&'life0 self,
docs: Vec<WireDoc>,
) -> Pin<Box<dyn Future<Output = Result<(), RagError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn delete_paths<'life0, 'async_trait>(
&'life0 self,
paths: Vec<String>,
) -> Pin<Box<dyn Future<Output = Result<(), RagError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn server_hashes<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<HashMap<String, String>, RagError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Expand description
The subset of server operations the sync orchestration depends on, behind a
trait so it can be exercised with a fake in tests. RagClient is the real
implementation.
Required Methods§
fn push_docs<'life0, 'async_trait>(
&'life0 self,
docs: Vec<WireDoc>,
) -> Pin<Box<dyn Future<Output = Result<(), RagError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn delete_paths<'life0, 'async_trait>(
&'life0 self,
paths: Vec<String>,
) -> Pin<Box<dyn Future<Output = Result<(), RagError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn server_hashes<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<HashMap<String, String>, RagError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".