Skip to content

Commit

Permalink
feat: add support for NodeConfig Update (#6594)
Browse files Browse the repository at this point in the history
feat: publicize tpu topology in v1 API
PiperOrigin-RevId: 560116372
Source-Link: googleapis/googleapis@cf6f9ee
Source-Link: googleapis/googleapis-gen@b618aaf
Copy-Tag: eyJwIjoiQ29udGFpbmVyLy5Pd2xCb3QueWFtbCIsImgiOiJiNjE4YWFmYTY0MTc0MWE1NjE1YzIxNmI4Nzg2MDA2NWJkYzMwZjhkIn0=
  • Loading branch information
gcf-owl-bot[bot] authored Aug 25, 2023
1 parent 3050628 commit 54206b4
Show file tree
Hide file tree
Showing 4 changed files with 203 additions and 0 deletions.
Binary file modified Container/metadata/V1/ClusterService.php
Binary file not shown.
27 changes: 27 additions & 0 deletions Container/src/V1/Gapic/ClusterManagerGapicClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -2805,6 +2805,21 @@ public function updateMaster($masterVersion, array $optionalArgs = [])
* Google Compute Engine resources.
* @type WindowsNodeConfig $windowsNodeConfig
* Parameters that can be configured on Windows nodes.
* @type string $machineType
* Optional. The desired [Google Compute Engine machine
* type](https://cloud.google.com/compute/docs/machine-types) for nodes in the
* node pool. Initiates an upgrade operation that migrates the nodes in the
* node pool to the specified machine type.
* @type string $diskType
* Optional. The desired disk type (e.g. 'pd-standard', 'pd-ssd' or
* 'pd-balanced') for nodes in the node pool.
* Initiates an upgrade operation that migrates the nodes in the
* node pool to the specified disk type.
* @type int $diskSizeGb
* Optional. The desired disk size for nodes in the node pool specified in GB.
* The smallest allowed disk size is 10GB.
* Initiates an upgrade operation that migrates the nodes in the
* node pool to the specified disk size.
* @type RetrySettings|array $retrySettings
* Retry settings to use for this call. Can be a {@see RetrySettings} object, or an
* associative array of retry settings parameters. See the documentation on
Expand Down Expand Up @@ -2914,6 +2929,18 @@ public function updateNodePool($nodeVersion, $imageType, array $optionalArgs = [
$request->setWindowsNodeConfig($optionalArgs['windowsNodeConfig']);
}

if (isset($optionalArgs['machineType'])) {
$request->setMachineType($optionalArgs['machineType']);
}

if (isset($optionalArgs['diskType'])) {
$request->setDiskType($optionalArgs['diskType']);
}

if (isset($optionalArgs['diskSizeGb'])) {
$request->setDiskSizeGb($optionalArgs['diskSizeGb']);
}

$requestParams = new RequestParamsHeaderDescriptor($requestParamHeaders);
$optionalArgs['headers'] = isset($optionalArgs['headers']) ? array_merge($requestParams->getHeader(), $optionalArgs['headers']) : $requestParams->getHeader();
return $this->startCall('UpdateNodePool', Operation::class, $optionalArgs, $request)->wait();
Expand Down
38 changes: 38 additions & 0 deletions Container/src/V1/NodePool/PlacementPolicy.php

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

138 changes: 138 additions & 0 deletions Container/src/V1/UpdateNodePoolRequest.php

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 54206b4

Please sign in to comment.