Skip to main content

clusters

Creates, updates, deletes, gets or lists a clusters resource.

Overview

Nameclusters
TypeResource
Idgoogle.hypercomputecluster.clusters

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
namestringIdentifier. Relative resource name of the cluster, in the format projects/{project}/locations/{location}/clusters/{cluster}.
computeResourcesobjectOptional. Compute resources available to the cluster. Keys specify the ID of the compute resource by which it can be referenced elsewhere, and must conform to RFC-1034 (lower-case, alphanumeric, and at most 63 characters).
createTimestring (google-datetime)Output only. Time that the cluster was originally created.
descriptionstringOptional. A description for your cluster. You can use up to 2,048 characters.
labelsobjectOptional. Labels applied to the cluster. Labels can be used to organize clusters and to filter them in queries.
networkResourcesobjectOptional. Network resources available to the cluster. Must contain exactly one value. Keys specify the ID of the network resource by which it can be referenced elsewhere, and must conform to RFC-1034 (lower-case, alphanumeric, and at most 63 characters).
orchestratorobjectOptional. Orchestrator that is responsible for scheduling and running jobs on the cluster. (id: Orchestrator)
reconcilingbooleanOutput only. Indicates whether changes to the cluster are currently in flight. If this is true, then the current state might not match the cluster's intended state.
storageResourcesobjectOptional. Storage resources available to the cluster. Keys specify the ID of the storage resource by which it can be referenced elsewhere, and must conform to RFC-1034 (lower-case, alphanumeric, and at most 63 characters).
updateTimestring (google-datetime)Output only. Time that the cluster was most recently updated.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, clustersIdGets details of a single Cluster.
listselectprojectsId, locationsIdfilter, pageSize, orderBy, pageTokenLists Clusters in a given project and location.
createinsertprojectsId, locationsIdrequestId, clusterIdCreates a new Cluster in a given project and location.
patchupdateprojectsId, locationsId, clustersIdupdateMask, requestIdUpdates the parameters of a single Cluster.
deletedeleteprojectsId, locationsId, clustersIdrequestIdDeletes a single Cluster.

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.

NameDatatypeDescription
clustersIdstring
locationsIdstring
projectsIdstring
clusterIdstring
filterstring
orderBystring
pageSizeinteger (int32)
pageTokenstring
requestIdstring
updateMaskstring (google-fieldmask)

SELECT examples

Gets details of a single Cluster.

SELECT
name,
computeResources,
createTime,
description,
labels,
networkResources,
orchestrator,
reconciling,
storageResources,
updateTime
FROM google.hypercomputecluster.clusters
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND clustersId = '{{ clustersId }}' -- required
;

INSERT examples

Creates a new Cluster in a given project and location.

INSERT INTO google.hypercomputecluster.clusters (
data__computeResources,
data__orchestrator,
data__description,
data__storageResources,
data__networkResources,
data__name,
data__labels,
projectsId,
locationsId,
requestId,
clusterId
)
SELECT
'{{ computeResources }}',
'{{ orchestrator }}',
'{{ description }}',
'{{ storageResources }}',
'{{ networkResources }}',
'{{ name }}',
'{{ labels }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ requestId }}',
'{{ clusterId }}'
RETURNING
name,
done,
error,
metadata,
response
;

UPDATE examples

Updates the parameters of a single Cluster.

UPDATE google.hypercomputecluster.clusters
SET
data__computeResources = '{{ computeResources }}',
data__orchestrator = '{{ orchestrator }}',
data__description = '{{ description }}',
data__storageResources = '{{ storageResources }}',
data__networkResources = '{{ networkResources }}',
data__name = '{{ name }}',
data__labels = '{{ labels }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND clustersId = '{{ clustersId }}' --required
AND updateMask = '{{ updateMask}}'
AND requestId = '{{ requestId}}'
RETURNING
name,
done,
error,
metadata,
response;

DELETE examples

Deletes a single Cluster.

DELETE FROM google.hypercomputecluster.clusters
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND clustersId = '{{ clustersId }}' --required
AND requestId = '{{ requestId }}'
;