#[non_exhaustive]pub struct UsageMetrics {
pub milli_dcu_seconds: i64,
pub shuffle_storage_gb_seconds: i64,
pub milli_accelerator_seconds: i64,
pub accelerator_type: String,
pub update_time: Option<Timestamp>,
/* private fields */
}Expand description
Usage metrics represent approximate total resources consumed by a workload.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.milli_dcu_seconds: i64Optional. DCU (Dataproc Compute Units) usage in (milliDCU x seconds)
(see [Dataproc Serverless pricing]
(https://cloud.google.com/dataproc-serverless/pricing)).
shuffle_storage_gb_seconds: i64Optional. Shuffle storage usage in (GB x seconds) (see
[Dataproc Serverless pricing]
(https://cloud.google.com/dataproc-serverless/pricing)).
milli_accelerator_seconds: i64Optional. [DEPRECATED] Accelerator usage in (milliAccelerator x
seconds) (see [Dataproc Serverless pricing]
(https://cloud.google.com/dataproc-serverless/pricing)).
accelerator_type: StringOptional. [DEPRECATED] Accelerator type being used, if any
update_time: Option<Timestamp>Optional. The timestamp of the usage metrics.
Implementations§
Source§impl UsageMetrics
impl UsageMetrics
Sourcepub fn set_milli_dcu_seconds<T: Into<i64>>(self, v: T) -> Self
pub fn set_milli_dcu_seconds<T: Into<i64>>(self, v: T) -> Self
Sets the value of milli_dcu_seconds.
§Example
let x = UsageMetrics::new().set_milli_dcu_seconds(42);Sourcepub fn set_shuffle_storage_gb_seconds<T: Into<i64>>(self, v: T) -> Self
pub fn set_shuffle_storage_gb_seconds<T: Into<i64>>(self, v: T) -> Self
Sets the value of shuffle_storage_gb_seconds.
§Example
let x = UsageMetrics::new().set_shuffle_storage_gb_seconds(42);Sourcepub fn set_milli_accelerator_seconds<T: Into<i64>>(self, v: T) -> Self
pub fn set_milli_accelerator_seconds<T: Into<i64>>(self, v: T) -> Self
Sets the value of milli_accelerator_seconds.
§Example
let x = UsageMetrics::new().set_milli_accelerator_seconds(42);Sourcepub fn set_accelerator_type<T: Into<String>>(self, v: T) -> Self
pub fn set_accelerator_type<T: Into<String>>(self, v: T) -> Self
Sets the value of accelerator_type.
§Example
let x = UsageMetrics::new().set_accelerator_type("example");Sourcepub fn set_update_time<T>(self, v: T) -> Self
pub fn set_update_time<T>(self, v: T) -> Self
Sets the value of update_time.
§Example
use wkt::Timestamp;
let x = UsageMetrics::new().set_update_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of update_time.
§Example
use wkt::Timestamp;
let x = UsageMetrics::new().set_or_clear_update_time(Some(Timestamp::default()/* use setters */));
let x = UsageMetrics::new().set_or_clear_update_time(None::<Timestamp>);Trait Implementations§
Source§impl Clone for UsageMetrics
impl Clone for UsageMetrics
Source§fn clone(&self) -> UsageMetrics
fn clone(&self) -> UsageMetrics
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for UsageMetrics
impl Debug for UsageMetrics
Source§impl Default for UsageMetrics
impl Default for UsageMetrics
Source§fn default() -> UsageMetrics
fn default() -> UsageMetrics
Source§impl Message for UsageMetrics
impl Message for UsageMetrics
Source§impl PartialEq for UsageMetrics
impl PartialEq for UsageMetrics
impl StructuralPartialEq for UsageMetrics
Auto Trait Implementations§
impl Freeze for UsageMetrics
impl RefUnwindSafe for UsageMetrics
impl Send for UsageMetrics
impl Sync for UsageMetrics
impl Unpin for UsageMetrics
impl UnsafeUnpin for UsageMetrics
impl UnwindSafe for UsageMetrics
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<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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