Skip to content
This repository was archived by the owner on Nov 29, 2023. It is now read-only.

Commit 4d61084

Browse files
feat: add a FastSocket API (#318)
* feat: add a FastSocket API PiperOrigin-RevId: 491259489 Source-Link: googleapis/googleapis@39bcdf4 Source-Link: https://github.com/googleapis/googleapis-gen/commit/ee2470d9e7906d0764adb562f4d4cc41f0d6c96f Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiZWUyNDcwZDllNzkwNmQwNzY0YWRiNTYyZjRkNGNjNDFmMGQ2Yzk2ZiJ9 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
1 parent 0d49eb0 commit 4d61084

File tree

5 files changed

+44
-4
lines changed

5 files changed

+44
-4
lines changed

google/cloud/container/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@
5555
DeleteNodePoolRequest,
5656
DnsCacheConfig,
5757
DNSConfig,
58+
FastSocket,
5859
GatewayAPIConfig,
5960
GcePersistentDiskCsiDriverConfig,
6061
GcfsConfig,
@@ -200,6 +201,7 @@
200201
"DeleteNodePoolRequest",
201202
"DnsCacheConfig",
202203
"DNSConfig",
204+
"FastSocket",
203205
"GatewayAPIConfig",
204206
"GcePersistentDiskCsiDriverConfig",
205207
"GcfsConfig",

google/cloud/container_v1/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
DeleteNodePoolRequest,
5151
DnsCacheConfig,
5252
DNSConfig,
53+
FastSocket,
5354
GatewayAPIConfig,
5455
GcePersistentDiskCsiDriverConfig,
5556
GcfsConfig,
@@ -196,6 +197,7 @@
196197
"DeleteClusterRequest",
197198
"DeleteNodePoolRequest",
198199
"DnsCacheConfig",
200+
"FastSocket",
199201
"GPUSharingConfig",
200202
"GatewayAPIConfig",
201203
"GcePersistentDiskCsiDriverConfig",

google/cloud/container_v1/types/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@
4444
DeleteNodePoolRequest,
4545
DnsCacheConfig,
4646
DNSConfig,
47+
FastSocket,
4748
GatewayAPIConfig,
4849
GcePersistentDiskCsiDriverConfig,
4950
GcfsConfig,
@@ -187,6 +188,7 @@
187188
"DeleteNodePoolRequest",
188189
"DnsCacheConfig",
189190
"DNSConfig",
191+
"FastSocket",
190192
"GatewayAPIConfig",
191193
"GcePersistentDiskCsiDriverConfig",
192194
"GcfsConfig",

google/cloud/container_v1/types/cluster_service.py

Lines changed: 37 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -153,6 +153,7 @@
153153
"DefaultSnatStatus",
154154
"ShieldedNodes",
155155
"VirtualNIC",
156+
"FastSocket",
156157
"NotificationConfig",
157158
"ConfidentialNodes",
158159
"UpgradeEvent",
@@ -507,6 +508,11 @@ class NodeConfig(proto.Message):
507508
Confidential nodes config.
508509
All the nodes in the node pool will be
509510
Confidential VM once enabled.
511+
fast_socket (google.cloud.container_v1.types.FastSocket):
512+
Enable or disable NCCL fast socket for the
513+
node pool.
514+
515+
This field is a member of `oneof`_ ``_fast_socket``.
510516
resource_labels (MutableMapping[str, str]):
511517
The resource labels for the node pool to use
512518
to annotate any related Google Compute Engine
@@ -637,6 +643,12 @@ class NodeConfig(proto.Message):
637643
number=35,
638644
message="ConfidentialNodes",
639645
)
646+
fast_socket: "FastSocket" = proto.Field(
647+
proto.MESSAGE,
648+
number=36,
649+
optional=True,
650+
message="FastSocket",
651+
)
640652
resource_labels: MutableMapping[str, str] = proto.MapField(
641653
proto.STRING,
642654
proto.STRING,
@@ -1588,9 +1600,8 @@ class BinaryAuthorization(proto.Message):
15881600
EVALUATION_MODE_UNSPECIFIED, this field is ignored.
15891601
evaluation_mode (google.cloud.container_v1.types.BinaryAuthorization.EvaluationMode):
15901602
Mode of operation for binauthz policy
1591-
evaluation. Currently the only options are
1592-
equivalent to enable/disable. If unspecified,
1593-
defaults to DISABLED.
1603+
evaluation. If unspecified, defaults to
1604+
DISABLED.
15941605
"""
15951606

15961607
class EvaluationMode(proto.Enum):
@@ -3276,6 +3287,9 @@ class UpdateNodePoolRequest(proto.Message):
32763287
Confidential VM once enabled.
32773288
gvnic (google.cloud.container_v1.types.VirtualNIC):
32783289
Enable or disable gvnic on the node pool.
3290+
fast_socket (google.cloud.container_v1.types.FastSocket):
3291+
Enable or disable NCCL fast socket for the
3292+
node pool.
32793293
logging_config (google.cloud.container_v1.types.NodePoolLoggingConfig):
32803294
Logging configuration.
32813295
resource_labels (google.cloud.container_v1.types.ResourceLabels):
@@ -3371,6 +3385,11 @@ class UpdateNodePoolRequest(proto.Message):
33713385
number=29,
33723386
message="VirtualNIC",
33733387
)
3388+
fast_socket: "FastSocket" = proto.Field(
3389+
proto.MESSAGE,
3390+
number=31,
3391+
message="FastSocket",
3392+
)
33743393
logging_config: "NodePoolLoggingConfig" = proto.Field(
33753394
proto.MESSAGE,
33763395
number=32,
@@ -6810,6 +6829,21 @@ class VirtualNIC(proto.Message):
68106829
)
68116830

68126831

6832+
class FastSocket(proto.Message):
6833+
r"""Configuration of Fast Socket feature.
6834+
6835+
Attributes:
6836+
enabled (bool):
6837+
Whether Fast Socket features are enabled in
6838+
the node pool.
6839+
"""
6840+
6841+
enabled: bool = proto.Field(
6842+
proto.BOOL,
6843+
number=1,
6844+
)
6845+
6846+
68136847
class NotificationConfig(proto.Message):
68146848
r"""NotificationConfig is the configuration of notifications.
68156849

scripts/fixup_container_v1_keywords.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ class containerCallTransformer(cst.CSTTransformer):
7171
'start_ip_rotation': ('project_id', 'zone', 'cluster_id', 'name', 'rotate_credentials', ),
7272
'update_cluster': ('update', 'project_id', 'zone', 'cluster_id', 'name', ),
7373
'update_master': ('master_version', 'project_id', 'zone', 'cluster_id', 'name', ),
74-
'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', 'logging_config', 'resource_labels', ),
74+
'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', ),
7575
}
7676

7777
def leave_Call(self, original: cst.Call, updated: cst.Call) -> cst.CSTNode:

0 commit comments

Comments
 (0)