Skip to content

Commit 4564a88

Browse files
feat: Add Cloud_Resource Connection Support (#181)
* feat: Add Cloud_Resource Connection Support PiperOrigin-RevId: 433053270 Source-Link: googleapis/googleapis@eb0700c Source-Link: googleapis/googleapis-gen@0678286 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMDY3ODI4NjllZDJiODUzYjI3NTBlYTJhNzhmYzRiMDgxYTgyMmRlOSJ9 * 🦉 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> Co-authored-by: Anthonios Partheniou <partheniou@google.com>
1 parent 254fb1e commit 4564a88

File tree

4 files changed

+38
-0
lines changed

4 files changed

+38
-0
lines changed

packages/google-cloud-bigquery-connection/google/cloud/bigquery_connection/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
from google.cloud.bigquery_connection_v1.types.connection import AwsAccessRole
2525
from google.cloud.bigquery_connection_v1.types.connection import AwsCrossAccountRole
2626
from google.cloud.bigquery_connection_v1.types.connection import AwsProperties
27+
from google.cloud.bigquery_connection_v1.types.connection import CloudResourceProperties
2728
from google.cloud.bigquery_connection_v1.types.connection import CloudSpannerProperties
2829
from google.cloud.bigquery_connection_v1.types.connection import CloudSqlCredential
2930
from google.cloud.bigquery_connection_v1.types.connection import CloudSqlProperties
@@ -41,6 +42,7 @@
4142
"AwsAccessRole",
4243
"AwsCrossAccountRole",
4344
"AwsProperties",
45+
"CloudResourceProperties",
4446
"CloudSpannerProperties",
4547
"CloudSqlCredential",
4648
"CloudSqlProperties",

packages/google-cloud-bigquery-connection/google/cloud/bigquery_connection_v1/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
from .types.connection import AwsAccessRole
2121
from .types.connection import AwsCrossAccountRole
2222
from .types.connection import AwsProperties
23+
from .types.connection import CloudResourceProperties
2324
from .types.connection import CloudSpannerProperties
2425
from .types.connection import CloudSqlCredential
2526
from .types.connection import CloudSqlProperties
@@ -36,6 +37,7 @@
3637
"AwsAccessRole",
3738
"AwsCrossAccountRole",
3839
"AwsProperties",
40+
"CloudResourceProperties",
3941
"CloudSpannerProperties",
4042
"CloudSqlCredential",
4143
"CloudSqlProperties",

packages/google-cloud-bigquery-connection/google/cloud/bigquery_connection_v1/types/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717
AwsAccessRole,
1818
AwsCrossAccountRole,
1919
AwsProperties,
20+
CloudResourceProperties,
2021
CloudSpannerProperties,
2122
CloudSqlCredential,
2223
CloudSqlProperties,
@@ -33,6 +34,7 @@
3334
"AwsAccessRole",
3435
"AwsCrossAccountRole",
3536
"AwsProperties",
37+
"CloudResourceProperties",
3638
"CloudSpannerProperties",
3739
"CloudSqlCredential",
3840
"CloudSqlProperties",

packages/google-cloud-bigquery-connection/google/cloud/bigquery_connection_v1/types/connection.py

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
"AwsProperties",
3535
"AwsCrossAccountRole",
3636
"AwsAccessRole",
37+
"CloudResourceProperties",
3738
},
3839
)
3940

@@ -175,6 +176,10 @@ class Connection(proto.Message):
175176
cloud_spanner (google.cloud.bigquery_connection_v1.types.CloudSpannerProperties):
176177
Cloud Spanner properties.
177178
179+
This field is a member of `oneof`_ ``properties``.
180+
cloud_resource (google.cloud.bigquery_connection_v1.types.CloudResourceProperties):
181+
Cloud Resource properties.
182+
178183
This field is a member of `oneof`_ ``properties``.
179184
creation_time (int):
180185
Output only. The creation timestamp of the
@@ -199,6 +204,9 @@ class Connection(proto.Message):
199204
cloud_spanner = proto.Field(
200205
proto.MESSAGE, number=21, oneof="properties", message="CloudSpannerProperties",
201206
)
207+
cloud_resource = proto.Field(
208+
proto.MESSAGE, number=22, oneof="properties", message="CloudResourceProperties",
209+
)
202210
creation_time = proto.Field(proto.INT64, number=5,)
203211
last_modified_time = proto.Field(proto.INT64, number=6,)
204212
has_credential = proto.Field(proto.BOOL, number=7,)
@@ -339,4 +347,28 @@ class AwsAccessRole(proto.Message):
339347
identity = proto.Field(proto.STRING, number=2,)
340348

341349

350+
class CloudResourceProperties(proto.Message):
351+
r"""Container for connection properties for delegation of access
352+
to GCP resources.
353+
354+
Attributes:
355+
service_account_id (str):
356+
Output only. The account ID of the service
357+
created for the purpose of this connection.
358+
The service account does not have any
359+
permissions associated with it when it is
360+
created. After creation, customers delegate
361+
permissions to the service account. When the
362+
connection is used in the context of an
363+
operation in BigQuery, the service account will
364+
be used to connect to the desired resources in
365+
GCP.
366+
367+
The account ID is in the form of:
368+
<service-1234>@gcp-sa-bigquery-cloudresource.iam.gserviceaccount.com
369+
"""
370+
371+
service_account_id = proto.Field(proto.STRING, number=1,)
372+
373+
342374
__all__ = tuple(sorted(__protobuf__.manifest))

0 commit comments

Comments
 (0)