REST Resource: projects.locations.clusters.nodePools

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": number,
  "locations": [
    string
  ],
  "selfLink": string,
  "version": string,
  "instanceGroupUrls": [
    string
  ],
  "status": enum (Status),
  "statusMessage": string,
  "autoscaling": {
    object (NodePoolAutoscaling)
  },
  "management": {
    object (NodeManagement)
  },
  "maxPodsConstraint": {
    object (MaxPodsConstraint)
  },
  "conditions": [
    {
      object (StatusCondition)
    }
  ],
  "podIpv4CidrSize": number,
  "upgradeSettings": {
    object (UpgradeSettings)
  }
}
Fields
name

string

The name of the node pool.

config

object (NodeConfig)

The node configuration of the pool.

initialNodeCount

number

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.

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.

status

enum (Status)

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

statusMessage

string

[Output only] 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

number

[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.

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": number,
  "maxNodeCount": number,
  "autoprovisioned": boolean
}
Fields
enabled

boolean

Is autoscaling enabled for this node pool.

minNodeCount

number

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

maxNodeCount

number

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

autoprovisioned

boolean

Can this node pool be deleted automatically.

NodeManagement

NodeManagement defines the set of node management services turned on for the node pool.

JSON representation
{
  "autoUpgrade": boolean,
  "autoRepair": boolean,
  "upgradeOptions": {
    object (AutoUpgradeOptions)
  }
}
Fields
autoUpgrade

boolean

Whether the nodes will be automatically upgraded.

autoRepair

boolean

Whether the nodes will be automatically repaired.

upgradeOptions

object (AutoUpgradeOptions)

Specifies the Auto Upgrade knobs for the node pool.

AutoUpgradeOptions

AutoUpgradeOptions defines the set of options for the user to control how the Auto Upgrades will proceed.

JSON representation
{
  "autoUpgradeStartTime": string,
  "description": string
}
Fields
autoUpgradeStartTime

string

[Output only] This field is set when upgrades are about to commence with the approximate start time for the upgrades, in RFC3339 text format.

description

string

[Output only] This field is set when upgrades are about to commence with the description of the upgrade.

UpgradeSettings

These upgrade settings control the level of parallelism and the level of disruption caused by an upgrade.

maxUnavailable controls the number of nodes that can be simultaneously unavailable.

maxSurge controls the number of additional nodes that can be added to the node pool temporarily for the time of the upgrade to increase the number of available nodes.

(maxUnavailable + maxSurge) determines the level of parallelism (how many nodes are being upgraded at the same time).

Note: upgrades inevitably introduce some disruption since workloads need to be moved from old nodes to new, upgraded ones. Even if maxUnavailable=0, this holds true. (Disruption stays within the limits of PodDisruptionBudget, if it is configured.)

Consider a hypothetical node pool with 5 nodes having maxSurge=2, maxUnavailable=1. This means the upgrade process upgrades 3 nodes simultaneously. It creates 2 additional (upgraded) nodes, then it brings down 3 old (not yet upgraded) nodes at the same time. This ensures that there are always at least 4 nodes available.

JSON representation
{
  "maxSurge": number,
  "maxUnavailable": number
}
Fields
maxSurge

number

The maximum number of nodes that can be created beyond the current size of the node pool during the upgrade process.

maxUnavailable

number

The maximum number of nodes that can be simultaneously unavailable during the upgrade process. A node is considered available if its status is Ready.

Methods

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 of a specific 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 of a specific node pool.
本頁內容對您是否有任何幫助?請提供意見:

傳送您對下列選項的寶貴意見...

這個網頁
Kubernetes Engine