pub struct MetricsArchiveClient { /* private fields */ }
Expand description
The metrics archive API client. Read more at https://coralogix.com/docs/archive-s3-bucket-forever/
Implementations§
source§impl MetricsArchiveClient
impl MetricsArchiveClient
sourcepub fn new(region: CoralogixRegion, auth_context: AuthContext) -> Result<Self>
pub fn new(region: CoralogixRegion, auth_context: AuthContext) -> Result<Self>
Creates a new client for the Metrics Archive API.
§Arguments
auth_context
- The to use for authentication.region
- The region to connect to.
sourcepub async fn configure_tenant(
&self,
retention_policy: Option<RetentionPolicyRequest>,
storage_config: StorageConfig,
) -> Result<()>
pub async fn configure_tenant( &self, retention_policy: Option<RetentionPolicyRequest>, storage_config: StorageConfig, ) -> Result<()>
Configures the tenant.
§Arguments
retention_policy
- The retention policy to set.storage_config
- The storage configuration to set.
sourcepub async fn update_tenant(
&self,
retention_days: u32,
storage_config: StorageConfigUpdate,
) -> Result<()>
pub async fn update_tenant( &self, retention_days: u32, storage_config: StorageConfigUpdate, ) -> Result<()>
Updates the tenant configuration.
§Arguments
retention_days
- The retention days to set.storage_config
- The storage configuration to set.
sourcepub async fn validate_bucket(
&self,
storage_config: StorageConfigValidation,
) -> Result<()>
pub async fn validate_bucket( &self, storage_config: StorageConfigValidation, ) -> Result<()>
Validates a bucket configuration.
§Arguments
storage_config
- The storage configuration to validate.bucket_name
- The name of the bucket to validate.
sourcepub async fn get_tenant_config(&self) -> Result<GetTenantConfigResponseV2>
pub async fn get_tenant_config(&self) -> Result<GetTenantConfigResponseV2>
Gets the tenant configuration.
sourcepub async fn enable_archive(&self) -> Result<()>
pub async fn enable_archive(&self) -> Result<()>
Enables the archive.
sourcepub async fn disable_archive(&self) -> Result<()>
pub async fn disable_archive(&self) -> Result<()>
Disables the archive.
Auto Trait Implementations§
impl !Freeze for MetricsArchiveClient
impl !RefUnwindSafe for MetricsArchiveClient
impl Send for MetricsArchiveClient
impl Sync for MetricsArchiveClient
impl Unpin for MetricsArchiveClient
impl !UnwindSafe for MetricsArchiveClient
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request