Skip to content

Commit 93dd15a

Browse files
author
phoenix
committed
Update SDK to 9e3b5bea423b52a4510fbb70de9b2df76f9d39ed
1 parent ad941ec commit 93dd15a

File tree

15 files changed

+57
-53
lines changed

15 files changed

+57
-53
lines changed

.codegen/_openapi_sha

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
8f5eedbc991c4f04ce1284406577b0c92d59a224
1+
9e3b5bea423b52a4510fbb70de9b2df76f9d39ed

databricks/sdk/service/catalog.py

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

databricks/sdk/service/compute.py

Lines changed: 6 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

databricks/sdk/service/sql.py

Lines changed: 5 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/account/iam/workspace_assignment.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,9 +74,9 @@
7474
7575
spn_id = spn.id
7676
77-
workspace_id = os.environ["TEST_WORKSPACE_ID"]
77+
workspace_id = os.environ["DUMMY_WORKSPACE_ID"]
7878
79-
a.workspace_assignment.update(
79+
_ = a.workspace_assignment.update(
8080
workspace_id=workspace_id,
8181
principal_id=spn_id,
8282
permissions=[iam.WorkspacePermission.USER],

docs/account/provisioning/storage.rst

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616

1717
.. code-block::
1818
19+
import os
1920
import time
2021
2122
from databricks.sdk import AccountClient
@@ -25,8 +26,11 @@
2526
2627
storage = a.storage.create(
2728
storage_configuration_name=f"sdk-{time.time_ns()}",
28-
root_bucket_info=provisioning.RootBucketInfo(bucket_name=f"sdk-{time.time_ns()}"),
29+
root_bucket_info=provisioning.RootBucketInfo(bucket_name=os.environ["TEST_ROOT_BUCKET"]),
2930
)
31+
32+
# cleanup
33+
a.storage.delete(storage_configuration_id=storage.storage_configuration_id)
3034
3135
Creates a Databricks storage configuration for an account.
3236

docs/dbdataclasses/catalog.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1497,7 +1497,7 @@ These dataclasses are used in the SDK to represent API requests and responses fo
14971497

14981498
.. py:class:: SecurableKind
14991499
1500-
Latest kind: SECRET_EXTERNAL_AWS_SECRETS_MANAGER = 273; Next id:274
1500+
Latest kind: CREDENTIAL_STORAGE_UC_CONNECTION = 275; Next id:276
15011501

15021502
.. py:attribute:: TABLE_DB_STORAGE
15031503
:value: "TABLE_DB_STORAGE"

docs/workspace/catalog/external_locations.rst

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -105,20 +105,20 @@
105105
106106
credential = w.storage_credentials.create(
107107
name=f"sdk-{time.time_ns()}",
108-
aws_iam_role=catalog.AwsIamRoleRequest(role_arn=os.environ["TEST_METASTORE_DATA_ACCESS_ARN"]),
108+
aws_iam_role=catalog.AwsIamRole(role_arn=os.environ["TEST_METASTORE_DATA_ACCESS_ARN"]),
109109
)
110110
111111
created = w.external_locations.create(
112112
name=f"sdk-{time.time_ns()}",
113113
credential_name=credential.name,
114-
url="s3://%s/%s" % (os.environ["TEST_BUCKET"], f"sdk-{time.time_ns()}"),
114+
url=f's3://{os.environ["TEST_BUCKET"]}/sdk-{time.time_ns()}',
115115
)
116116
117-
_ = w.external_locations.get(name=created.name)
117+
_ = w.external_locations.get(get=created.name)
118118
119119
# cleanup
120-
w.storage_credentials.delete(name=credential.name)
121-
w.external_locations.delete(name=created.name)
120+
w.storage_credentials.delete(delete=credential.name)
121+
w.external_locations.delete(delete=created.name)
122122
123123
Gets an external location from the metastore. The caller must be either a metastore admin, the owner
124124
of the external location, or a user that has some privilege on the external location.
@@ -140,11 +140,10 @@
140140
.. code-block::
141141
142142
from databricks.sdk import WorkspaceClient
143-
from databricks.sdk.service import catalog
144143
145144
w = WorkspaceClient()
146145
147-
all = w.external_locations.list(catalog.ListExternalLocationsRequest())
146+
all = w.external_locations.list()
148147
149148
Gets an array of external locations (__ExternalLocationInfo__ objects) from the metastore. The caller
150149
must be a metastore admin, the owner of the external location, or a user that has some privilege on

docs/workspace/catalog/storage_credentials.rst

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,11 @@
3232
3333
created = w.storage_credentials.create(
3434
name=f"sdk-{time.time_ns()}",
35-
aws_iam_role=catalog.AwsIamRole(role_arn=os.environ["TEST_METASTORE_DATA_ACCESS_ARN"]),
35+
aws_iam_role=catalog.AwsIamRoleRequest(role_arn=os.environ["TEST_METASTORE_DATA_ACCESS_ARN"]),
3636
)
3737
3838
# cleanup
39-
w.storage_credentials.delete(delete=created.name)
39+
w.storage_credentials.delete(name=created.name)
4040
4141
Creates a new storage credential.
4242

@@ -173,17 +173,17 @@
173173
174174
created = w.storage_credentials.create(
175175
name=f"sdk-{time.time_ns()}",
176-
aws_iam_role=catalog.AwsIamRole(role_arn=os.environ["TEST_METASTORE_DATA_ACCESS_ARN"]),
176+
aws_iam_role=catalog.AwsIamRoleRequest(role_arn=os.environ["TEST_METASTORE_DATA_ACCESS_ARN"]),
177177
)
178178
179179
_ = w.storage_credentials.update(
180180
name=created.name,
181181
comment=f"sdk-{time.time_ns()}",
182-
aws_iam_role=catalog.AwsIamRole(role_arn=os.environ["TEST_METASTORE_DATA_ACCESS_ARN"]),
182+
aws_iam_role=catalog.AwsIamRoleRequest(role_arn=os.environ["TEST_METASTORE_DATA_ACCESS_ARN"]),
183183
)
184184
185185
# cleanup
186-
w.storage_credentials.delete(delete=created.name)
186+
w.storage_credentials.delete(name=created.name)
187187
188188
Updates a storage credential on the metastore.
189189

docs/workspace/catalog/tables.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@
156156
157157
created_schema = w.schemas.create(name=f"sdk-{time.time_ns()}", catalog_name=created_catalog.name)
158158
159-
summaries = w.tables.list_summaries(catalog_name=created_catalog.name, schema_name_pattern=created_schema.name)
159+
all_tables = w.tables.list(catalog_name=created_catalog.name, schema_name=created_schema.name)
160160
161161
# cleanup
162162
w.schemas.delete(full_name=created_schema.full_name)

0 commit comments

Comments
 (0)