operations
Creates, updates, deletes, gets or lists an operations
resource.
Overview
Name | operations |
Type | Resource |
Id | google.container.operations |
Fields
The following fields are returned by SELECT
queries:
- projects_locations_operations_get
- projects_zones_operations_get
- projects_locations_operations_list
- projects_zones_operations_list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Output only. The server-assigned ID for the operation. |
clusterConditions | array | Which conditions caused the current cluster state. Deprecated. Use field error instead. |
detail | string | Output only. Detailed operation progress, if available. |
endTime | string | Output only. The time the operation completed, in RFC3339 text format. |
error | object | The error result of the operation in case of failure. (id: Status) |
location | string | Output only. The name of the Google Compute Engine zone or region in which the cluster resides. |
nodepoolConditions | array | Which conditions caused the current node pool state. Deprecated. Use field error instead. |
operationType | string | Output only. The operation type. |
progress | object | Output only. Progress information for an operation. (id: OperationProgress) |
selfLink | string | Output only. Server-defined URI for the operation. Example: https://container.googleapis.com/v1alpha1/projects/123/locations/us-central1/operations/operation-123 . |
startTime | string | Output only. The time the operation started, in RFC3339 text format. |
status | string | Output only. The current status of the operation. |
statusMessage | string | Output only. If an error has occurred, a textual description of the error. Deprecated. Use the field error instead. |
targetLink | 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 |
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. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Output only. The server-assigned ID for the operation. |
clusterConditions | array | Which conditions caused the current cluster state. Deprecated. Use field error instead. |
detail | string | Output only. Detailed operation progress, if available. |
endTime | string | Output only. The time the operation completed, in RFC3339 text format. |
error | object | The error result of the operation in case of failure. (id: Status) |
location | string | Output only. The name of the Google Compute Engine zone or region in which the cluster resides. |
nodepoolConditions | array | Which conditions caused the current node pool state. Deprecated. Use field error instead. |
operationType | string | Output only. The operation type. |
progress | object | Output only. Progress information for an operation. (id: OperationProgress) |
selfLink | string | Output only. Server-defined URI for the operation. Example: https://container.googleapis.com/v1alpha1/projects/123/locations/us-central1/operations/operation-123 . |
startTime | string | Output only. The time the operation started, in RFC3339 text format. |
status | string | Output only. The current status of the operation. |
statusMessage | string | Output only. If an error has occurred, a textual description of the error. Deprecated. Use the field error instead. |
targetLink | 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 |
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. |
Successful response
Name | Datatype | Description |
---|---|---|
missingZones | array | If any zones are listed here, the list of operations returned may be missing the operations from those zones. |
operations | array | A list of operations in the project in the specified zone. |
Successful response
Name | Datatype | Description |
---|---|---|
missingZones | array | If any zones are listed here, the list of operations returned may be missing the operations from those zones. |
operations | array | A list of operations in the project in the specified zone. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
projects_locations_operations_get | select | projectsId , locationsId , operationsId | projectId , zone , operationId | Gets the specified operation. |
projects_zones_operations_get | select | projectId , zone , operationId | name | Gets the specified operation. |
projects_locations_operations_list | select | projectsId , locationsId | projectId , zone | Lists all operations in a project in a specific zone or all zones. |
projects_zones_operations_list | select | projectId , zone | parent | Lists all operations in a project in a specific zone or all zones. |
projects_locations_operations_cancel | exec | projectsId , locationsId , operationsId | Cancels the specified operation. | |
projects_zones_operations_cancel | exec | projectId , zone , operationId | Cancels the specified operation. |
Parameters
Parameters can be passed in the WHERE
clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
Name | Datatype | Description |
---|---|---|
locationsId | string | |
operationId | string | |
operationsId | string | |
projectId | string | |
projectsId | string | |
zone | string | |
name | string | |
operationId | string | |
parent | string | |
projectId | string | |
zone | string |
SELECT
examples
- projects_locations_operations_get
- projects_zones_operations_get
- projects_locations_operations_list
- projects_zones_operations_list
Gets the specified operation.
SELECT
name,
clusterConditions,
detail,
endTime,
error,
location,
nodepoolConditions,
operationType,
progress,
selfLink,
startTime,
status,
statusMessage,
targetLink,
zone
FROM google.container.operations
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND operationsId = '{{ operationsId }}' -- required
AND projectId = '{{ projectId }}'
AND zone = '{{ zone }}'
AND operationId = '{{ operationId }}';
Gets the specified operation.
SELECT
name,
clusterConditions,
detail,
endTime,
error,
location,
nodepoolConditions,
operationType,
progress,
selfLink,
startTime,
status,
statusMessage,
targetLink,
zone
FROM google.container.operations
WHERE projectId = '{{ projectId }}' -- required
AND zone = '{{ zone }}' -- required
AND operationId = '{{ operationId }}' -- required
AND name = '{{ name }}';
Lists all operations in a project in a specific zone or all zones.
SELECT
missingZones,
operations
FROM google.container.operations
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND projectId = '{{ projectId }}'
AND zone = '{{ zone }}';
Lists all operations in a project in a specific zone or all zones.
SELECT
missingZones,
operations
FROM google.container.operations
WHERE projectId = '{{ projectId }}' -- required
AND zone = '{{ zone }}' -- required
AND parent = '{{ parent }}';
Lifecycle Methods
- projects_locations_operations_cancel
- projects_zones_operations_cancel
Cancels the specified operation.
EXEC google.container.operations.projects_locations_operations_cancel
@projectsId='{{ projectsId }}' --required,
@locationsId='{{ locationsId }}' --required,
@operationsId='{{ operationsId }}' --required
@@json=
'{
"projectId": "{{ projectId }}",
"zone": "{{ zone }}",
"operationId": "{{ operationId }}",
"name": "{{ name }}"
}';
Cancels the specified operation.
EXEC google.container.operations.projects_zones_operations_cancel
@projectId='{{ projectId }}' --required,
@zone='{{ zone }}' --required,
@operationId='{{ operationId }}' --required
@@json=
'{
"projectId": "{{ projectId }}",
"zone": "{{ zone }}",
"operationId": "{{ operationId }}",
"name": "{{ name }}"
}';