Trait object_store::signer::Signer

source ·
pub trait Signer: Send + Sync + Debug + 'static {
    // Required method
    fn signed_url<'life0, 'life1, 'async_trait>(
        &'life0 self,
        method: Method,
        path: &'life1 Path,
        expires_in: Duration
    ) -> Pin<Box<dyn Future<Output = Result<Url>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;

    // Provided method
    fn signed_urls<'life0, 'life1, 'async_trait>(
        &'life0 self,
        method: Method,
        paths: &'life1 [Path],
        expires_in: Duration
    ) -> Pin<Box<dyn Future<Output = Result<Vec<Url>>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait { ... }
}
Expand description

Universal API to generate presigned URLs from multiple object store services.

Required Methods§

source

fn signed_url<'life0, 'life1, 'async_trait>( &'life0 self, method: Method, path: &'life1 Path, expires_in: Duration ) -> Pin<Box<dyn Future<Output = Result<Url>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Given the intended Method and Path to use and the desired length of time for which the URL should be valid, return a signed Url created with the object store implementation’s credentials such that the URL can be handed to something that doesn’t have access to the object store’s credentials, to allow limited access to the object store.

Provided Methods§

source

fn signed_urls<'life0, 'life1, 'async_trait>( &'life0 self, method: Method, paths: &'life1 [Path], expires_in: Duration ) -> Pin<Box<dyn Future<Output = Result<Vec<Url>>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Generate signed urls for multiple paths.

See Signer::signed_url for more details.

Implementors§