pub struct ConfigServiceV2Client<T> { /* private fields */ }
Expand description

Service for configuring sinks used to route log entries.

Implementations§

source§

impl<T> ConfigServiceV2Client<T>
where T: GrpcService<BoxBody>, T::Error: Into<StdError>, T::ResponseBody: Body<Data = Bytes> + Send + 'static, <T::ResponseBody as Body>::Error: Into<StdError> + Send,

source

pub fn new(inner: T) -> Self

source

pub fn with_origin(inner: T, origin: Uri) -> Self

source

pub fn with_interceptor<F>( inner: T, interceptor: F ) -> ConfigServiceV2Client<InterceptedService<T, F>>
where F: Interceptor, T::ResponseBody: Default, T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>, <T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,

source

pub fn send_compressed(self, encoding: CompressionEncoding) -> Self

Compress requests with the given encoding.

This requires the server to support it otherwise it might respond with an error.

source

pub fn accept_compressed(self, encoding: CompressionEncoding) -> Self

Enable decompressing responses.

source

pub fn max_decoding_message_size(self, limit: usize) -> Self

Limits the maximum size of a decoded message.

Default: 4MB

source

pub fn max_encoding_message_size(self, limit: usize) -> Self

Limits the maximum size of an encoded message.

Default: usize::MAX

source

pub async fn list_buckets( &mut self, request: impl IntoRequest<ListBucketsRequest> ) -> Result<Response<ListBucketsResponse>, Status>

Lists log buckets.

source

pub async fn get_bucket( &mut self, request: impl IntoRequest<GetBucketRequest> ) -> Result<Response<LogBucket>, Status>

Gets a log bucket.

source

pub async fn create_bucket_async( &mut self, request: impl IntoRequest<CreateBucketRequest> ) -> Result<Response<Operation>, Status>

Creates a log bucket asynchronously that can be used to store log entries.

After a bucket has been created, the bucket’s location cannot be changed.

source

pub async fn update_bucket_async( &mut self, request: impl IntoRequest<UpdateBucketRequest> ) -> Result<Response<Operation>, Status>

Updates a log bucket asynchronously.

If the bucket has a lifecycle_state of DELETE_REQUESTED, then FAILED_PRECONDITION will be returned.

After a bucket has been created, the bucket’s location cannot be changed.

source

pub async fn create_bucket( &mut self, request: impl IntoRequest<CreateBucketRequest> ) -> Result<Response<LogBucket>, Status>

Creates a log bucket that can be used to store log entries. After a bucket has been created, the bucket’s location cannot be changed.

source

pub async fn update_bucket( &mut self, request: impl IntoRequest<UpdateBucketRequest> ) -> Result<Response<LogBucket>, Status>

Updates a log bucket.

If the bucket has a lifecycle_state of DELETE_REQUESTED, then FAILED_PRECONDITION will be returned.

After a bucket has been created, the bucket’s location cannot be changed.

source

pub async fn delete_bucket( &mut self, request: impl IntoRequest<DeleteBucketRequest> ) -> Result<Response<()>, Status>

Deletes a log bucket.

Changes the bucket’s lifecycle_state to the DELETE_REQUESTED state. After 7 days, the bucket will be purged and all log entries in the bucket will be permanently deleted.

source

pub async fn undelete_bucket( &mut self, request: impl IntoRequest<UndeleteBucketRequest> ) -> Result<Response<()>, Status>

Undeletes a log bucket. A bucket that has been deleted can be undeleted within the grace period of 7 days.

source

pub async fn list_views( &mut self, request: impl IntoRequest<ListViewsRequest> ) -> Result<Response<ListViewsResponse>, Status>

Lists views on a log bucket.

source

pub async fn get_view( &mut self, request: impl IntoRequest<GetViewRequest> ) -> Result<Response<LogView>, Status>

Gets a view on a log bucket..

source

pub async fn create_view( &mut self, request: impl IntoRequest<CreateViewRequest> ) -> Result<Response<LogView>, Status>

Creates a view over log entries in a log bucket. A bucket may contain a maximum of 30 views.

source

pub async fn update_view( &mut self, request: impl IntoRequest<UpdateViewRequest> ) -> Result<Response<LogView>, Status>

Updates a view on a log bucket. This method replaces the following fields in the existing view with values from the new view: filter. If an UNAVAILABLE error is returned, this indicates that system is not in a state where it can update the view. If this occurs, please try again in a few minutes.

source

pub async fn delete_view( &mut self, request: impl IntoRequest<DeleteViewRequest> ) -> Result<Response<()>, Status>

Deletes a view on a log bucket. If an UNAVAILABLE error is returned, this indicates that system is not in a state where it can delete the view. If this occurs, please try again in a few minutes.

source

pub async fn list_sinks( &mut self, request: impl IntoRequest<ListSinksRequest> ) -> Result<Response<ListSinksResponse>, Status>

Lists sinks.

source

pub async fn get_sink( &mut self, request: impl IntoRequest<GetSinkRequest> ) -> Result<Response<LogSink>, Status>

Gets a sink.

source

pub async fn create_sink( &mut self, request: impl IntoRequest<CreateSinkRequest> ) -> Result<Response<LogSink>, Status>

Creates a sink that exports specified log entries to a destination. The export of newly-ingested log entries begins immediately, unless the sink’s writer_identity is not permitted to write to the destination. A sink can export log entries only from the resource owning the sink.

source

