diff --git a/google/cloud/container/__init__.py b/google/cloud/container/__init__.py index b594ebd7..a409cf10 100644 --- a/google/cloud/container/__init__.py +++ b/google/cloud/container/__init__.py @@ -55,6 +55,7 @@ DeleteNodePoolRequest, DnsCacheConfig, DNSConfig, + EphemeralStorageLocalSsdConfig, FastSocket, GatewayAPIConfig, GcePersistentDiskCsiDriverConfig, @@ -89,6 +90,7 @@ ListOperationsResponse, ListUsableSubnetworksRequest, ListUsableSubnetworksResponse, + LocalNvmeSsdBlockConfig, LoggingComponentConfig, LoggingConfig, LoggingVariantConfig, @@ -165,6 +167,7 @@ UsableSubnetworkSecondaryRange, VerticalPodAutoscaling, VirtualNIC, + WindowsNodeConfig, WorkloadIdentityConfig, WorkloadMetadataConfig, ) @@ -201,6 +204,7 @@ "DeleteNodePoolRequest", "DnsCacheConfig", "DNSConfig", + "EphemeralStorageLocalSsdConfig", "FastSocket", "GatewayAPIConfig", "GcePersistentDiskCsiDriverConfig", @@ -234,6 +238,7 @@ "ListOperationsResponse", "ListUsableSubnetworksRequest", "ListUsableSubnetworksResponse", + "LocalNvmeSsdBlockConfig", "LoggingComponentConfig", "LoggingConfig", "LoggingVariantConfig", @@ -306,6 +311,7 @@ "UsableSubnetworkSecondaryRange", "VerticalPodAutoscaling", "VirtualNIC", + "WindowsNodeConfig", "WorkloadIdentityConfig", "WorkloadMetadataConfig", "DatapathProvider", diff --git a/google/cloud/container_v1/__init__.py b/google/cloud/container_v1/__init__.py index 817f9c31..e4a50957 100644 --- a/google/cloud/container_v1/__init__.py +++ b/google/cloud/container_v1/__init__.py @@ -50,6 +50,7 @@ DeleteNodePoolRequest, DnsCacheConfig, DNSConfig, + EphemeralStorageLocalSsdConfig, FastSocket, GatewayAPIConfig, GcePersistentDiskCsiDriverConfig, @@ -84,6 +85,7 @@ ListOperationsResponse, ListUsableSubnetworksRequest, ListUsableSubnetworksResponse, + LocalNvmeSsdBlockConfig, LoggingComponentConfig, LoggingConfig, LoggingVariantConfig, @@ -160,6 +162,7 @@ UsableSubnetworkSecondaryRange, VerticalPodAutoscaling, VirtualNIC, + WindowsNodeConfig, WorkloadIdentityConfig, WorkloadMetadataConfig, ) @@ -197,6 +200,7 @@ "DeleteClusterRequest", "DeleteNodePoolRequest", "DnsCacheConfig", + "EphemeralStorageLocalSsdConfig", "FastSocket", "GPUSharingConfig", "GatewayAPIConfig", @@ -231,6 +235,7 @@ "ListOperationsResponse", "ListUsableSubnetworksRequest", "ListUsableSubnetworksResponse", + "LocalNvmeSsdBlockConfig", "LoggingComponentConfig", "LoggingConfig", "LoggingVariantConfig", @@ -307,6 +312,7 @@ "UsableSubnetworkSecondaryRange", "VerticalPodAutoscaling", "VirtualNIC", + "WindowsNodeConfig", "WorkloadIdentityConfig", "WorkloadMetadataConfig", ) diff --git a/google/cloud/container_v1/types/__init__.py b/google/cloud/container_v1/types/__init__.py index efccf26e..7018b5f2 100644 --- a/google/cloud/container_v1/types/__init__.py +++ b/google/cloud/container_v1/types/__init__.py @@ -44,6 +44,7 @@ DeleteNodePoolRequest, DnsCacheConfig, DNSConfig, + EphemeralStorageLocalSsdConfig, FastSocket, GatewayAPIConfig, GcePersistentDiskCsiDriverConfig, @@ -78,6 +79,7 @@ ListOperationsResponse, ListUsableSubnetworksRequest, ListUsableSubnetworksResponse, + LocalNvmeSsdBlockConfig, LoggingComponentConfig, LoggingConfig, LoggingVariantConfig, @@ -154,6 +156,7 @@ UsableSubnetworkSecondaryRange, VerticalPodAutoscaling, VirtualNIC, + WindowsNodeConfig, WorkloadIdentityConfig, WorkloadMetadataConfig, ) @@ -188,6 +191,7 @@ "DeleteNodePoolRequest", "DnsCacheConfig", "DNSConfig", + "EphemeralStorageLocalSsdConfig", "FastSocket", "GatewayAPIConfig", "GcePersistentDiskCsiDriverConfig", @@ -221,6 +225,7 @@ "ListOperationsResponse", "ListUsableSubnetworksRequest", "ListUsableSubnetworksResponse", + "LocalNvmeSsdBlockConfig", "LoggingComponentConfig", "LoggingConfig", "LoggingVariantConfig", @@ -293,6 +298,7 @@ "UsableSubnetworkSecondaryRange", "VerticalPodAutoscaling", "VirtualNIC", + "WindowsNodeConfig", "WorkloadIdentityConfig", "WorkloadMetadataConfig", "DatapathProvider", diff --git a/google/cloud/container_v1/types/cluster_service.py b/google/cloud/container_v1/types/cluster_service.py index c4547265..1446d0d1 100644 --- a/google/cloud/container_v1/types/cluster_service.py +++ b/google/cloud/container_v1/types/cluster_service.py @@ -32,6 +32,7 @@ "StackType", "IPv6AccessType", "LinuxNodeConfig", + "WindowsNodeConfig", "NodeKubeletConfig", "NodeConfig", "AdvancedMachineFeatures", @@ -167,6 +168,8 @@ "LoggingVariantConfig", "MonitoringComponentConfig", "ManagedPrometheusConfig", + "LocalNvmeSsdBlockConfig", + "EphemeralStorageLocalSsdConfig", }, ) @@ -259,6 +262,30 @@ class CgroupMode(proto.Enum): ) +class WindowsNodeConfig(proto.Message): + r"""Parameters that can be configured on Windows nodes. + Windows Node Config that define the parameters that will be used + to configure the Windows node pool settings + + Attributes: + os_version (google.cloud.container_v1.types.WindowsNodeConfig.OSVersion): + OSVersion specifies the Windows node config + to be used on the node + """ + + class OSVersion(proto.Enum): + r"""Possible OS version that can be used.""" + OS_VERSION_UNSPECIFIED = 0 + OS_VERSION_LTSC2019 = 1 + OS_VERSION_LTSC2022 = 2 + + os_version: OSVersion = proto.Field( + proto.ENUM, + number=1, + enum=OSVersion, + ) + + class NodeKubeletConfig(proto.Message): r"""Node kubelet configs. @@ -519,6 +546,16 @@ class NodeConfig(proto.Message): resources. logging_config (google.cloud.container_v1.types.NodePoolLoggingConfig): Logging configuration. + windows_node_config (google.cloud.container_v1.types.WindowsNodeConfig): + Parameters that can be configured on Windows + nodes. + local_nvme_ssd_block_config (google.cloud.container_v1.types.LocalNvmeSsdBlockConfig): + Parameters for using raw-block Local NVMe + SSDs. + ephemeral_storage_local_ssd_config (google.cloud.container_v1.types.EphemeralStorageLocalSsdConfig): + Parameters for the node ephemeral storage + using Local SSDs. If unspecified, ephemeral + storage is backed by the boot disk. """ machine_type: str = proto.Field( @@ -659,6 +696,21 @@ class NodeConfig(proto.Message): number=38, message="NodePoolLoggingConfig", ) + windows_node_config: "WindowsNodeConfig" = proto.Field( + proto.MESSAGE, + number=39, + message="WindowsNodeConfig", + ) + local_nvme_ssd_block_config: "LocalNvmeSsdBlockConfig" = proto.Field( + proto.MESSAGE, + number=40, + message="LocalNvmeSsdBlockConfig", + ) + ephemeral_storage_local_ssd_config: "EphemeralStorageLocalSsdConfig" = proto.Field( + proto.MESSAGE, + number=41, + message="EphemeralStorageLocalSsdConfig", + ) class AdvancedMachineFeatures(proto.Message): @@ -2107,6 +2159,11 @@ class Cluster(proto.Message): auto-provisioned node pools in autopilot clusters and node auto-provisioning enabled clusters. + etag (str): + This checksum is computed by the server based + on the value of cluster fields, and may be sent + on update requests to ensure the client has an + up-to-date value before proceeding. """ class Status(proto.Enum): @@ -2402,6 +2459,10 @@ class Status(proto.Enum): number=136, message="NodePoolAutoConfig", ) + etag: str = proto.Field( + proto.STRING, + number=139, + ) class NodePoolAutoConfig(proto.Message): @@ -2630,6 +2691,11 @@ class ClusterUpdate(proto.Message): desired_gateway_api_config (google.cloud.container_v1.types.GatewayAPIConfig): The desired config of Gateway API on this cluster. + etag (str): + The current etag of the cluster. + If an etag is provided and does not match the + current etag of the cluster, update will be + blocked and an ABORTED error will be returned. desired_node_pool_logging_config (google.cloud.container_v1.types.NodePoolLoggingConfig): The desired node pool logging configuration defaults for the cluster. @@ -2821,6 +2887,10 @@ class ClusterUpdate(proto.Message): number=114, message="GatewayAPIConfig", ) + etag: str = proto.Field( + proto.STRING, + number=115, + ) desired_node_pool_logging_config: "NodePoolLoggingConfig" = proto.Field( proto.MESSAGE, number=116, @@ -3298,6 +3368,11 @@ class UpdateNodePoolRequest(proto.Message): Confidential VM once enabled. gvnic (google.cloud.container_v1.types.VirtualNIC): Enable or disable gvnic on the node pool. + etag (str): + The current etag of the node pool. + If an etag is provided and does not match the + current etag of the node pool, update will be + blocked and an ABORTED error will be returned. fast_socket (google.cloud.container_v1.types.FastSocket): Enable or disable NCCL fast socket for the node pool. @@ -3307,6 +3382,9 @@ class UpdateNodePoolRequest(proto.Message): The resource labels for the node pool to use to annotate any related Google Compute Engine resources. + windows_node_config (google.cloud.container_v1.types.WindowsNodeConfig): + Parameters that can be configured on Windows + nodes. """ project_id: str = proto.Field( @@ -3396,6 +3474,10 @@ class UpdateNodePoolRequest(proto.Message): number=29, message="VirtualNIC", ) + etag: str = proto.Field( + proto.STRING, + number=30, + ) fast_socket: "FastSocket" = proto.Field( proto.MESSAGE, number=31, @@ -3411,6 +3493,11 @@ class UpdateNodePoolRequest(proto.Message): number=33, message="ResourceLabels", ) + windows_node_config: "WindowsNodeConfig" = proto.Field( + proto.MESSAGE, + number=34, + message="WindowsNodeConfig", + ) class SetNodePoolAutoscalingRequest(proto.Message): @@ -4536,6 +4623,11 @@ class NodePool(proto.Message): update_info (google.cloud.container_v1.types.NodePool.UpdateInfo): Output only. [Output only] Update info contains relevant information during a node pool update. + etag (str): + This checksum is computed by the server based + on the value of node pool fields, and may be + sent on update requests to ensure the client has + an up-to-date value before proceeding. """ class Status(proto.Enum): @@ -4818,6 +4910,10 @@ class Type(proto.Enum): number=109, message=UpdateInfo, ) + etag: str = proto.Field( + proto.STRING, + number=110, + ) class NodeManagement(proto.Message): @@ -6429,6 +6525,7 @@ class DNSScope(proto.Enum): records. """ DNS_SCOPE_UNSPECIFIED = 0 + CLUSTER_SCOPE = 1 VPC_SCOPE = 2 cluster_dns: Provider = proto.Field( @@ -7276,4 +7373,50 @@ class ManagedPrometheusConfig(proto.Message): ) +class LocalNvmeSsdBlockConfig(proto.Message): + r"""LocalNvmeSsdBlockConfig contains configuration for using + raw-block local NVMe SSD. + + Attributes: + local_ssd_count (int): + The number of raw-block local NVMe SSD disks + to be attached to the node. Each local SSD is + 375 GB in size. If zero, it means no raw-block + local NVMe SSD disks to be attached to the node. + The limit for this value is dependent upon the + maximum number of disks available on a machine + per zone. See: + https://cloud.google.com/compute/docs/disks/local-ssd + for more information. + """ + + local_ssd_count: int = proto.Field( + proto.INT32, + number=1, + ) + + +class EphemeralStorageLocalSsdConfig(proto.Message): + r"""EphemeralStorageLocalSsdConfig contains configuration for the + node ephemeral storage using Local SSD. + + Attributes: + local_ssd_count (int): + Number of local SSDs to use to back ephemeral + storage. Uses NVMe interfaces. Each local SSD is + 375 GB in size. If zero, it means to disable + using local SSDs as ephemeral storage. The limit + for this value is dependent upon the maximum + number of disks available on a machine per zone. + See: + https://cloud.google.com/compute/docs/disks/local-ssd + for more information. + """ + + local_ssd_count: int = proto.Field( + proto.INT32, + number=1, + ) + + __all__ = tuple(sorted(__protobuf__.manifest)) diff --git a/google/cloud/container_v1beta1/__init__.py b/google/cloud/container_v1beta1/__init__.py index 1993fd79..7df69a67 100644 --- a/google/cloud/container_v1beta1/__init__.py +++ b/google/cloud/container_v1beta1/__init__.py @@ -52,6 +52,7 @@ DnsCacheConfig, DNSConfig, EphemeralStorageConfig, + EphemeralStorageLocalSsdConfig, FastSocket, GatewayAPIConfig, GcePersistentDiskCsiDriverConfig, @@ -89,6 +90,7 @@ ListOperationsResponse, ListUsableSubnetworksRequest, ListUsableSubnetworksResponse, + LocalNvmeSsdBlockConfig, Location, LoggingComponentConfig, LoggingConfig, @@ -155,6 +157,7 @@ SetNodePoolSizeRequest, ShieldedInstanceConfig, ShieldedNodes, + StackType, StartIPRotationRequest, StatusCondition, TimeWindow, @@ -169,6 +172,7 @@ UsableSubnetworkSecondaryRange, VerticalPodAutoscaling, VirtualNIC, + WindowsNodeConfig, WindowsVersions, WorkloadALTSConfig, WorkloadCertificates, @@ -212,6 +216,7 @@ "DeleteNodePoolRequest", "DnsCacheConfig", "EphemeralStorageConfig", + "EphemeralStorageLocalSsdConfig", "FastSocket", "GPUSharingConfig", "GatewayAPIConfig", @@ -249,6 +254,7 @@ "ListOperationsResponse", "ListUsableSubnetworksRequest", "ListUsableSubnetworksResponse", + "LocalNvmeSsdBlockConfig", "Location", "LoggingComponentConfig", "LoggingConfig", @@ -315,6 +321,7 @@ "SetNodePoolSizeRequest", "ShieldedInstanceConfig", "ShieldedNodes", + "StackType", "StartIPRotationRequest", "StatusCondition", "TimeWindow", @@ -329,6 +336,7 @@ "UsableSubnetworkSecondaryRange", "VerticalPodAutoscaling", "VirtualNIC", + "WindowsNodeConfig", "WindowsVersions", "WorkloadALTSConfig", "WorkloadCertificates", diff --git a/google/cloud/container_v1beta1/types/__init__.py b/google/cloud/container_v1beta1/types/__init__.py index c13a4196..247e6211 100644 --- a/google/cloud/container_v1beta1/types/__init__.py +++ b/google/cloud/container_v1beta1/types/__init__.py @@ -46,6 +46,7 @@ DnsCacheConfig, DNSConfig, EphemeralStorageConfig, + EphemeralStorageLocalSsdConfig, FastSocket, GatewayAPIConfig, GcePersistentDiskCsiDriverConfig, @@ -83,6 +84,7 @@ ListOperationsResponse, ListUsableSubnetworksRequest, ListUsableSubnetworksResponse, + LocalNvmeSsdBlockConfig, Location, LoggingComponentConfig, LoggingConfig, @@ -149,6 +151,7 @@ SetNodePoolSizeRequest, ShieldedInstanceConfig, ShieldedNodes, + StackType, StartIPRotationRequest, StatusCondition, TimeWindow, @@ -163,6 +166,7 @@ UsableSubnetworkSecondaryRange, VerticalPodAutoscaling, VirtualNIC, + WindowsNodeConfig, WindowsVersions, WorkloadALTSConfig, WorkloadCertificates, @@ -203,6 +207,7 @@ "DnsCacheConfig", "DNSConfig", "EphemeralStorageConfig", + "EphemeralStorageLocalSsdConfig", "FastSocket", "GatewayAPIConfig", "GcePersistentDiskCsiDriverConfig", @@ -240,6 +245,7 @@ "ListOperationsResponse", "ListUsableSubnetworksRequest", "ListUsableSubnetworksResponse", + "LocalNvmeSsdBlockConfig", "Location", "LoggingComponentConfig", "LoggingConfig", @@ -317,6 +323,7 @@ "UsableSubnetworkSecondaryRange", "VerticalPodAutoscaling", "VirtualNIC", + "WindowsNodeConfig", "WindowsVersions", "WorkloadALTSConfig", "WorkloadCertificates", @@ -326,5 +333,6 @@ "DatapathProvider", "NodePoolUpdateStrategy", "PrivateIPv6GoogleAccess", + "StackType", "UpgradeResourceType", ) diff --git a/google/cloud/container_v1beta1/types/cluster_service.py b/google/cloud/container_v1beta1/types/cluster_service.py index 6141a6a7..d0656135 100644 --- a/google/cloud/container_v1beta1/types/cluster_service.py +++ b/google/cloud/container_v1beta1/types/cluster_service.py @@ -30,7 +30,9 @@ "UpgradeResourceType", "NodePoolUpdateStrategy", "DatapathProvider", + "StackType", "LinuxNodeConfig", + "WindowsNodeConfig", "NodeKubeletConfig", "NodeConfig", "AdvancedMachineFeatures", @@ -38,6 +40,8 @@ "ShieldedInstanceConfig", "SandboxConfig", "EphemeralStorageConfig", + "LocalNvmeSsdBlockConfig", + "EphemeralStorageLocalSsdConfig", "GcfsConfig", "ReservationAffinity", "NodeTaint", @@ -221,6 +225,13 @@ class DatapathProvider(proto.Enum): ADVANCED_DATAPATH = 2 +class StackType(proto.Enum): + r"""Possible values for IP stack type""" + STACK_TYPE_UNSPECIFIED = 0 + IPV4 = 1 + IPV4_IPV6 = 2 + + class LinuxNodeConfig(proto.Message): r"""Parameters that can be configured on Linux nodes. @@ -259,6 +270,30 @@ class CgroupMode(proto.Enum): ) +class WindowsNodeConfig(proto.Message): + r"""Parameters that can be configured on Windows nodes. + Windows Node Config that define the parameters that will be used + to configure the Windows node pool settings + + Attributes: + os_version (google.cloud.container_v1beta1.types.WindowsNodeConfig.OSVersion): + OSVersion specifies the Windows node config + to be used on the node + """ + + class OSVersion(proto.Enum): + r"""Possible OS version that can be used.""" + OS_VERSION_UNSPECIFIED = 0 + OS_VERSION_LTSC2019 = 1 + OS_VERSION_LTSC2022 = 2 + + os_version: OSVersion = proto.Field( + proto.ENUM, + number=1, + enum=OSVersion, + ) + + class NodeKubeletConfig(proto.Message): r"""Node kubelet configs. @@ -522,6 +557,17 @@ class NodeConfig(proto.Message): resources. logging_config (google.cloud.container_v1beta1.types.NodePoolLoggingConfig): Logging configuration. + windows_node_config (google.cloud.container_v1beta1.types.WindowsNodeConfig): + Parameters that can be configured on Windows + nodes. + local_nvme_ssd_block_config (google.cloud.container_v1beta1.types.LocalNvmeSsdBlockConfig): + Parameters for using raw-block Local NVMe + SSDs. + ephemeral_storage_local_ssd_config (google.cloud.container_v1beta1.types.EphemeralStorageLocalSsdConfig): + Parameters for the node ephemeral storage using Local SSDs. + If unspecified, ephemeral storage is backed by the boot + disk. This field is functionally equivalent to the + ephemeral_storage_config """ machine_type: str = proto.Field( @@ -667,6 +713,21 @@ class NodeConfig(proto.Message): number=38, message="NodePoolLoggingConfig", ) + windows_node_config: "WindowsNodeConfig" = proto.Field( + proto.MESSAGE, + number=39, + message="WindowsNodeConfig", + ) + local_nvme_ssd_block_config: "LocalNvmeSsdBlockConfig" = proto.Field( + proto.MESSAGE, + number=40, + message="LocalNvmeSsdBlockConfig", + ) + ephemeral_storage_local_ssd_config: "EphemeralStorageLocalSsdConfig" = proto.Field( + proto.MESSAGE, + number=41, + message="EphemeralStorageLocalSsdConfig", + ) class AdvancedMachineFeatures(proto.Message): @@ -891,6 +952,52 @@ class EphemeralStorageConfig(proto.Message): ) +class LocalNvmeSsdBlockConfig(proto.Message): + r"""LocalNvmeSsdBlockConfig contains configuration for using + raw-block local NVMe SSDs + + Attributes: + local_ssd_count (int): + The number of raw-block local NVMe SSD disks + to be attached to the node. Each local SSD is + 375 GB in size. If zero, it means no raw-block + local NVMe SSD disks to be attached to the node. + The limit for this value is dependent upon the + maximum number of disks available on a machine + per zone. See: + https://cloud.google.com/compute/docs/disks/local-ssd + for more information. + """ + + local_ssd_count: int = proto.Field( + proto.INT32, + number=1, + ) + + +class EphemeralStorageLocalSsdConfig(proto.Message): + r"""EphemeralStorageLocalSsdConfig contains configuration for the + node ephemeral storage using Local SSDs. + + Attributes: + local_ssd_count (int): + Number of local SSDs to use to back ephemeral + storage. Uses NVMe interfaces. Each local SSD is + 375 GB in size. If zero, it means to disable + using local SSDs as ephemeral storage. The limit + for this value is dependent upon the maximum + number of disks available on a machine per zone. + See: + https://cloud.google.com/compute/docs/disks/local-ssd + for more information. + """ + + local_ssd_count: int = proto.Field( + proto.INT32, + number=1, + ) + + class GcfsConfig(proto.Message): r"""GcfsConfig contains configurations of Google Container File System. @@ -2992,6 +3099,12 @@ class ClusterUpdate(proto.Message): desired_node_pool_logging_config (google.cloud.container_v1beta1.types.NodePoolLoggingConfig): The desired node pool logging configuration defaults for the cluster. + desired_stack_type (google.cloud.container_v1beta1.types.StackType): + The desired stack type of the cluster. + If a stack type is provided and does not match + the current stack type of the cluster, update + will attempt to change the stack type to the new + type. """ desired_node_version: str = proto.Field( @@ -3215,6 +3328,11 @@ class ClusterUpdate(proto.Message): number=116, message="NodePoolLoggingConfig", ) + desired_stack_type: "StackType" = proto.Field( + proto.ENUM, + number=119, + enum="StackType", + ) class Operation(proto.Message): @@ -3690,6 +3808,9 @@ class UpdateNodePoolRequest(proto.Message): The resource labels for the node pool to use to annotate any related Google Compute Engine resources. + windows_node_config (google.cloud.container_v1beta1.types.WindowsNodeConfig): + Parameters that can be configured on Windows + nodes. """ project_id: str = proto.Field( @@ -3794,6 +3915,11 @@ class UpdateNodePoolRequest(proto.Message): number=33, message="ResourceLabels", ) + windows_node_config: "WindowsNodeConfig" = proto.Field( + proto.MESSAGE, + number=34, + message="WindowsNodeConfig", + ) class SetNodePoolAutoscalingRequest(proto.Message): diff --git a/samples/generated_samples/snippet_metadata_google.container.v1.json b/samples/generated_samples/snippet_metadata_google.container.v1.json index 9ab16eb0..34c1cf39 100644 --- a/samples/generated_samples/snippet_metadata_google.container.v1.json +++ b/samples/generated_samples/snippet_metadata_google.container.v1.json @@ -8,7 +8,7 @@ ], "language": "PYTHON", "name": "google-cloud-container", - "version": "2.14.0" + "version": "0.1.0" }, "snippets": [ { diff --git a/samples/generated_samples/snippet_metadata_google.container.v1beta1.json b/samples/generated_samples/snippet_metadata_google.container.v1beta1.json index e6078800..15a96218 100644 --- a/samples/generated_samples/snippet_metadata_google.container.v1beta1.json +++ b/samples/generated_samples/snippet_metadata_google.container.v1beta1.json @@ -8,7 +8,7 @@ ], "language": "PYTHON", "name": "google-cloud-container", - "version": "2.14.0" + "version": "0.1.0" }, "snippets": [ { diff --git a/scripts/fixup_container_v1_keywords.py b/scripts/fixup_container_v1_keywords.py index 854df513..80b16377 100644 --- a/scripts/fixup_container_v1_keywords.py +++ b/scripts/fixup_container_v1_keywords.py @@ -71,7 +71,7 @@ class containerCallTransformer(cst.CSTTransformer): 'start_ip_rotation': ('project_id', 'zone', 'cluster_id', 'name', 'rotate_credentials', ), 'update_cluster': ('update', 'project_id', 'zone', 'cluster_id', 'name', ), 'update_master': ('master_version', 'project_id', 'zone', 'cluster_id', 'name', ), - 'update_node_pool': ('node_version', 'image_type', 'project_id', 'zone', 'cluster_id', 'node_pool_id', 'name', 'locations', 'workload_metadata_config', 'upgrade_settings', 'tags', 'taints', 'labels', 'linux_node_config', 'kubelet_config', 'node_network_config', 'gcfs_config', 'confidential_nodes', 'gvnic', 'fast_socket', 'logging_config', 'resource_labels', ), + 'update_node_pool': ('node_version', 'image_type', 'project_id', 'zone', 'cluster_id', 'node_pool_id', 'name', 'locations', 'workload_metadata_config', 'upgrade_settings', 'tags', 'taints', 'labels', 'linux_node_config', 'kubelet_config', 'node_network_config', 'gcfs_config', 'confidential_nodes', 'gvnic', 'etag', 'fast_socket', 'logging_config', 'resource_labels', 'windows_node_config', ), } def leave_Call(self, original: cst.Call, updated: cst.Call) -> cst.CSTNode: diff --git a/scripts/fixup_container_v1beta1_keywords.py b/scripts/fixup_container_v1beta1_keywords.py index 34053f77..6bb191d0 100644 --- a/scripts/fixup_container_v1beta1_keywords.py +++ b/scripts/fixup_container_v1beta1_keywords.py @@ -72,7 +72,7 @@ class containerCallTransformer(cst.CSTTransformer): 'start_ip_rotation': ('project_id', 'zone', 'cluster_id', 'name', 'rotate_credentials', ), 'update_cluster': ('project_id', 'zone', 'cluster_id', 'update', 'name', ), 'update_master': ('project_id', 'zone', 'cluster_id', 'master_version', 'name', ), - 'update_node_pool': ('project_id', 'zone', 'cluster_id', 'node_pool_id', 'node_version', 'image_type', 'locations', 'workload_metadata_config', 'name', 'upgrade_settings', 'tags', 'taints', 'labels', 'linux_node_config', 'kubelet_config', 'node_network_config', 'gcfs_config', 'confidential_nodes', 'gvnic', 'fast_socket', 'logging_config', 'resource_labels', ), + 'update_node_pool': ('project_id', 'zone', 'cluster_id', 'node_pool_id', 'node_version', 'image_type', 'locations', 'workload_metadata_config', 'name', 'upgrade_settings', 'tags', 'taints', 'labels', 'linux_node_config', 'kubelet_config', 'node_network_config', 'gcfs_config', 'confidential_nodes', 'gvnic', 'fast_socket', 'logging_config', 'resource_labels', 'windows_node_config', ), } def leave_Call(self, original: cst.Call, updated: cst.Call) -> cst.CSTNode: diff --git a/tests/unit/gapic/container_v1/test_cluster_manager.py b/tests/unit/gapic/container_v1/test_cluster_manager.py index faedea20..fce41dee 100644 --- a/tests/unit/gapic/container_v1/test_cluster_manager.py +++ b/tests/unit/gapic/container_v1/test_cluster_manager.py @@ -987,6 +987,7 @@ def test_get_cluster(request_type, transport: str = "grpc"): enable_tpu=True, tpu_ipv4_cidr_block="tpu_ipv4_cidr_block_value", id="id_value", + etag="etag_value", ) response = client.get_cluster(request) @@ -1026,6 +1027,7 @@ def test_get_cluster(request_type, transport: str = "grpc"): assert response.enable_tpu is True assert response.tpu_ipv4_cidr_block == "tpu_ipv4_cidr_block_value" assert response.id == "id_value" + assert response.etag == "etag_value" def test_get_cluster_empty_call(): @@ -1091,6 +1093,7 @@ async def test_get_cluster_async( enable_tpu=True, tpu_ipv4_cidr_block="tpu_ipv4_cidr_block_value", id="id_value", + etag="etag_value", ) ) response = await client.get_cluster(request) @@ -1131,6 +1134,7 @@ async def test_get_cluster_async( assert response.enable_tpu is True assert response.tpu_ipv4_cidr_block == "tpu_ipv4_cidr_block_value" assert response.id == "id_value" + assert response.etag == "etag_value" @pytest.mark.asyncio @@ -5952,6 +5956,7 @@ def test_get_node_pool(request_type, transport: str = "grpc"): status=cluster_service.NodePool.Status.PROVISIONING, status_message="status_message_value", pod_ipv4_cidr_size=1856, + etag="etag_value", ) response = client.get_node_pool(request) @@ -5971,6 +5976,7 @@ def test_get_node_pool(request_type, transport: str = "grpc"): assert response.status == cluster_service.NodePool.Status.PROVISIONING assert response.status_message == "status_message_value" assert response.pod_ipv4_cidr_size == 1856 + assert response.etag == "etag_value" def test_get_node_pool_empty_call(): @@ -6016,6 +6022,7 @@ async def test_get_node_pool_async( status=cluster_service.NodePool.Status.PROVISIONING, status_message="status_message_value", pod_ipv4_cidr_size=1856, + etag="etag_value", ) ) response = await client.get_node_pool(request) @@ -6036,6 +6043,7 @@ async def test_get_node_pool_async( assert response.status == cluster_service.NodePool.Status.PROVISIONING assert response.status_message == "status_message_value" assert response.pod_ipv4_cidr_size == 1856 + assert response.etag == "etag_value" @pytest.mark.asyncio