Struct google_api_proto::google::devtools::cloudprofiler::v2::profiler_service_client::ProfilerServiceClient
source · pub struct ProfilerServiceClient<T> { /* private fields */ }
Expand description
Manage the collection of continuous profiling data provided by profiling agents running in the cloud or by an offline provider of profiling data.
The APIs listed in this service are intended for use within our profiler agents only.
Implementations§
source§impl<T> ProfilerServiceClient<T>where
T: GrpcService<BoxBody>,
T::Error: Into<StdError>,
T::ResponseBody: Body<Data = Bytes> + Send + 'static,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
impl<T> ProfilerServiceClient<T>where
T: GrpcService<BoxBody>,
T::Error: Into<StdError>,
T::ResponseBody: Body<Data = Bytes> + Send + 'static,
<T::ResponseBody as Body>::Error: Into<StdError> + Send,
pub fn new(inner: T) -> Self
pub fn with_origin(inner: T, origin: Uri) -> Self
pub fn with_interceptor<F>(
inner: T,
interceptor: F,
) -> ProfilerServiceClient<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,
sourcepub fn send_compressed(self, encoding: CompressionEncoding) -> Self
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.
sourcepub fn accept_compressed(self, encoding: CompressionEncoding) -> Self
pub fn accept_compressed(self, encoding: CompressionEncoding) -> Self
Enable decompressing responses.
sourcepub fn max_decoding_message_size(self, limit: usize) -> Self
pub fn max_decoding_message_size(self, limit: usize) -> Self
Limits the maximum size of a decoded message.
Default: 4MB
sourcepub fn max_encoding_message_size(self, limit: usize) -> Self
pub fn max_encoding_message_size(self, limit: usize) -> Self
Limits the maximum size of an encoded message.
Default: usize::MAX
sourcepub async fn create_profile(
&mut self,
request: impl IntoRequest<CreateProfileRequest>,
) -> Result<Response<Profile>, Status>
pub async fn create_profile( &mut self, request: impl IntoRequest<CreateProfileRequest>, ) -> Result<Response<Profile>, Status>
CreateProfile creates a new profile resource in the online mode.
Direct use of this API is discouraged, please use a supported profiler agent instead for profile collection.
The server ensures that the new profiles are created at a constant rate per deployment, so the creation request may hang for some time until the next profile session is available.
The request may fail with ABORTED error if the creation is not available within ~1m, the response will indicate the duration of the backoff the client should take before attempting creating a profile again. The backoff duration is returned in google.rpc.RetryInfo extension on the response status. To a gRPC client, the extension will be return as a binary-serialized proto in the trailing metadata item named “google.rpc.retryinfo-bin”.
sourcepub async fn create_offline_profile(
&mut self,
request: impl IntoRequest<CreateOfflineProfileRequest>,
) -> Result<Response<Profile>, Status>
pub async fn create_offline_profile( &mut self, request: impl IntoRequest<CreateOfflineProfileRequest>, ) -> Result<Response<Profile>, Status>
CreateOfflineProfile creates a new profile resource in the offline mode. The client provides the profile to create along with the profile bytes, the server records it.
Direct use of this API is discouraged, please use a supported profiler agent instead for profile collection.
sourcepub async fn update_profile(
&mut self,
request: impl IntoRequest<UpdateProfileRequest>,
) -> Result<Response<Profile>, Status>
pub async fn update_profile( &mut self, request: impl IntoRequest<UpdateProfileRequest>, ) -> Result<Response<Profile>, Status>
UpdateProfile updates the profile bytes and labels on the profile resource created in the online mode. Updating the bytes for profiles created in the offline mode is currently not supported: the profile content must be provided at the time of the profile creation.
Direct use of this API is discouraged, please use a supported profiler agent instead for profile collection.
Trait Implementations§
source§impl<T: Clone> Clone for ProfilerServiceClient<T>
impl<T: Clone> Clone for ProfilerServiceClient<T>
source§fn clone(&self) -> ProfilerServiceClient<T>
fn clone(&self) -> ProfilerServiceClient<T>
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreAuto Trait Implementations§
impl<T> !Freeze for ProfilerServiceClient<T>
impl<T> RefUnwindSafe for ProfilerServiceClient<T>where
T: RefUnwindSafe,
impl<T> Send for ProfilerServiceClient<T>where
T: Send,
impl<T> Sync for ProfilerServiceClient<T>where
T: Sync,
impl<T> Unpin for ProfilerServiceClient<T>where
T: Unpin,
impl<T> UnwindSafe for ProfilerServiceClient<T>where
T: UnwindSafe,
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
§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>
T
in a tonic::Request