REST Resource: projects.locations.operations

Stay organized with collections Save and categorize content based on your preferences.

Resource: Operation

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

JSON representation
{
  "name": string,
  "zone": string,
  "operationType": enum (Type),
  "status": enum (Status),
  "detail": string,
  "statusMessage": string,
  "selfLink": string,
  "targetLink": string,
  "location": string,
  "startTime": string,
  "endTime": string,
  "progress": {
    object (OperationProgress)
  },
  "clusterConditions": [
    {
      object (StatusCondition)
    }
  ],
  "nodepoolConditions": [
    {
      object (StatusCondition)
    }
  ],
  "error": {
    object (Status)
  }
}
Fields
name

string

The server-assigned ID for the operation.

zone
(deprecated)

string

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

operationType

enum (Type)

The operation type.

status

enum (Status)

The current status of the operation.

detail

string

Detailed operation progress, if available.

statusMessage
(deprecated)

string

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

location

string

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

startTime

string

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

endTime

string

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

progress

object (OperationProgress)

Output only. [Output only] Progress information for an operation.

clusterConditions[]
(deprecated)

object (StatusCondition)

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

nodepoolConditions[]
(deprecated)

object (StatusCondition)

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

error

object (Status)

The error result of the operation in case of failure.

Type

Operation type.

Enums
TYPE_UNSPECIFIED Not set.
CREATE_CLUSTER Cluster create.
DELETE_CLUSTER Cluster delete.
UPGRADE_MASTER A master upgrade.
UPGRADE_NODES A node upgrade.
REPAIR_CLUSTER Cluster repair.
UPDATE_CLUSTER Cluster update.
CREATE_NODE_POOL Node pool create.
DELETE_NODE_POOL Node pool delete.
SET_NODE_POOL_MANAGEMENT Set node pool management.
AUTO_REPAIR_NODES Automatic node pool repair.
AUTO_UPGRADE_NODES Automatic node upgrade.
SET_LABELS Set labels.
SET_MASTER_AUTH Set/generate master auth materials
SET_NODE_POOL_SIZE Set node pool size.
SET_NETWORK_POLICY Updates network policy for a cluster.
SET_MAINTENANCE_POLICY Set the maintenance policy.

Status

Current status of the operation.

Enums
STATUS_UNSPECIFIED Not set.
PENDING The operation has been created.
RUNNING The operation is currently running.
DONE The operation is done, either cancelled or completed.
ABORTING The operation is aborting.

OperationProgress

Information about operation (or operation stage) progress.

JSON representation
{
  "name": string,
  "status": enum (Status),
  "metrics": [
    {
      object (Metric)
    }
  ],
  "stages": [
    {
      object (OperationProgress)
    }
  ]
}
Fields
name

string

A non-parameterized string describing an operation stage. Unset for single-stage operations.

status

enum (Status)

Status of an operation stage. Unset for single-stage operations.

metrics[]

object (Metric)

Progress metric bundle, for example: metrics: [{name: "nodes done", intValue: 15}, {name: "nodes total", intValue: 32}] or metrics: [{name: "progress", doubleValue: 0.56}, {name: "progress scale", doubleValue: 1.0}]

stages[]

object (OperationProgress)

Substages of an operation or a stage.

Metric

Progress metric is (string, int|float|string) pair.

JSON representation
{
  "name": string,

  // Union field value can be only one of the following:
  "intValue": string,
  "doubleValue": number,
  "stringValue": string
  // End of list of possible types for union field value.
}
Fields
name

string

Required. Metric name, e.g., "nodes total", "percent done".

Union field value. Strictly one of the values is required. value can be only one of the following:
intValue

string (int64 format)

For metrics with integer value.

doubleValue

number

For metrics with floating point value.

stringValue

string

For metrics with custom values (ratios, visual progress, etc.).

Methods

cancel

Cancels the specified operation.

get

Gets the specified operation.

list

Lists all operations in a project in a specific zone or all zones.