REST Resource: projects.locations.clusters.nodePools

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

Resource: NodePool

NodePool contains the name and configuration for a cluster's node pool. Node pools are a set of nodes (i.e. VM's), with a common configuration and specification, under the control of the cluster master. They may have a set of Kubernetes labels applied to them, which may be used to reference them during pod scheduling. They may also be resized up or down, to accommodate the workload.

JSON representation
{
  "name": string,
  "config": {
    object (NodeConfig)
  },
  "initialNodeCount": integer,
  "locations": [
    string
  ],
  "networkConfig": {
    object (NodeNetworkConfig)
  },
  "selfLink": string,
  "version": string,
  "instanceGroupUrls": [
    string
  ],
  "status": enum (Status),
  "statusMessage": string,
  "autoscaling": {
    object (NodePoolAutoscaling)
  },
  "management": {
    object (NodeManagement)
  },
  "maxPodsConstraint": {
    object (MaxPodsConstraint)
  },
  "conditions": [
    {
      object (StatusCondition)
    }
  ],
  "podIpv4CidrSize": integer,
  "upgradeSettings": {
    object (UpgradeSettings)
  },
  "updateInfo": {
    object (UpdateInfo)
  }
}
Fields
name

string

The name of the node pool.

config

object (NodeConfig)

The node configuration of the pool.

initialNodeCount

integer

The initial node count for the pool. You must ensure that your Compute Engine resource quota is sufficient for this number of instances. You must also have available firewall and routes quota.

locations[]

string

The list of Google Compute Engine zones in which the NodePool's nodes should be located.

If this value is unspecified during node pool creation, the Cluster.Locations value will be used, instead.

Warning: changing node pool locations will result in nodes being added and/or removed.

networkConfig

object (NodeNetworkConfig)

Networking configuration for this NodePool. If specified, it overrides the cluster-level defaults.

version

string

The version of the Kubernetes of this node.

instanceGroupUrls[]

string

[Output only] The resource URLs of the managed instance groups associated with this node pool. During the node pool blue-green upgrade operation, the URLs contain both blue and green resources.

status

enum (Status)

[Output only] The status of the nodes in this pool instance.

statusMessage
(deprecated)

string

[Output only] Deprecated. Use conditions instead. Additional information about the current status of this node pool instance, if available.

autoscaling

object (NodePoolAutoscaling)

Autoscaler configuration for this NodePool. Autoscaler is enabled only if a valid configuration is present.

management

object (NodeManagement)

NodeManagement configuration for this NodePool.

maxPodsConstraint

object (MaxPodsConstraint)

The constraint on the maximum number of pods that can be run simultaneously on a node in the node pool.

conditions[]

object (StatusCondition)

Which conditions caused the current node pool state.

podIpv4CidrSize

integer

[Output only] The pod CIDR block size per node in this node pool.

upgradeSettings

object (UpgradeSettings)

Upgrade settings control disruption and speed of the upgrade.

updateInfo

object (UpdateInfo)

Output only. [Output only] Update info contains relevant information during a node pool update.

NodeNetworkConfig

Parameters for node pool-level network config.

JSON representation
{
  "createPodRange": boolean,
  "podRange": string,
  "podIpv4CidrBlock": string,
  "networkPerformanceConfig": {
    object (NetworkPerformanceConfig)
  }
}
Fields
createPodRange

boolean

Input only. Whether to create a new range for pod IPs in this node pool. Defaults are provided for podRange and podIpv4CidrBlock if they are not specified.

If neither createPodRange or podRange are specified, the cluster-level default (ipAllocationPolicy.cluster_ipv4_cidr_block) is used.

Only applicable if ipAllocationPolicy.use_ip_aliases is true.

This field cannot be changed after the node pool has been created.

podRange

string

The ID of the secondary range for pod IPs. If createPodRange is true, this ID is used for the new range. If createPodRange is false, uses an existing secondary range with this ID.

Only applicable if ipAllocationPolicy.use_ip_aliases is true.

This field cannot be changed after the node pool has been created.

podIpv4CidrBlock

string

The IP address range for pod IPs in this node pool.

Only applicable if createPodRange is true.

Set to blank to have a range chosen with the default size.

Set to /netmask (e.g. /14) to have a range chosen with a specific netmask.

Set to a CIDR notation (e.g. 10.96.0.0/14) to pick a specific range to use.

Only applicable if ipAllocationPolicy.use_ip_aliases is true.

This field cannot be changed after the node pool has been created.

networkPerformanceConfig

object (NetworkPerformanceConfig)

Network bandwidth tier configuration.

NetworkPerformanceConfig

Configuration of all network bandwidth tiers

JSON representation
{
  "totalEgressBandwidthTier": enum (Tier)
}
Fields
totalEgressBandwidthTier

enum (Tier)

Specifies the total network bandwidth tier for the NodePool.