pub async fn update_sink( &mut self, request: impl IntoRequest<UpdateSinkRequest> ) -> Result<Response<LogSink>, Status>

Updates a sink. This method replaces the following fields in the existing sink with values from the new sink: destination, and filter.

The updated sink might also have a new writer_identity; see the unique_writer_identity field.

source

pub async fn delete_sink( &mut self, request: impl IntoRequest<DeleteSinkRequest> ) -> Result<Response<()>, Status>

Deletes a sink. If the sink has a unique writer_identity, then that service account is also deleted.

Asynchronously creates a linked dataset in BigQuery which makes it possible to use BigQuery to read the logs stored in the log bucket. A log bucket may currently only contain one link.

Deletes a link. This will also delete the corresponding BigQuery linked dataset.

Lists links.

Gets a link.

source

pub async fn list_exclusions( &mut self, request: impl IntoRequest<ListExclusionsRequest> ) -> Result<Response<ListExclusionsResponse>, Status>

Lists all the exclusions on the _Default sink in a parent resource.

source

pub async fn get_exclusion( &mut self, request: impl IntoRequest<GetExclusionRequest> ) -> Result<Response<LogExclusion>, Status>

Gets the description of an exclusion in the _Default sink.

source

pub async fn create_exclusion( &mut self, request: impl IntoRequest<CreateExclusionRequest> ) -> Result<Response<LogExclusion>, Status>

Creates a new exclusion in the _Default sink in a specified parent resource. Only log entries belonging to that resource can be excluded. You can have up to 10 exclusions in a resource.

source

pub async fn update_exclusion( &mut self, request: impl IntoRequest<UpdateExclusionRequest> ) -> Result<Response<LogExclusion>, Status>

Changes one or more properties of an existing exclusion in the _Default sink.

source

pub async fn delete_exclusion( &mut self, request: impl IntoRequest<DeleteExclusionRequest> ) -> Result<Response<()>, Status>

Deletes an exclusion in the _Default sink.

source

pub async fn get_cmek_settings( &mut self, request: impl IntoRequest<GetCmekSettingsRequest> ) -> Result<Response<CmekSettings>, Status>

Gets the Logging CMEK settings for the given resource.

Note: CMEK for the Log Router can be configured for Google Cloud projects, folders, organizations and billing accounts. Once configured for an organization, it applies to all projects and folders in the Google Cloud organization.

See Enabling CMEK for Log Router for more information.

source

pub async fn update_cmek_settings( &mut self, request: impl IntoRequest<UpdateCmekSettingsRequest> ) -> Result<Response<CmekSettings>, Status>

Updates the Log Router CMEK settings for the given resource.

Note: CMEK for the Log Router can currently only be configured for Google Cloud organizations. Once configured, it applies to all projects and folders in the Google Cloud organization.

[UpdateCmekSettings][google.logging.v2.ConfigServiceV2.UpdateCmekSettings] will fail if 1) kms_key_name is invalid, or 2) the associated service account does not have the required roles/cloudkms.cryptoKeyEncrypterDecrypter role assigned for the key, or 3) access to the key is disabled.

See Enabling CMEK for Log Router for more information.

source

pub async fn get_settings( &mut self, request: impl IntoRequest<GetSettingsRequest> ) -> Result<Response<Settings>, Status>

Gets the Log Router settings for the given resource.

Note: Settings for the Log Router can be get for Google Cloud projects, folders, organizations and billing accounts. Currently it can only be configured for organizations. Once configured for an organization, it applies to all projects and folders in the Google Cloud organization.

See Enabling CMEK for Log Router for more information.

source

pub async fn update_settings( &mut self, request: impl IntoRequest<UpdateSettingsRequest> ) -> Result<Response<Settings>, Status>

Updates the Log Router settings for the given resource.

Note: Settings for the Log Router can currently only be configured for Google Cloud organizations. Once configured, it applies to all projects and folders in the Google Cloud organization.

[UpdateSettings][google.logging.v2.ConfigServiceV2.UpdateSettings] will fail if 1) kms_key_name is invalid, or 2) the associated service account does not have the required roles/cloudkms.cryptoKeyEncrypterDecrypter role assigned for the key, or 3) access to the key is disabled. 4) location_id is not supported by Logging. 5) location_id violate OrgPolicy.

See Enabling CMEK for Log Router for more information.

source

pub async fn copy_log_entries( &mut self, request: impl IntoRequest<CopyLogEntriesRequest> ) -> Result<Response<Operation>, Status>

Copies a set of log entries from a log bucket to a Cloud Storage bucket.

Trait Implementations§

source§

impl<T: Clone> Clone for ConfigServiceV2Client<T>

source§

fn clone(&self) -> ConfigServiceV2Client<T>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<T: Debug> Debug for ConfigServiceV2Client<T>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

§

impl<T> !Freeze for ConfigServiceV2Client<T>

§

impl<T> RefUnwindSafe for ConfigServiceV2Client<T>
where T: RefUnwindSafe,

§

impl<T> Send for ConfigServiceV2Client<T>
where T: Send,

§

impl<T> Sync for ConfigServiceV2Client<T>
where T: Sync,

§

impl<T> Unpin for ConfigServiceV2Client<T>
where T: Unpin,

§

impl<T> UnwindSafe for ConfigServiceV2Client<T>
where T: UnwindSafe,

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> FromRef<T> for T
where T: Clone,

§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoRequest<T> for T

source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more