@databricks/sdk-uc-tables 0.0.0-dev → 0.1.0-dev.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +203 -0
- package/dist/v1/client.d.ts +127 -0
- package/dist/v1/client.d.ts.map +1 -0
- package/dist/v1/client.js +453 -0
- package/dist/v1/client.js.map +1 -0
- package/dist/v1/index.d.ts +4 -0
- package/dist/v1/index.d.ts.map +1 -0
- package/dist/v1/index.js +4 -0
- package/dist/v1/index.js.map +1 -0
- package/dist/v1/model.d.ts +863 -0
- package/dist/v1/model.d.ts.map +1 -0
- package/dist/v1/model.js +1103 -0
- package/dist/v1/model.js.map +1 -0
- package/dist/v1/transport.d.ts +5 -0
- package/dist/v1/transport.d.ts.map +1 -0
- package/dist/v1/transport.js +57 -0
- package/dist/v1/transport.js.map +1 -0
- package/dist/v1/utils.d.ts +22 -0
- package/dist/v1/utils.d.ts.map +1 -0
- package/dist/v1/utils.js +113 -0
- package/dist/v1/utils.js.map +1 -0
- package/package.json +38 -4
- package/src/v1/client.ts +567 -0
- package/src/v1/index.ts +58 -0
- package/src/v1/model.ts +1822 -0
- package/src/v1/transport.ts +73 -0
- package/src/v1/utils.ts +156 -0
- package/README.md +0 -1
- package/index.js +0 -1
|
@@ -0,0 +1,453 @@
|
|
|
1
|
+
// Code generated from API definition by Databricks SDK Generator. DO NOT EDIT.
|
|
2
|
+
import { VERSION as AUTH_VERSION } from '@databricks/sdk-auth';
|
|
3
|
+
import { createDefault } from '@databricks/sdk-core/clientinfo';
|
|
4
|
+
import { NoOpLogger } from '@databricks/sdk-core/logger';
|
|
5
|
+
import { newHttpClient } from './transport';
|
|
6
|
+
import { buildHttpRequest, executeCall, executeHttpCall, marshalRequest, parseResponse, } from './utils';
|
|
7
|
+
import pkgJson from '../../package.json' with { type: 'json' };
|
|
8
|
+
import { marshalCreateTableConstraintRequestSchema, marshalCreateTableRequestSchema, marshalUpdateTableRequestSchema, unmarshalDeleteTableConstraintRequest_ResponseSchema, unmarshalDeleteTableRequest_ResponseSchema, unmarshalListTableSummariesRequest_ResponseSchema, unmarshalListTablesRequest_ResponseSchema, unmarshalTableConstraintSchema, unmarshalTableExistsRequest_ResponseSchema, unmarshalTableInfoSchema, unmarshalUpdateTableRequest_ResponseSchema, } from './model';
|
|
9
|
+
// Package identity segment for this client to be used in the User-Agent header.
|
|
10
|
+
const PACKAGE_SEGMENT = {
|
|
11
|
+
key: 'sdk-js-' + pkgJson.name.replace(/^@[^/]+\/sdk-/, ''),
|
|
12
|
+
value: pkgJson.version,
|
|
13
|
+
};
|
|
14
|
+
export class TablesClient {
|
|
15
|
+
host;
|
|
16
|
+
// Workspace ID used to route workspace-level calls on unified hosts (SPOG).
|
|
17
|
+
// When set, workspace-level methods send X-Databricks-Org-Id on every
|
|
18
|
+
// request.
|
|
19
|
+
workspaceId;
|
|
20
|
+
httpClient;
|
|
21
|
+
logger;
|
|
22
|
+
// User-Agent header value. Composed once at construction from
|
|
23
|
+
// createDefault() merged with this package's identity and the active
|
|
24
|
+
// credential's name.
|
|
25
|
+
userAgent;
|
|
26
|
+
constructor(options) {
|
|
27
|
+
if (options.host === undefined) {
|
|
28
|
+
throw new Error('Host is required.');
|
|
29
|
+
}
|
|
30
|
+
this.host = options.host.replace(/\/$/, '');
|
|
31
|
+
this.workspaceId = options.workspaceId;
|
|
32
|
+
this.logger = options.logger ?? new NoOpLogger();
|
|
33
|
+
const info = createDefault()
|
|
34
|
+
.with(PACKAGE_SEGMENT)
|
|
35
|
+
.with({ key: 'sdk-js-auth', value: AUTH_VERSION })
|
|
36
|
+
.with({ key: 'auth', value: options.credentials?.name() ?? 'default' });
|
|
37
|
+
this.userAgent = info.toString();
|
|
38
|
+
this.httpClient = newHttpClient(options);
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Creates a new table in the specified catalog and schema.
|
|
42
|
+
*
|
|
43
|
+
* To create an external delta table, the caller must have the **EXTERNAL_USE_SCHEMA** privilege on the parent schema
|
|
44
|
+
* and the **EXTERNAL_USE_LOCATION** privilege on the external location. These privileges must always be granted explicitly,
|
|
45
|
+
* and cannot be inherited through ownership or **ALL_PRIVILEGES**.
|
|
46
|
+
*
|
|
47
|
+
* Standard UC permissions needed to create tables still apply: **USE_CATALOG** on the parent catalog (or ownership of
|
|
48
|
+
* the parent catalog), **CREATE_TABLE** and **USE_SCHEMA** on the parent schema (or ownership of the parent schema),
|
|
49
|
+
* and **CREATE_EXTERNAL_TABLE** on external location.
|
|
50
|
+
*
|
|
51
|
+
* The **columns** field needs to be in a Spark compatible format, so we recommend you use Spark to create these tables.
|
|
52
|
+
* The API itself does not validate the correctness of the column spec. If the spec is not Spark compatible,
|
|
53
|
+
* the tables may not be readable by Databricks Runtime.
|
|
54
|
+
*
|
|
55
|
+
*
|
|
56
|
+
*
|
|
57
|
+
*
|
|
58
|
+
*
|
|
59
|
+
*
|
|
60
|
+
*
|
|
61
|
+
* NOTE: The Create Table API for external clients only supports creating **external delta tables**. The values shown
|
|
62
|
+
* in the respective enums are all values supported by <Databricks>, however for this specific Create Table API,
|
|
63
|
+
* only **table_type** **EXTERNAL** and **data_source_format** **DELTA** are supported. Additionally, column masks
|
|
64
|
+
* are not supported when creating tables through this API.
|
|
65
|
+
*/
|
|
66
|
+
async createTable(req, options) {
|
|
67
|
+
const url = `${this.host}/api/2.1/unity-catalog/tables`;
|
|
68
|
+
const body = marshalRequest(req, marshalCreateTableRequestSchema);
|
|
69
|
+
let resp;
|
|
70
|
+
const call = async (callSignal) => {
|
|
71
|
+
const headers = new Headers({ 'Content-Type': 'application/json' });
|
|
72
|
+
if (this.workspaceId !== undefined) {
|
|
73
|
+
headers.set('X-Databricks-Org-Id', this.workspaceId);
|
|
74
|
+
}
|
|
75
|
+
headers.set('User-Agent', this.userAgent);
|
|
76
|
+
const httpReq = buildHttpRequest('POST', url, headers, callSignal, body);
|
|
77
|
+
const respBody = await executeHttpCall({
|
|
78
|
+
request: httpReq,
|
|
79
|
+
httpClient: this.httpClient,
|
|
80
|
+
logger: this.logger,
|
|
81
|
+
});
|
|
82
|
+
resp = parseResponse(respBody, unmarshalTableInfoSchema);
|
|
83
|
+
};
|
|
84
|
+
await executeCall(call, options);
|
|
85
|
+
if (resp === undefined) {
|
|
86
|
+
throw new Error('API call completed without a result.');
|
|
87
|
+
}
|
|
88
|
+
return resp;
|
|
89
|
+
}
|
|
90
|
+
/**
|
|
91
|
+
* Creates a new table constraint.
|
|
92
|
+
*
|
|
93
|
+
* For the table constraint creation to succeed, the user must satisfy both of these conditions:
|
|
94
|
+
* - the user must have the **USE_CATALOG** privilege on the table's parent catalog,
|
|
95
|
+
* the **USE_SCHEMA** privilege on the table's parent schema, and be the owner of the table.
|
|
96
|
+
* - if the new constraint is a __ForeignKeyConstraint__,
|
|
97
|
+
* the user must have the **USE_CATALOG** privilege on the referenced parent table's catalog,
|
|
98
|
+
* the **USE_SCHEMA** privilege on the referenced parent table's schema,
|
|
99
|
+
* and be the owner of the referenced parent table.
|
|
100
|
+
*/
|
|
101
|
+
async createTableConstraint(req, options) {
|
|
102
|
+
const url = `${this.host}/api/2.1/unity-catalog/constraints`;
|
|
103
|
+
const body = marshalRequest(req, marshalCreateTableConstraintRequestSchema);
|
|
104
|
+
let resp;
|
|
105
|
+
const call = async (callSignal) => {
|
|
106
|
+
const headers = new Headers({ 'Content-Type': 'application/json' });
|
|
107
|
+
if (this.workspaceId !== undefined) {
|
|
108
|
+
headers.set('X-Databricks-Org-Id', this.workspaceId);
|
|
109
|
+
}
|
|
110
|
+
headers.set('User-Agent', this.userAgent);
|
|
111
|
+
const httpReq = buildHttpRequest('POST', url, headers, callSignal, body);
|
|
112
|
+
const respBody = await executeHttpCall({
|
|
113
|
+
request: httpReq,
|
|
114
|
+
httpClient: this.httpClient,
|
|
115
|
+
logger: this.logger,
|
|
116
|
+
});
|
|
117
|
+
resp = parseResponse(respBody, unmarshalTableConstraintSchema);
|
|
118
|
+
};
|
|
119
|
+
await executeCall(call, options);
|
|
120
|
+
if (resp === undefined) {
|
|
121
|
+
throw new Error('API call completed without a result.');
|
|
122
|
+
}
|
|
123
|
+
return resp;
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* Deletes a table from the specified parent catalog and schema.
|
|
127
|
+
* The caller must be the owner of the parent catalog, have the **USE_CATALOG** privilege on the parent catalog and be the owner of the parent schema,
|
|
128
|
+
* or be the owner of the table and have the **USE_CATALOG** privilege on the parent catalog and the **USE_SCHEMA** privilege on the parent schema.
|
|
129
|
+
*/
|
|
130
|
+
async deleteTable(req, options) {
|
|
131
|
+
const url = `${this.host}/api/2.1/unity-catalog/tables/${req.fullNameArg ?? ''}`;
|
|
132
|
+
let resp;
|
|
133
|
+
const call = async (callSignal) => {
|
|
134
|
+
const headers = new Headers();
|
|
135
|
+
if (this.workspaceId !== undefined) {
|
|
136
|
+
headers.set('X-Databricks-Org-Id', this.workspaceId);
|
|
137
|
+
}
|
|
138
|
+
headers.set('User-Agent', this.userAgent);
|
|
139
|
+
const httpReq = buildHttpRequest('DELETE', url, headers, callSignal);
|
|
140
|
+
const respBody = await executeHttpCall({
|
|
141
|
+
request: httpReq,
|
|
142
|
+
httpClient: this.httpClient,
|
|
143
|
+
logger: this.logger,
|
|
144
|
+
});
|
|
145
|
+
resp = parseResponse(respBody, unmarshalDeleteTableRequest_ResponseSchema);
|
|
146
|
+
};
|
|
147
|
+
await executeCall(call, options);
|
|
148
|
+
if (resp === undefined) {
|
|
149
|
+
throw new Error('API call completed without a result.');
|
|
150
|
+
}
|
|
151
|
+
return resp;
|
|
152
|
+
}
|
|
153
|
+
/**
|
|
154
|
+
* Deletes a table constraint.
|
|
155
|
+
*
|
|
156
|
+
* For the table constraint deletion to succeed, the user must satisfy both of these conditions:
|
|
157
|
+
* - the user must have the **USE_CATALOG** privilege on the table's parent catalog,
|
|
158
|
+
* the **USE_SCHEMA** privilege on the table's parent schema, and be the owner of the table.
|
|
159
|
+
* - if __cascade__ argument is **true**, the user must have the following permissions on all of the child tables:
|
|
160
|
+
* the **USE_CATALOG** privilege on the table's catalog,
|
|
161
|
+
* the **USE_SCHEMA** privilege on the table's schema,
|
|
162
|
+
* and be the owner of the table.
|
|
163
|
+
*/
|
|
164
|
+
async deleteTableConstraint(req, options) {
|
|
165
|
+
const url = `${this.host}/api/2.1/unity-catalog/constraints/${req.fullNameArg ?? ''}`;
|
|
166
|
+
const params = new URLSearchParams();
|
|
167
|
+
if (req.constraintName !== undefined) {
|
|
168
|
+
params.append('constraint_name', req.constraintName);
|
|
169
|
+
}
|
|
170
|
+
if (req.cascade !== undefined) {
|
|
171
|
+
params.append('cascade', String(req.cascade));
|
|
172
|
+
}
|
|
173
|
+
const query = params.toString();
|
|
174
|
+
const fullUrl = query !== '' ? `${url}?${query}` : url;
|
|
175
|
+
let resp;
|
|
176
|
+
const call = async (callSignal) => {
|
|
177
|
+
const headers = new Headers();
|
|
178
|
+
if (this.workspaceId !== undefined) {
|
|
179
|
+
headers.set('X-Databricks-Org-Id', this.workspaceId);
|
|
180
|
+
}
|
|
181
|
+
headers.set('User-Agent', this.userAgent);
|
|
182
|
+
const httpReq = buildHttpRequest('DELETE', fullUrl, headers, callSignal);
|
|
183
|
+
const respBody = await executeHttpCall({
|
|
184
|
+
request: httpReq,
|
|
185
|
+
httpClient: this.httpClient,
|
|
186
|
+
logger: this.logger,
|
|
187
|
+
});
|
|
188
|
+
resp = parseResponse(respBody, unmarshalDeleteTableConstraintRequest_ResponseSchema);
|
|
189
|
+
};
|
|
190
|
+
await executeCall(call, options);
|
|
191
|
+
if (resp === undefined) {
|
|
192
|
+
throw new Error('API call completed without a result.');
|
|
193
|
+
}
|
|
194
|
+
return resp;
|
|
195
|
+
}
|
|
196
|
+
/**
|
|
197
|
+
* Gets a table from the metastore for a specific catalog and schema.
|
|
198
|
+
* The caller must satisfy one of the following requirements:
|
|
199
|
+
* * Be a metastore admin
|
|
200
|
+
* * Be the owner of the parent catalog
|
|
201
|
+
* * Be the owner of the parent schema and have the **USE_CATALOG** privilege on the parent catalog
|
|
202
|
+
* * Have the **USE_CATALOG** privilege on the parent catalog and the **USE_SCHEMA** privilege on the parent schema,
|
|
203
|
+
* and either be the table owner or have the **SELECT** privilege on the table.
|
|
204
|
+
*/
|
|
205
|
+
async getTable(req, options) {
|
|
206
|
+
const url = `${this.host}/api/2.1/unity-catalog/tables/${req.fullNameArg ?? ''}`;
|
|
207
|
+
const params = new URLSearchParams();
|
|
208
|
+
if (req.includeDeltaMetadata !== undefined) {
|
|
209
|
+
params.append('include_delta_metadata', String(req.includeDeltaMetadata));
|
|
210
|
+
}
|
|
211
|
+
if (req.includeBrowse !== undefined) {
|
|
212
|
+
params.append('include_browse', String(req.includeBrowse));
|
|
213
|
+
}
|
|
214
|
+
if (req.includeManifestCapabilities !== undefined) {
|
|
215
|
+
params.append('include_manifest_capabilities', String(req.includeManifestCapabilities));
|
|
216
|
+
}
|
|
217
|
+
const query = params.toString();
|
|
218
|
+
const fullUrl = query !== '' ? `${url}?${query}` : url;
|
|
219
|
+
let resp;
|
|
220
|
+
const call = async (callSignal) => {
|
|
221
|
+
const headers = new Headers();
|
|
222
|
+
if (this.workspaceId !== undefined) {
|
|
223
|
+
headers.set('X-Databricks-Org-Id', this.workspaceId);
|
|
224
|
+
}
|
|
225
|
+
headers.set('User-Agent', this.userAgent);
|
|
226
|
+
const httpReq = buildHttpRequest('GET', fullUrl, headers, callSignal);
|
|
227
|
+
const respBody = await executeHttpCall({
|
|
228
|
+
request: httpReq,
|
|
229
|
+
httpClient: this.httpClient,
|
|
230
|
+
logger: this.logger,
|
|
231
|
+
});
|
|
232
|
+
resp = parseResponse(respBody, unmarshalTableInfoSchema);
|
|
233
|
+
};
|
|
234
|
+
await executeCall(call, options);
|
|
235
|
+
if (resp === undefined) {
|
|
236
|
+
throw new Error('API call completed without a result.');
|
|
237
|
+
}
|
|
238
|
+
return resp;
|
|
239
|
+
}
|
|
240
|
+
/**
|
|
241
|
+
* Gets an array of summaries for tables for a schema and catalog within the metastore. The table summaries returned are either:
|
|
242
|
+
*
|
|
243
|
+
* * summaries for tables (within the current metastore and parent catalog and schema), when the user is a metastore admin, or:
|
|
244
|
+
* * summaries for tables and schemas (within the current metastore and parent catalog)
|
|
245
|
+
* for which the user has ownership or the **SELECT** privilege on the table and ownership or **USE_SCHEMA** privilege on the schema,
|
|
246
|
+
* provided that the user also has ownership or the **USE_CATALOG** privilege on the parent catalog.
|
|
247
|
+
*
|
|
248
|
+
* There is no guarantee of a specific ordering of the elements in the array.
|
|
249
|
+
*
|
|
250
|
+
* PAGINATION BEHAVIOR: The API is by default paginated, a page may contain zero results while still providing a next_page_token.
|
|
251
|
+
* Clients must continue reading pages until next_page_token is absent, which is the only indication that the end of results has been reached.
|
|
252
|
+
*/
|
|
253
|
+
async listTableSummaries(req, options) {
|
|
254
|
+
const url = `${this.host}/api/2.1/unity-catalog/table-summaries`;
|
|
255
|
+
const params = new URLSearchParams();
|
|
256
|
+
if (req.catalogName !== undefined) {
|
|
257
|
+
params.append('catalog_name', req.catalogName);
|
|
258
|
+
}
|
|
259
|
+
if (req.schemaNamePattern !== undefined) {
|
|
260
|
+
params.append('schema_name_pattern', req.schemaNamePattern);
|
|
261
|
+
}
|
|
262
|
+
if (req.tableNamePattern !== undefined) {
|
|
263
|
+
params.append('table_name_pattern', req.tableNamePattern);
|
|
264
|
+
}
|
|
265
|
+
if (req.maxResults !== undefined) {
|
|
266
|
+
params.append('max_results', String(req.maxResults));
|
|
267
|
+
}
|
|
268
|
+
if (req.pageToken !== undefined) {
|
|
269
|
+
params.append('page_token', req.pageToken);
|
|
270
|
+
}
|
|
271
|
+
if (req.includeManifestCapabilities !== undefined) {
|
|
272
|
+
params.append('include_manifest_capabilities', String(req.includeManifestCapabilities));
|
|
273
|
+
}
|
|
274
|
+
const query = params.toString();
|
|
275
|
+
const fullUrl = query !== '' ? `${url}?${query}` : url;
|
|
276
|
+
let resp;
|
|
277
|
+
const call = async (callSignal) => {
|
|
278
|
+
const headers = new Headers();
|
|
279
|
+
if (this.workspaceId !== undefined) {
|
|
280
|
+
headers.set('X-Databricks-Org-Id', this.workspaceId);
|
|
281
|
+
}
|
|
282
|
+
headers.set('User-Agent', this.userAgent);
|
|
283
|
+
const httpReq = buildHttpRequest('GET', fullUrl, headers, callSignal);
|
|
284
|
+
const respBody = await executeHttpCall({
|
|
285
|
+
request: httpReq,
|
|
286
|
+
httpClient: this.httpClient,
|
|
287
|
+
logger: this.logger,
|
|
288
|
+
});
|
|
289
|
+
resp = parseResponse(respBody, unmarshalListTableSummariesRequest_ResponseSchema);
|
|
290
|
+
};
|
|
291
|
+
await executeCall(call, options);
|
|
292
|
+
if (resp === undefined) {
|
|
293
|
+
throw new Error('API call completed without a result.');
|
|
294
|
+
}
|
|
295
|
+
return resp;
|
|
296
|
+
}
|
|
297
|
+
async *listTableSummariesIter(req, options) {
|
|
298
|
+
const pageReq = { ...req };
|
|
299
|
+
for (;;) {
|
|
300
|
+
const resp = await this.listTableSummaries(pageReq, options);
|
|
301
|
+
for (const item of resp.tables ?? []) {
|
|
302
|
+
yield item;
|
|
303
|
+
}
|
|
304
|
+
if (resp.nextPageToken === undefined || resp.nextPageToken === '') {
|
|
305
|
+
return;
|
|
306
|
+
}
|
|
307
|
+
pageReq.pageToken = resp.nextPageToken;
|
|
308
|
+
}
|
|
309
|
+
}
|
|
310
|
+
/**
|
|
311
|
+
* Gets an array of all tables for the current metastore under the parent catalog and schema.
|
|
312
|
+
* The caller must be a metastore admin or an owner of (or have the **SELECT** privilege on) the table.
|
|
313
|
+
* For the latter case, the caller must also be the owner or have the **USE_CATALOG** privilege on the parent catalog and the **USE_SCHEMA** privilege on the parent schema.
|
|
314
|
+
* There is no guarantee of a specific ordering of the elements in the array.
|
|
315
|
+
*
|
|
316
|
+
* NOTE: **view_dependencies** and **table_constraints** are not returned by ListTables queries.
|
|
317
|
+
*
|
|
318
|
+
* NOTE: we recommend using max_results=0 to use the paginated version of this API. Unpaginated calls will be deprecated soon.
|
|
319
|
+
*
|
|
320
|
+
* PAGINATION BEHAVIOR: When using pagination (max_results >= 0), a page may contain zero results while still providing a next_page_token.
|
|
321
|
+
* Clients must continue reading pages until next_page_token is absent, which is the only indication that the end of results has been reached.
|
|
322
|
+
*/
|
|
323
|
+
async listTables(req, options) {
|
|
324
|
+
const url = `${this.host}/api/2.1/unity-catalog/tables`;
|
|
325
|
+
const params = new URLSearchParams();
|
|
326
|
+
if (req.catalogName !== undefined) {
|
|
327
|
+
params.append('catalog_name', req.catalogName);
|
|
328
|
+
}
|
|
329
|
+
if (req.schemaName !== undefined) {
|
|
330
|
+
params.append('schema_name', req.schemaName);
|
|
331
|
+
}
|
|
332
|
+
if (req.maxResults !== undefined) {
|
|
333
|
+
params.append('max_results', String(req.maxResults));
|
|
334
|
+
}
|
|
335
|
+
if (req.pageToken !== undefined) {
|
|
336
|
+
params.append('page_token', req.pageToken);
|
|
337
|
+
}
|
|
338
|
+
if (req.omitColumns !== undefined) {
|
|
339
|
+
params.append('omit_columns', String(req.omitColumns));
|
|
340
|
+
}
|
|
341
|
+
if (req.omitProperties !== undefined) {
|
|
342
|
+
params.append('omit_properties', String(req.omitProperties));
|
|
343
|
+
}
|
|
344
|
+
if (req.omitUsername !== undefined) {
|
|
345
|
+
params.append('omit_username', String(req.omitUsername));
|
|
346
|
+
}
|
|
347
|
+
if (req.includeBrowse !== undefined) {
|
|
348
|
+
params.append('include_browse', String(req.includeBrowse));
|
|
349
|
+
}
|
|
350
|
+
if (req.includeManifestCapabilities !== undefined) {
|
|
351
|
+
params.append('include_manifest_capabilities', String(req.includeManifestCapabilities));
|
|
352
|
+
}
|
|
353
|
+
const query = params.toString();
|
|
354
|
+
const fullUrl = query !== '' ? `${url}?${query}` : url;
|
|
355
|
+
let resp;
|
|
356
|
+
const call = async (callSignal) => {
|
|
357
|
+
const headers = new Headers();
|
|
358
|
+
if (this.workspaceId !== undefined) {
|
|
359
|
+
headers.set('X-Databricks-Org-Id', this.workspaceId);
|
|
360
|
+
}
|
|
361
|
+
headers.set('User-Agent', this.userAgent);
|
|
362
|
+
const httpReq = buildHttpRequest('GET', fullUrl, headers, callSignal);
|
|
363
|
+
const respBody = await executeHttpCall({
|
|
364
|
+
request: httpReq,
|
|
365
|
+
httpClient: this.httpClient,
|
|
366
|
+
logger: this.logger,
|
|
367
|
+
});
|
|
368
|
+
resp = parseResponse(respBody, unmarshalListTablesRequest_ResponseSchema);
|
|
369
|
+
};
|
|
370
|
+
await executeCall(call, options);
|
|
371
|
+
if (resp === undefined) {
|
|
372
|
+
throw new Error('API call completed without a result.');
|
|
373
|
+
}
|
|
374
|
+
return resp;
|
|
375
|
+
}
|
|
376
|
+
async *listTablesIter(req, options) {
|
|
377
|
+
const pageReq = { ...req };
|
|
378
|
+
for (;;) {
|
|
379
|
+
const resp = await this.listTables(pageReq, options);
|
|
380
|
+
for (const item of resp.tables ?? []) {
|
|
381
|
+
yield item;
|
|
382
|
+
}
|
|
383
|
+
if (resp.nextPageToken === undefined || resp.nextPageToken === '') {
|
|
384
|
+
return;
|
|
385
|
+
}
|
|
386
|
+
pageReq.pageToken = resp.nextPageToken;
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
/**
|
|
390
|
+
* Gets if a table exists in the metastore for a specific catalog and schema.
|
|
391
|
+
* The caller must satisfy one of the following requirements:
|
|
392
|
+
* * Be a metastore admin
|
|
393
|
+
* * Be the owner of the parent catalog
|
|
394
|
+
* * Be the owner of the parent schema and have the **USE_CATALOG** privilege on the parent catalog
|
|
395
|
+
* * Have the **USE_CATALOG** privilege on the parent catalog and the **USE_SCHEMA** privilege on the parent schema,
|
|
396
|
+
* and either be the table owner or have the **SELECT** privilege on the table.
|
|
397
|
+
* * Have **BROWSE** privilege on the parent catalog
|
|
398
|
+
* * Have **BROWSE** privilege on the parent schema
|
|
399
|
+
*/
|
|
400
|
+
async tableExists(req, options) {
|
|
401
|
+
const url = `${this.host}/api/2.1/unity-catalog/tables/${req.fullNameArg ?? ''}/exists`;
|
|
402
|
+
let resp;
|
|
403
|
+
const call = async (callSignal) => {
|
|
404
|
+
const headers = new Headers();
|
|
405
|
+
if (this.workspaceId !== undefined) {
|
|
406
|
+
headers.set('X-Databricks-Org-Id', this.workspaceId);
|
|
407
|
+
}
|
|
408
|
+
headers.set('User-Agent', this.userAgent);
|
|
409
|
+
const httpReq = buildHttpRequest('GET', url, headers, callSignal);
|
|
410
|
+
const respBody = await executeHttpCall({
|
|
411
|
+
request: httpReq,
|
|
412
|
+
httpClient: this.httpClient,
|
|
413
|
+
logger: this.logger,
|
|
414
|
+
});
|
|
415
|
+
resp = parseResponse(respBody, unmarshalTableExistsRequest_ResponseSchema);
|
|
416
|
+
};
|
|
417
|
+
await executeCall(call, options);
|
|
418
|
+
if (resp === undefined) {
|
|
419
|
+
throw new Error('API call completed without a result.');
|
|
420
|
+
}
|
|
421
|
+
return resp;
|
|
422
|
+
}
|
|
423
|
+
/**
|
|
424
|
+
* Change the owner of the table.
|
|
425
|
+
* The caller must be the owner of the parent catalog, have the **USE_CATALOG** privilege on the parent catalog and be the owner of the parent schema,
|
|
426
|
+
* or be the owner of the table and have the **USE_CATALOG** privilege on the parent catalog and the **USE_SCHEMA** privilege on the parent schema.
|
|
427
|
+
*/
|
|
428
|
+
async updateTable(req, options) {
|
|
429
|
+
const url = `${this.host}/api/2.1/unity-catalog/tables/${req.fullNameArg ?? ''}`;
|
|
430
|
+
const body = marshalRequest(req, marshalUpdateTableRequestSchema);
|
|
431
|
+
let resp;
|
|
432
|
+
const call = async (callSignal) => {
|
|
433
|
+
const headers = new Headers({ 'Content-Type': 'application/json' });
|
|
434
|
+
if (this.workspaceId !== undefined) {
|
|
435
|
+
headers.set('X-Databricks-Org-Id', this.workspaceId);
|
|
436
|
+
}
|
|
437
|
+
headers.set('User-Agent', this.userAgent);
|
|
438
|
+
const httpReq = buildHttpRequest('PATCH', url, headers, callSignal, body);
|
|
439
|
+
const respBody = await executeHttpCall({
|
|
440
|
+
request: httpReq,
|
|
441
|
+
httpClient: this.httpClient,
|
|
442
|
+
logger: this.logger,
|
|
443
|
+
});
|
|
444
|
+
resp = parseResponse(respBody, unmarshalUpdateTableRequest_ResponseSchema);
|
|
445
|
+
};
|
|
446
|
+
await executeCall(call, options);
|
|
447
|
+
if (resp === undefined) {
|
|
448
|
+
throw new Error('API call completed without a result.');
|
|
449
|
+
}
|
|
450
|
+
return resp;
|
|
451
|
+
}
|
|
452
|
+
}
|
|
453
|
+
//# sourceMappingURL=client.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"client.js","sourceRoot":"","sources":["../../src/v1/client.ts"],"names":[],"mappings":"AAAA,+EAA+E;AAE/E,OAAO,EAAC,OAAO,IAAI,YAAY,EAAC,MAAM,sBAAsB,CAAC;AAE7D,OAAO,EAAC,aAAa,EAAC,MAAM,iCAAiC,CAAC;AAE9D,OAAO,EAAC,UAAU,EAAC,MAAM,6BAA6B,CAAC;AAIvD,OAAO,EAAC,aAAa,EAAC,MAAM,aAAa,CAAC;AAC1C,OAAO,EACL,gBAAgB,EAChB,WAAW,EACX,eAAe,EACf,cAAc,EACd,aAAa,GACd,MAAM,SAAS,CAAC;AACjB,OAAO,OAAO,MAAM,oBAAoB,CAAC,OAAM,IAAI,EAAE,MAAM,EAAC,CAAC;AAqB7D,OAAO,EACL,yCAAyC,EACzC,+BAA+B,EAC/B,+BAA+B,EAC/B,oDAAoD,EACpD,0CAA0C,EAC1C,iDAAiD,EACjD,yCAAyC,EACzC,8BAA8B,EAC9B,0CAA0C,EAC1C,wBAAwB,EACxB,0CAA0C,GAC3C,MAAM,SAAS,CAAC;AAEjB,gFAAgF;AAChF,MAAM,eAAe,GAAG;IACtB,GAAG,EAAE,SAAS,GAAG,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,eAAe,EAAE,EAAE,CAAC;IAC1D,KAAK,EAAE,OAAO,CAAC,OAAO;CACvB,CAAC;AAEF,MAAM,OAAO,YAAY;IACN,IAAI,CAAS;I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,EAAE,CAAC;gBACnC,OAAO,CAAC,GAAG,CAAC,qBAAqB,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC;YACvD,CAAC;YACD,OAAO,CAAC,GAAG,CAAC,YAAY,EAAE,IAAI,CAAC,SAAS,CAAC,CAAC;YAC1C,MAAM,OAAO,GAAG,gBAAgB,CAAC,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,UAAU,EAAE,IAAI,CAAC,CAAC;YAC1E,MAAM,QAAQ,GAAG,MAAM,eAAe,CAAC;gBACrC,OAAO,EAAE,OAAO;gBAChB,UAAU,EAAE,IAAI,CAAC,UAAU;gBAC3B,MAAM,EAAE,IAAI,CAAC,MAAM;aACpB,CAAC,CAAC;YACH,IAAI,GAAG,aAAa,CAClB,QAAQ,EACR,0CAA0C,CAC3C,CAAC;QACJ,CAAC,CAAC;QACF,MAAM,WAAW,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;QACjC,IAAI,IAAI,KAAK,SAAS,EAAE,CAAC;YACvB,MAAM,IAAI,KAAK,CAAC,sCAAsC,CAAC,CAAC;QAC1D,CAAC;QACD,OAAO,IAAI,CAAC;IACd,CAAC;CACF"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { TablesClient } from './client';
|
|
2
|
+
export { ColumnTypeName, DataSourceFormat, SecurableKind, SecurableType, SseEncryptionAlgorithm, TableType, OptionSpec_OauthStage, OptionSpec_OptionType, } from './model';
|
|
3
|
+
export type { ColumnInfo, ColumnMask, ConnectionDependency, CreateTableConstraintRequest, CreateTableRequest, CreateTableRequest_PropertiesEntry, CredentialDependency, DeleteTableConstraintRequest, DeleteTableConstraintRequest_Response, DeleteTableRequest, DeleteTableRequest_Response, DeltaRuntimePropertiesKvPairs, DeltaRuntimePropertiesKvPairs_DeltaRuntimePropertiesEntry, Dependency, DependencyList, EffectivePredictiveOptimizationFlag, EncryptionDetails, ForeignKeyConstraint, FunctionDependency, GetTableRequest, ListTableSummariesRequest, ListTableSummariesRequest_Response, ListTablesRequest, ListTablesRequest_Response, NamedTableConstraint, OptionSpec, PolicyFunctionArgument, PrimaryKeyConstraint, RowFilter, SecurableKindManifest, SseEncryptionDetails, TableConstraint, TableDependency, TableExistsRequest, TableExistsRequest_Response, TableInfo, TableInfo_PropertiesEntry, TableSummary, UpdateTableRequest, UpdateTableRequest_PropertiesEntry, UpdateTableRequest_Response, } from './model';
|
|
4
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/v1/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAC,YAAY,EAAC,MAAM,UAAU,CAAC;AAEtC,OAAO,EACL,cAAc,EACd,gBAAgB,EAChB,aAAa,EACb,aAAa,EACb,sBAAsB,EACtB,SAAS,EACT,qBAAqB,EACrB,qBAAqB,GACtB,MAAM,SAAS,CAAC;AAEjB,YAAY,EACV,UAAU,EACV,UAAU,EACV,oBAAoB,EACpB,4BAA4B,EAC5B,kBAAkB,EAClB,kCAAkC,EAClC,oBAAoB,EACpB,4BAA4B,EAC5B,qCAAqC,EACrC,kBAAkB,EAClB,2BAA2B,EAC3B,6BAA6B,EAC7B,yDAAyD,EACzD,UAAU,EACV,cAAc,EACd,mCAAmC,EACnC,iBAAiB,EACjB,oBAAoB,EACpB,kBAAkB,EAClB,eAAe,EACf,yBAAyB,EACzB,kCAAkC,EAClC,iBAAiB,EACjB,0BAA0B,EAC1B,oBAAoB,EACpB,UAAU,EACV,sBAAsB,EACtB,oBAAoB,EACpB,SAAS,EACT,qBAAqB,EACrB,oBAAoB,EACpB,eAAe,EACf,eAAe,EACf,kBAAkB,EAClB,2BAA2B,EAC3B,SAAS,EACT,yBAAyB,EACzB,YAAY,EACZ,kBAAkB,EAClB,kCAAkC,EAClC,2BAA2B,GAC5B,MAAM,SAAS,CAAC"}
|
package/dist/v1/index.js
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
// Code generated from API definition by Databricks SDK Generator. DO NOT EDIT.
|
|
2
|
+
export { TablesClient } from './client';
|
|
3
|
+
export { ColumnTypeName, DataSourceFormat, SecurableKind, SecurableType, SseEncryptionAlgorithm, TableType, OptionSpec_OauthStage, OptionSpec_OptionType, } from './model';
|
|
4
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/v1/index.ts"],"names":[],"mappings":"AAAA,+EAA+E;AAE/E,OAAO,EAAC,YAAY,EAAC,MAAM,UAAU,CAAC;AAEtC,OAAO,EACL,cAAc,EACd,gBAAgB,EAChB,aAAa,EACb,aAAa,EACb,sBAAsB,EACtB,SAAS,EACT,qBAAqB,EACrB,qBAAqB,GACtB,MAAM,SAAS,CAAC"}
|