#[non_exhaustive]pub struct UsageSnapshot {
pub milli_dcu: i64,
pub shuffle_storage_gb: i64,
pub milli_dcu_premium: i64,
pub shuffle_storage_gb_premium: i64,
pub milli_accelerator: i64,
pub accelerator_type: String,
pub snapshot_time: Option<Timestamp>,
/* private fields */
}Expand description
The usage snapshot represents the resources consumed by a workload at a specified time.
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: i64Optional. Milli (one-thousandth) Dataproc Compute Units (DCUs) (see [Dataproc Serverless pricing] (https://cloud.google.com/dataproc-serverless/pricing)).
shuffle_storage_gb: i64Optional. Shuffle Storage in gigabytes (GB). (see [Dataproc Serverless pricing] (https://cloud.google.com/dataproc-serverless/pricing))
Optional. Milli (one-thousandth) Dataproc Compute Units (DCUs) charged at premium tier (see [Dataproc Serverless pricing] (https://cloud.google.com/dataproc-serverless/pricing)).
Optional. Shuffle Storage in gigabytes (GB) charged at premium tier. (see [Dataproc Serverless pricing] (https://cloud.google.com/dataproc-serverless/pricing))
milli_accelerator: i64Optional. Milli (one-thousandth) accelerator. (see [Dataproc Serverless pricing] (https://cloud.google.com/dataproc-serverless/pricing))
accelerator_type: StringOptional. Accelerator type being used, if any
snapshot_time: Option<Timestamp>Optional. The timestamp of the usage snapshot.
Implementations§
Source§impl UsageSnapshot
impl UsageSnapshot
Sourcepub fn set_milli_dcu<T: Into<i64>>(self, v: T) -> Self
pub fn set_milli_dcu<T: Into<i64>>(self, v: T) -> Self
Sourcepub fn set_shuffle_storage_gb<T: Into<i64>>(self, v: T) -> Self
pub fn set_shuffle_storage_gb<T: Into<i64>>(self, v: T) -> Self
Sets the value of shuffle_storage_gb.
§Example
let x = UsageSnapshot::new().set_shuffle_storage_gb(42);Sets the value of milli_dcu_premium.
§Example
let x = UsageSnapshot::new().set_milli_dcu_premium(42);Sets the value of shuffle_storage_gb_premium.
§Example
let x = UsageSnapshot::new().set_shuffle_storage_gb_premium(42);Sourcepub fn set_milli_accelerator<T: Into<i64>>(self, v: T) -> Self
pub fn set_milli_accelerator<T: Into<i64>>(self, v: T) -> Self
Sets the value of milli_accelerator.
§Example
let x = UsageSnapshot::new().set_milli_accelerator(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 = UsageSnapshot::new().set_accelerator_type("example");Sourcepub fn set_snapshot_time<T>(self, v: T) -> Self
pub fn set_snapshot_time<T>(self, v: T) -> Self
Sets the value of snapshot_time.
§Example
use wkt::Timestamp;
let x = UsageSnapshot::new().set_snapshot_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_snapshot_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_snapshot_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of snapshot_time.
§Example
use wkt::Timestamp;
let x = UsageSnapshot::new().set_or_clear_snapshot_time(Some(Timestamp::default()/* use setters */));
let x = UsageSnapshot::new().set_or_clear_snapshot_time(None::<Timestamp>);Trait Implementations§
Source§impl Clone for UsageSnapshot
impl Clone for UsageSnapshot
Source§fn clone(&self) -> UsageSnapshot
fn clone(&self) -> UsageSnapshot
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 UsageSnapshot
impl Debug for UsageSnapshot
Source§impl Default for UsageSnapshot
impl Default for UsageSnapshot
Source§fn default() -> UsageSnapshot
fn default() -> UsageSnapshot
Source§impl Message for UsageSnapshot
impl Message for UsageSnapshot
Source§impl PartialEq for UsageSnapshot
impl PartialEq for UsageSnapshot
impl StructuralPartialEq for UsageSnapshot
Auto Trait Implementations§
impl Freeze for UsageSnapshot
impl RefUnwindSafe for UsageSnapshot
impl Send for UsageSnapshot
impl Sync for UsageSnapshot
impl Unpin for UsageSnapshot
impl UnsafeUnpin for UsageSnapshot
impl UnwindSafe for UsageSnapshot
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