pub struct ClientBuilder { /* private fields */ }Expand description
Service for storing and retrieving objects.
The Service contains the base configuration to connect to a service.
It has to be further initialized with credentials using the
for_organization and
for_project functions.
Implementations§
Source§impl ClientBuilder
impl ClientBuilder
Sourcepub fn new(service_url: &str, usecase: &str) -> Result<Self>
pub fn new(service_url: &str, usecase: &str) -> Result<Self>
Creates a new ClientBuilder.
This service instance is configured to target the given service_url.
It is also scoped for the given usecase.
In order to get or put objects, one has to create a Client using the
for_organization function.
Sourcepub fn default_compression(self, compression: Compression) -> Self
pub fn default_compression(self, compression: Compression) -> Self
This changes the default compression used for uploads.
Sourcepub fn default_expiration_policy(
self,
expiration_policy: ExpirationPolicy,
) -> Self
pub fn default_expiration_policy( self, expiration_policy: ExpirationPolicy, ) -> Self
This sets a default expiration policy used for uploads.
Sourcepub fn with_distributed_tracing(self, propagate_traces: bool) -> Self
pub fn with_distributed_tracing(self, propagate_traces: bool) -> Self
This changes whether the sentry-trace header will be sent to Objectstore
to take advantage of Sentry’s distributed tracing.
Sourcepub fn for_organization(&self, organization_id: u64) -> Client
pub fn for_organization(&self, organization_id: u64) -> Client
Create a new Client and sets its scope based on the provided organization.