pub trait RemoteStore: Send + Sync {
// Required methods
fn fetch_raw(&self, cid: &VoidCid) -> Result<Vec<u8>>;
fn push_raw(&self, data: &[u8]) -> Result<VoidCid>;
fn exists(&self, cid: &VoidCid) -> Result<bool>;
fn pin(&self, cid: &VoidCid) -> Result<()>;
}Expand description
Remote content-addressed storage.
Object-safe — can be used as dyn RemoteStore and Arc<dyn RemoteStore>.
All operations use raw bytes. Typed EncryptedBlob wrapping happens
in the callers, not here.
Required Methods§
Sourcefn fetch_raw(&self, cid: &VoidCid) -> Result<Vec<u8>>
fn fetch_raw(&self, cid: &VoidCid) -> Result<Vec<u8>>
Fetch raw bytes by CID.
Implementations must verify the fetched content hash matches the CID.