Tier

Node network tier

Enums
TIER_UNSPECIFIED Default value
TIER_1 Higher bandwidth, actual values based on VM size.

Status

The current status of the node pool instance.

Enums
STATUS_UNSPECIFIED Not set.
PROVISIONING The PROVISIONING state indicates the node pool is being created.
RUNNING The RUNNING state indicates the node pool has been created and is fully usable.
RUNNING_WITH_ERROR The RUNNING_WITH_ERROR state indicates the node pool has been created and is partially usable. Some error state has occurred and some functionality may be impaired. Customer may need to reissue a request or trigger a new update.
RECONCILING The RECONCILING state indicates that some work is actively being done on the node pool, such as upgrading node software. Details can be found in the statusMessage field.
STOPPING The STOPPING state indicates the node pool is being deleted.
ERROR The ERROR state indicates the node pool may be unusable. Details can be found in the statusMessage field.

NodePoolAutoscaling

NodePoolAutoscaling contains information required by cluster autoscaler to adjust the size of the node pool to the current cluster usage.

JSON representation
{
  "enabled": boolean,
  "minNodeCount": integer,
  "maxNodeCount": integer,
  "autoprovisioned": boolean,
  "locationPolicy": enum (LocationPolicy),
  "totalMinNodeCount": integer,
  "totalMaxNodeCount": integer
}
Fields
enabled

boolean

Is autoscaling enabled for this node pool.

minNodeCount

integer

Minimum number of nodes for one location in the NodePool. Must be >= 1 and <= maxNodeCount.

maxNodeCount

integer

Maximum number of nodes for one location in the NodePool. Must be >= minNodeCount. There has to be enough quota to scale up the cluster.

autoprovisioned

boolean

Can this node pool be deleted automatically.

locationPolicy

enum (LocationPolicy)

Location policy used when scaling up a nodepool.

totalMinNodeCount

integer

Minimum number of nodes in the node pool. Must be greater than 1 less than totalMaxNodeCount. The total_*_node_count fields are mutually exclusive with the *_node_count fields.

totalMaxNodeCount

integer

Maximum number of nodes in the node pool. Must be greater than totalMinNodeCount. There has to be enough quota to scale up the cluster. The total_*_node_count fields are mutually exclusive with the *_node_count fields.

LocationPolicy

Location policy specifies how zones are picked when scaling up the nodepool.

Enums
LOCATION_POLICY_UNSPECIFIED Not set.
BALANCED BALANCED is a best effort policy that aims to balance the sizes of different zones.
ANY ANY policy picks zones that have the highest capacity available.

UpdateInfo

UpdateInfo contains resource (instance groups, etc), status and other intermediate information relevant to a node pool upgrade.

JSON representation
{
  "blueGreenInfo": {
    object (BlueGreenInfo)
  }
}
Fields
blueGreenInfo

object (BlueGreenInfo)

Information of a blue-green upgrade.

BlueGreenInfo

Information relevant to blue-green upgrade.

JSON representation
{
  "phase": enum (Phase),
  "blueInstanceGroupUrls": [
    string
  ],
  "greenInstanceGroupUrls": [
    string
  ],
  "bluePoolDeletionStartTime": string,
  "greenPoolVersion": string
}
Fields
phase

enum (Phase)

Current blue-green upgrade phase.

blueInstanceGroupUrls[]

string

The resource URLs of the managed instance groups associated with blue pool.

greenInstanceGroupUrls[]

string

The resource URLs of the managed instance groups associated with green pool.

bluePoolDeletionStartTime

string

Time to start deleting blue pool to complete blue-green upgrade, in RFC3339 text format.

greenPoolVersion

string

Version of green pool.

Phase

Phase represents the different stages blue-green upgrade is running in.

Enums
PHASE_UNSPECIFIED Unspecified phase.
UPDATE_STARTED blue-green upgrade has been initiated.
CREATING_GREEN_POOL Start creating green pool nodes.
CORDONING_BLUE_POOL Start cordoning blue pool nodes.
DRAINING_BLUE_POOL Start draining blue pool nodes.
NODE_POOL_SOAKING Start soaking time after draining entire blue pool.
DELETING_BLUE_POOL Start deleting blue nodes.
ROLLBACK_STARTED Rollback has been initiated.

Methods

completeUpgrade

CompleteNodePoolUpgrade will signal an on-going node pool upgrade to complete.

create

Creates a node pool for a cluster.

delete

Deletes a node pool from a cluster.

get

Retrieves the requested node pool.

list

Lists the node pools for a cluster.

rollback

Rolls back a previously Aborted or Failed NodePool upgrade.

setAutoscaling

Sets the autoscaling settings for the specified node pool.

setManagement

Sets the NodeManagement options for a node pool.

setSize

Sets the size for a specific node pool.

update

Updates the version and/or image type for the specified node pool.