Struct Operation

Source
#[non_exhaustive]
pub struct Operation {
Show 15 fields pub name: String, pub zone: String, pub operation_type: Type, pub status: Status, pub detail: String, pub status_message: String, pub self_link: String, pub target_link: String, pub location: String, pub start_time: String, pub end_time: String, pub progress: Option<OperationProgress>, pub cluster_conditions: Vec<StatusCondition>, pub nodepool_conditions: Vec<StatusCondition>, pub error: Option<Status>,
}
Expand description

This operation resource represents operations that may have happened or are happening on the cluster. All fields are output only.

Fields (Non-exhaustive)§

This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.
§name: String

Output only. The server-assigned ID for the operation.

§zone: String

Output only. The name of the Google Compute Engine zone in which the operation is taking place. This field is deprecated, use location instead.

§operation_type: Type

Output only. The operation type.

§status: Status

Output only. The current status of the operation.

§detail: String

Output only. Detailed operation progress, if available.

§status_message: String

Output only. If an error has occurred, a textual description of the error. Deprecated. Use the field error instead.

§self_link: String

Output only. Server-defined URI for the operation. Example: <https://container.googleapis.com/v1alpha1/projects/123/locations/us-central1/operations/operation-123>.

§target_link: String

Output only. Server-defined URI for the target of the operation. The format of this is a URI to the resource being modified (such as a cluster, node pool, or node). For node pool repairs, there may be multiple nodes being repaired, but only one will be the target.

Examples:

§

<https://container.googleapis.com/v1/projects/123/locations/us-central1/clusters/my-cluster>

§

<https://container.googleapis.com/v1/projects/123/zones/us-central1-c/clusters/my-cluster/nodePools/my-np>

<https://container.googleapis.com/v1/projects/123/zones/us-central1-c/clusters/my-cluster/nodePools/my-np/node/my-node>

§location: String

Output only. The name of the Google Compute Engine zone or region in which the cluster resides.

§start_time: String

Output only. The time the operation started, in RFC3339 text format.

§end_time: String

Output only. The time the operation completed, in RFC3339 text format.

§progress: Option<OperationProgress>

Output only. Progress information for an operation.

§cluster_conditions: Vec<StatusCondition>

Which conditions caused the current cluster state. Deprecated. Use field error instead.

§nodepool_conditions: Vec<StatusCondition>

Which conditions caused the current node pool state. Deprecated. Use field error instead.

§error: Option<Status>

The error result of the operation in case of failure.

Implementations§

Source§

impl Operation

Source

pub fn set_name<T: Into<String>>(self, v: T) -> Self

Sets the value of name.

Source

pub fn set_zone<T: Into<String>>(self, v: T) -> Self

Sets the value of zone.

Source

pub fn set_operation_type<T: Into<Type>>(self, v: T) -> Self

Sets the value of operation_type.

Source

pub fn set_status<T: Into<Status>>(self, v: T) -> Self

Sets the value of status.

Source

pub fn set_detail<T: Into<String>>(self, v: T) -> Self

Sets the value of detail.

Source

pub fn set_status_message<T: Into<String>>(self, v: T) -> Self

Sets the value of status_message.

Sets the value of self_link.

Sets the value of target_link.

Source

pub fn set_location<T: Into<String>>(self, v: T) -> Self

Sets the value of location.

Source

pub fn set_start_time<T: Into<String>>(self, v: T) -> Self

Sets the value of start_time.

Source

pub fn set_end_time<T: Into<String>>(self, v: T) -> Self

Sets the value of end_time.

Source

pub fn set_progress<T: Into<Option<OperationProgress>>>(self, v: T) -> Self

Sets the value of progress.

Source

pub fn set_error<T: Into<Option<Status>>>(self, v: T) -> Self

Sets the value of error.

Source

pub fn set_cluster_conditions<T, V>(self, v: T) -> Self
where T: IntoIterator<Item = V>, V: Into<StatusCondition>,

Sets the value of cluster_conditions.

Source

pub fn set_nodepool_conditions<T, V>(self, v: T) -> Self
where T: IntoIterator<Item = V>, V: Into<StatusCondition>,

Sets the value of nodepool_conditions.

Trait Implementations§

Source§

impl Clone for Operation

Source§

fn clone(&self) -> Operation

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 Debug for Operation

Source§

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

Formats the value using the given formatter. Read more
Source§

impl Default for Operation

Source§

fn default() -> Operation

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for Operation

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl Message for Operation

Source§

fn typename() -> &'static str

The typename of this message.
Source§

impl PartialEq for Operation

Source§

fn eq(&self, other: &Operation) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for Operation

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for Operation

Auto Trait Implementations§

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> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dst: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

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

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

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> ToOwned for T
where T: Clone,

Source§

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>,

Source§

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>,

Source§

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.
Source§

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

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

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
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

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

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> ErasedDestructor for T
where T: 'static,

Source§

impl<T> MaybeSendSync for T