@databricks/sdk-core 0.0.0-dev → 0.1.0-dev.2

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.
Files changed (164) hide show
  1. package/LICENSE +203 -0
  2. package/README.md +11 -1
  3. package/dist/api/execute.d.ts +12 -0
  4. package/dist/api/execute.d.ts.map +1 -0
  5. package/dist/api/execute.js +77 -0
  6. package/dist/api/execute.js.map +1 -0
  7. package/dist/api/index.d.ts +12 -0
  8. package/dist/api/index.d.ts.map +1 -0
  9. package/dist/api/index.js +8 -0
  10. package/dist/api/index.js.map +1 -0
  11. package/dist/api/limiter.d.ts +9 -0
  12. package/dist/api/limiter.d.ts.map +1 -0
  13. package/dist/api/limiter.js +2 -0
  14. package/dist/api/limiter.js.map +1 -0
  15. package/dist/api/options.d.ts +22 -0
  16. package/dist/api/options.d.ts.map +1 -0
  17. package/dist/api/options.js +2 -0
  18. package/dist/api/options.js.map +1 -0
  19. package/dist/api/retrier.d.ts +58 -0
  20. package/dist/api/retrier.d.ts.map +1 -0
  21. package/dist/api/retrier.js +70 -0
  22. package/dist/api/retrier.js.map +1 -0
  23. package/dist/apierror/apierror.d.ts +53 -0
  24. package/dist/apierror/apierror.d.ts.map +1 -0
  25. package/dist/apierror/apierror.js +217 -0
  26. package/dist/apierror/apierror.js.map +1 -0
  27. package/dist/apierror/codes/codes.d.ts +140 -0
  28. package/dist/apierror/codes/codes.d.ts.map +1 -0
  29. package/dist/apierror/codes/codes.js +167 -0
  30. package/dist/apierror/codes/codes.js.map +1 -0
  31. package/dist/apierror/codes/index.d.ts +7 -0
  32. package/dist/apierror/codes/index.d.ts.map +1 -0
  33. package/dist/apierror/codes/index.js +7 -0
  34. package/dist/apierror/codes/index.js.map +1 -0
  35. package/dist/apierror/details.d.ts +177 -0
  36. package/dist/apierror/details.d.ts.map +1 -0
  37. package/dist/apierror/details.js +250 -0
  38. package/dist/apierror/details.js.map +1 -0
  39. package/dist/apierror/index.d.ts +8 -0
  40. package/dist/apierror/index.d.ts.map +1 -0
  41. package/dist/apierror/index.js +7 -0
  42. package/dist/apierror/index.js.map +1 -0
  43. package/dist/clientinfo/agent.d.ts +56 -0
  44. package/dist/clientinfo/agent.d.ts.map +1 -0
  45. package/dist/clientinfo/agent.js +114 -0
  46. package/dist/clientinfo/agent.js.map +1 -0
  47. package/dist/clientinfo/base.d.ts +39 -0
  48. package/dist/clientinfo/base.d.ts.map +1 -0
  49. package/dist/clientinfo/base.js +62 -0
  50. package/dist/clientinfo/base.js.map +1 -0
  51. package/dist/clientinfo/clientinfo.d.ts +61 -0
  52. package/dist/clientinfo/clientinfo.d.ts.map +1 -0
  53. package/dist/clientinfo/clientinfo.js +96 -0
  54. package/dist/clientinfo/clientinfo.js.map +1 -0
  55. package/dist/clientinfo/default.browser.d.ts +17 -0
  56. package/dist/clientinfo/default.browser.d.ts.map +1 -0
  57. package/dist/clientinfo/default.browser.js +20 -0
  58. package/dist/clientinfo/default.browser.js.map +1 -0
  59. package/dist/clientinfo/default.d.ts +14 -0
  60. package/dist/clientinfo/default.d.ts.map +1 -0
  61. package/dist/clientinfo/default.js +104 -0
  62. package/dist/clientinfo/default.js.map +1 -0
  63. package/dist/clientinfo/index.browser.d.ts +5 -0
  64. package/dist/clientinfo/index.browser.d.ts.map +1 -0
  65. package/dist/clientinfo/index.browser.js +4 -0
  66. package/dist/clientinfo/index.browser.js.map +1 -0
  67. package/dist/clientinfo/index.d.ts +5 -0
  68. package/dist/clientinfo/index.d.ts.map +1 -0
  69. package/dist/clientinfo/index.js +4 -0
  70. package/dist/clientinfo/index.js.map +1 -0
  71. package/dist/http/http.d.ts +40 -0
  72. package/dist/http/http.d.ts.map +1 -0
  73. package/dist/http/http.js +37 -0
  74. package/dist/http/http.js.map +1 -0
  75. package/dist/http/index.d.ts +8 -0
  76. package/dist/http/index.d.ts.map +1 -0
  77. package/dist/http/index.js +7 -0
  78. package/dist/http/index.js.map +1 -0
  79. package/dist/index.d.ts +6 -0
  80. package/dist/index.d.ts.map +1 -0
  81. package/dist/index.js +7 -0
  82. package/dist/index.js.map +1 -0
  83. package/dist/logger/index.d.ts +8 -0
  84. package/dist/logger/index.d.ts.map +1 -0
  85. package/dist/logger/index.js +7 -0
  86. package/dist/logger/index.js.map +1 -0
  87. package/dist/logger/logger.d.ts +49 -0
  88. package/dist/logger/logger.d.ts.map +1 -0
  89. package/dist/logger/logger.js +65 -0
  90. package/dist/logger/logger.js.map +1 -0
  91. package/dist/profiles/errors.d.ts +17 -0
  92. package/dist/profiles/errors.d.ts.map +1 -0
  93. package/dist/profiles/errors.js +19 -0
  94. package/dist/profiles/errors.js.map +1 -0
  95. package/dist/profiles/index.browser.d.ts +10 -0
  96. package/dist/profiles/index.browser.d.ts.map +1 -0
  97. package/dist/profiles/index.browser.js +8 -0
  98. package/dist/profiles/index.browser.js.map +1 -0
  99. package/dist/profiles/index.d.ts +15 -0
  100. package/dist/profiles/index.d.ts.map +1 -0
  101. package/dist/profiles/index.js +13 -0
  102. package/dist/profiles/index.js.map +1 -0
  103. package/dist/profiles/ini.d.ts +36 -0
  104. package/dist/profiles/ini.d.ts.map +1 -0
  105. package/dist/profiles/ini.js +113 -0
  106. package/dist/profiles/ini.js.map +1 -0
  107. package/dist/profiles/profile.d.ts +131 -0
  108. package/dist/profiles/profile.d.ts.map +1 -0
  109. package/dist/profiles/profile.js +307 -0
  110. package/dist/profiles/profile.js.map +1 -0
  111. package/dist/profiles/resolve.d.ts +29 -0
  112. package/dist/profiles/resolve.d.ts.map +1 -0
  113. package/dist/profiles/resolve.js +206 -0
  114. package/dist/profiles/resolve.js.map +1 -0
  115. package/dist/profiles/secret.d.ts +25 -0
  116. package/dist/profiles/secret.d.ts.map +1 -0
  117. package/dist/profiles/secret.js +38 -0
  118. package/dist/profiles/secret.js.map +1 -0
  119. package/dist/wkt/fieldmask.d.ts +32 -0
  120. package/dist/wkt/fieldmask.d.ts.map +1 -0
  121. package/dist/wkt/fieldmask.js +68 -0
  122. package/dist/wkt/fieldmask.js.map +1 -0
  123. package/dist/wkt/index.d.ts +4 -0
  124. package/dist/wkt/index.d.ts.map +1 -0
  125. package/dist/wkt/index.js +2 -0
  126. package/dist/wkt/index.js.map +1 -0
  127. package/dist/wkt/value.d.ts +13 -0
  128. package/dist/wkt/value.d.ts.map +1 -0
  129. package/dist/wkt/value.js +2 -0
  130. package/dist/wkt/value.js.map +1 -0
  131. package/package.json +82 -4
  132. package/src/api/execute.ts +102 -0
  133. package/src/api/index.ts +12 -0
  134. package/src/api/limiter.ts +8 -0
  135. package/src/api/options.ts +22 -0
  136. package/src/api/retrier.ts +108 -0
  137. package/src/apierror/apierror.ts +253 -0
  138. package/src/apierror/codes/codes.ts +189 -0
  139. package/src/apierror/codes/index.ts +7 -0
  140. package/src/apierror/details.ts +459 -0
  141. package/src/apierror/index.ts +24 -0
  142. package/src/clientinfo/agent.ts +125 -0
  143. package/src/clientinfo/base.ts +73 -0
  144. package/src/clientinfo/clientinfo.ts +129 -0
  145. package/src/clientinfo/default.browser.ts +24 -0
  146. package/src/clientinfo/default.ts +128 -0
  147. package/src/clientinfo/index.browser.ts +4 -0
  148. package/src/clientinfo/index.ts +4 -0
  149. package/src/http/http.ts +75 -0
  150. package/src/http/index.ts +8 -0
  151. package/src/index.ts +5 -0
  152. package/src/logger/index.ts +8 -0
  153. package/src/logger/logger.ts +99 -0
  154. package/src/profiles/errors.ts +28 -0
  155. package/src/profiles/index.browser.ts +10 -0
  156. package/src/profiles/index.ts +15 -0
  157. package/src/profiles/ini.ts +126 -0
  158. package/src/profiles/profile.ts +467 -0
  159. package/src/profiles/resolve.ts +251 -0
  160. package/src/profiles/secret.ts +40 -0
  161. package/src/wkt/fieldmask.ts +89 -0
  162. package/src/wkt/index.ts +3 -0
  163. package/src/wkt/value.ts +19 -0
  164. package/index.js +0 -1
@@ -0,0 +1,217 @@
1
+ import { z } from 'zod';
2
+ import { Code, codeFromString } from './codes';
3
+ import { parseErrorDetails } from './details';
4
+ // Reusable schema fragment for nullish string fields.
5
+ const nullishString = z
6
+ .string()
7
+ .nullish()
8
+ .transform(v => v ?? '');
9
+ // Zod schema for parsing the JSON error response body. The schema is lenient
10
+ // to handle the various Databricks API error formats (standard, legacy, SCIM).
11
+ const errorResponseSchema = z.object({
12
+ message: nullishString,
13
+ details: z
14
+ .array(z.unknown())
15
+ .nullish()
16
+ .transform(v => v ?? []),
17
+ // Some Databricks APIs incorrectly return the HTTP status code as an
18
+ // integer rather than the actual error code as a string.
19
+ error_code: z.unknown().optional(),
20
+ // Legacy Databricks APIs (e.g. version 1.2 and earlier) used "error"
21
+ // instead of "message".
22
+ error: nullishString,
23
+ // SCIM error fields (RFC7644 section 3.7.3).
24
+ // The "status" field is intentionally omitted; it duplicates HTTP status.
25
+ detail: nullishString,
26
+ scimType: nullishString,
27
+ });
28
+ /** ApiError is a transport-agnostic error representing a Databricks API error. */
29
+ export class ApiError extends Error {
30
+ /** The canonical error code of the error. */
31
+ code;
32
+ /**
33
+ * The structured error details of the error. This is left empty if the
34
+ * error response is not a standard Databricks API error.
35
+ */
36
+ details;
37
+ // The raw HTTP error details, undefined if this is not an HTTP error.
38
+ httpErr;
39
+ /**
40
+ * Do not use this constructor directly. Use {@link ApiError.fromHttpError}
41
+ * instead. This constructor is only meant for internal and testing use.
42
+ * TODO: Make this constructor private.
43
+ *
44
+ * @private
45
+ */
46
+ constructor(options) {
47
+ super(options.message, { cause: options.cause });
48
+ this.name = 'ApiError';
49
+ this.code = options.code;
50
+ this.details = options.details;
51
+ if (options.httpStatusCode !== undefined) {
52
+ this.httpErr = {
53
+ statusCode: options.httpStatusCode,
54
+ header: options.httpHeader,
55
+ body: options.httpBody,
56
+ };
57
+ }
58
+ }
59
+ /**
60
+ * Returns the ApiError's HTTP status code. If the ApiError is not an HTTP
61
+ * error, returns -1.
62
+ */
63
+ get httpStatusCode() {
64
+ if (this.httpErr === undefined) {
65
+ return -1;
66
+ }
67
+ return this.httpErr.statusCode;
68
+ }
69
+ /**
70
+ * Returns the ApiError's HTTP headers. If the ApiError is not an HTTP
71
+ * error, returns undefined.
72
+ */
73
+ get httpHeader() {
74
+ if (this.httpErr === undefined) {
75
+ return undefined;
76
+ }
77
+ return this.httpErr.header;
78
+ }
79
+ /**
80
+ * Returns the ApiError's HTTP body. If the ApiError is not an HTTP error,
81
+ * returns undefined.
82
+ */
83
+ get httpBody() {
84
+ if (this.httpErr === undefined) {
85
+ return undefined;
86
+ }
87
+ return this.httpErr.body;
88
+ }
89
+ /**
90
+ * Parses an HTTP error response into an ApiError. Returns undefined if the
91
+ * status code is 2xx.
92
+ */
93
+ static fromHttpError(statusCode, header, body) {
94
+ if (statusCode >= 200 && statusCode < 300) {
95
+ return undefined;
96
+ }
97
+ const emptyDetails = { unknownDetails: [] };
98
+ if (body === undefined || body.length === 0) {
99
+ return new ApiError({
100
+ code: toCode(statusCode),
101
+ message: '',
102
+ details: emptyDetails,
103
+ httpStatusCode: statusCode,
104
+ httpHeader: header,
105
+ httpBody: body,
106
+ });
107
+ }
108
+ // Decode the body to a string for JSON parsing.
109
+ let parsed;
110
+ try {
111
+ parsed = JSON.parse(new TextDecoder().decode(body));
112
+ }
113
+ catch (e) {
114
+ // The JSON error is simply swallowed, this typically happens when the
115
+ // error does not come directly from a Databricks API. A typical example
116
+ // is when the error is returned by a proxy.
117
+ return new ApiError({
118
+ code: toCode(statusCode),
119
+ message: '',
120
+ details: emptyDetails,
121
+ httpStatusCode: statusCode,
122
+ httpHeader: header,
123
+ httpBody: body,
124
+ cause: e instanceof Error ? e : undefined,
125
+ });
126
+ }
127
+ const result = errorResponseSchema.safeParse(parsed);
128
+ if (!result.success) {
129
+ return new ApiError({
130
+ code: toCode(statusCode),
131
+ message: '',
132
+ details: emptyDetails,
133
+ httpStatusCode: statusCode,
134
+ httpHeader: header,
135
+ httpBody: body,
136
+ cause: result.error,
137
+ });
138
+ }
139
+ const errResp = result.data;
140
+ // Error codes may be missing or be an integer (legacy APIs). In such
141
+ // cases, defer to the HTTP status code to infer the closest canonical
142
+ // error code.
143
+ let errorCode;
144
+ if (typeof errResp.error_code === 'string') {
145
+ errorCode = codeFromString(errResp.error_code);
146
+ }
147
+ else {
148
+ errorCode = toCode(statusCode);
149
+ }
150
+ // Determine the error message from available fields.
151
+ let errorMessage = '';
152
+ if (errResp.message !== '') {
153
+ errorMessage = errResp.message;
154
+ }
155
+ else if (errResp.error !== '') {
156
+ errorMessage = errResp.error;
157
+ }
158
+ else if (errResp.detail !== '') {
159
+ errorMessage = errResp.detail;
160
+ }
161
+ else if (errResp.scimType !== '') {
162
+ errorMessage = errResp.scimType;
163
+ }
164
+ return new ApiError({
165
+ code: errorCode,
166
+ message: errorMessage,
167
+ details: parseErrorDetails(errResp.details),
168
+ httpStatusCode: statusCode,
169
+ httpHeader: header,
170
+ httpBody: body,
171
+ });
172
+ }
173
+ }
174
+ // Maps an HTTP status code to the closest canonical error code.
175
+ export function toCode(httpCode) {
176
+ // Canonical mappings.
177
+ switch (httpCode) {
178
+ case 200:
179
+ return Code.OK;
180
+ case 400:
181
+ return Code.INVALID_ARGUMENT;
182
+ case 401:
183
+ return Code.UNAUTHENTICATED;
184
+ case 403:
185
+ return Code.PERMISSION_DENIED;
186
+ case 404:
187
+ return Code.NOT_FOUND;
188
+ case 409:
189
+ return Code.ABORTED;
190
+ case 416:
191
+ return Code.OUT_OF_RANGE;
192
+ case 429:
193
+ return Code.RESOURCE_EXHAUSTED;
194
+ case 501:
195
+ return Code.UNIMPLEMENTED;
196
+ case 503:
197
+ return Code.UNAVAILABLE;
198
+ case 504:
199
+ return Code.DEADLINE_EXCEEDED;
200
+ default:
201
+ break;
202
+ }
203
+ // Fallback for status codes without a direct canonical mapping.
204
+ if (httpCode >= 200 && httpCode < 300) {
205
+ return Code.OK;
206
+ }
207
+ if (httpCode >= 400 && httpCode < 500) {
208
+ // Most non-canonical 4xx status codes are state related and map
209
+ // to the definition of FailedPrecondition.
210
+ return Code.FAILED_PRECONDITION;
211
+ }
212
+ if (httpCode >= 500 && httpCode < 600) {
213
+ return Code.INTERNAL;
214
+ }
215
+ return Code.UNKNOWN;
216
+ }
217
+ //# sourceMappingURL=apierror.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"apierror.js","sourceRoot":"","sources":["../../src/apierror/apierror.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,OAAO,EAAC,IAAI,EAAE,cAAc,EAAC,MAAM,SAAS,CAAC;AAE7C,OAAO,EAAC,iBAAiB,EAAC,MAAM,WAAW,CAAC;AAE5C,sDAAsD;AACtD,MAAM,aAAa,GAAG,CAAC;KACpB,MAAM,EAAE;KACR,OAAO,EAAE;KACT,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC;AAE3B,6EAA6E;AAC7E,+EAA+E;AAC/E,MAAM,mBAAmB,GAAG,CAAC,CAAC,MAAM,CAAC;IACnC,OAAO,EAAE,aAAa;IACtB,OAAO,EAAE,CAAC;SACP,KAAK,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;SAClB,OAAO,EAAE;SACT,SAAS,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC;IAC1B,qEAAqE;IACrE,yDAAyD;IACzD,UAAU,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IAClC,qEAAqE;IACrE,wBAAwB;IACxB,KAAK,EAAE,aAAa;IACpB,6CAA6C;IAC7C,0EAA0E;IAC1E,MAAM,EAAE,aAAa;IACrB,QAAQ,EAAE,aAAa;CACxB,CAAC,CAAC;AAaH,kFAAkF;AAClF,MAAM,OAAO,QAAS,SAAQ,KAAK;IACjC,6CAA6C;IACpC,IAAI,CAAO;IAEpB;;;OAGG;IACM,OAAO,CAAe;IAE/B,sEAAsE;IACrD,OAAO,CAItB;IAEF;;;;;;OAMG;IACH,YAAY,OAAwB;QAClC,KAAK,CAAC,OAAO,CAAC,OAAO,EA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AAG;YACN,OAAO,IAAI,CAAC,gBAAgB,CAAC;QAC/B,KAAK,GAAG;YACN,OAAO,IAAI,CAAC,eAAe,CAAC;QAC9B,KAAK,GAAG;YACN,OAAO,IAAI,CAAC,iBAAiB,CAAC;QAChC,KAAK,GAAG;YACN,OAAO,IAAI,CAAC,SAAS,CAAC;QACxB,KAAK,GAAG;YACN,OAAO,IAAI,CAAC,OAAO,CAAC;QACtB,KAAK,GAAG;YACN,OAAO,IAAI,CAAC,YAAY,CAAC;QAC3B,KAAK,GAAG;YACN,OAAO,IAAI,CAAC,kBAAkB,CAAC;QACjC,KAAK,GAAG;YACN,OAAO,IAAI,CAAC,aAAa,CAAC;QAC5B,KAAK,GAAG;YACN,OAAO,IAAI,CAAC,WAAW,CAAC;QAC1B,KAAK,GAAG;YACN,OAAO,IAAI,CAAC,iBAAiB,CAAC;QAChC;YACE,MAAM;IACV,CAAC;IAED,gEAAgE;IAChE,IAAI,QAAQ,IAAI,GAAG,IAAI,QAAQ,GAAG,GAAG,EAAE,CAAC;QACtC,OAAO,IAAI,CAAC,EAAE,CAAC;IACjB,CAAC;IACD,IAAI,QAAQ,IAAI,GAAG,IAAI,QAAQ,GAAG,GAAG,EAAE,CAAC;QACtC,gEAAgE;QAChE,2CAA2C;QAC3C,OAAO,IAAI,CAAC,mBAAmB,CAAC;IAClC,CAAC;IACD,IAAI,QAAQ,IAAI,GAAG,IAAI,QAAQ,GAAG,GAAG,EAAE,CAAC;QACtC,OAAO,IAAI,CAAC,QAAQ,CAAC;IACvB,CAAC;IAED,OAAO,IAAI,CAAC,OAAO,CAAC;AACtB,CAAC"}
@@ -0,0 +1,140 @@
1
+ /**
2
+ * Defines error codes for API errors and their retry semantics.
3
+ *
4
+ * @packageDocumentation
5
+ */
6
+ /**
7
+ * Code is a numeric code for an error.
8
+ *
9
+ * The numeric values are stable and can be relied upon across SDK versions.
10
+ */
11
+ declare enum Code {
12
+ /**
13
+ * Unknown indicates an error that cannot be classified.
14
+ *
15
+ * This code might be used for malformed error responses or error responses
16
+ * using an error code that cannot be mapped to a code in this package.
17
+ */
18
+ UNKNOWN = 0,
19
+ /** OK indicates the operation completed successfully. */
20
+ OK = 1,
21
+ /** Canceled indicates the operation was canceled (typically by the caller). */
22
+ CANCELED = 2,
23
+ /**
24
+ * InvalidArgument indicates the client specified an invalid argument.
25
+ *
26
+ * By contrast with FailedPrecondition, InvalidArgument indicates arguments
27
+ * that are problematic regardless of the state of the system. For example,
28
+ * a malformed request parameter.
29
+ */
30
+ INVALID_ARGUMENT = 3,
31
+ /**
32
+ * DeadlineExceeded means the operation expired before completion.
33
+ *
34
+ * For operations that modify the state of the system, this error may be
35
+ * returned even if the operation has completed successfully. For
36
+ * example, a successful response from a server could have been delayed
37
+ * long enough for the deadline to expire.
38
+ */
39
+ DEADLINE_EXCEEDED = 4,
40
+ /**
41
+ * NotFound means a requested entity (e.g. a resource or a file) was
42
+ * not found.
43
+ */
44
+ NOT_FOUND = 5,
45
+ /**
46
+ * AlreadyExists means an attempt to create an entity failed because one
47
+ * already exists.
48
+ */
49
+ ALREADY_EXISTS = 6,
50
+ /**
51
+ * PermissionDenied indicates the caller does not have permission to
52
+ * execute the specified operation.
53
+ *
54
+ * This is different from an error returned when the user has exhausted
55
+ * some resource (e.g. too many requests) which is a ResourceExhausted
56
+ * error.
57
+ */
58
+ PERMISSION_DENIED = 7,
59
+ /**
60
+ * ResourceExhausted indicates some resource has been exhausted, perhaps
61
+ * a per-user quota, or perhaps the entire file system is out of space.
62
+ */
63
+ RESOURCE_EXHAUSTED = 8,
64
+ /**
65
+ * FailedPrecondition indicates the operation was rejected because the
66
+ * system is not in a state required for the operation's execution.
67
+ * For example, directory to be deleted may be non-empty, an rmdir
68
+ * operation is applied to a non-directory, etc.
69
+ */
70
+ FAILED_PRECONDITION = 9,
71
+ /**
72
+ * Aborted indicates the operation was aborted, typically due to a
73
+ * concurrency issue like sequencer check failures, transaction aborts,
74
+ * etc.
75
+ */
76
+ ABORTED = 10,
77
+ /**
78
+ * OutOfRange means the operation was attempted past the valid range.
79
+ * E.g., seeking or reading past end of file.
80
+ *
81
+ * Unlike InvalidArgument, this error indicates a problem that may
82
+ * be fixed if the system state changes. For example, a 32-bit file
83
+ * system will generate InvalidArgument if asked to read at an
84
+ * offset that is not in the range [0,2^32-1], but it will generate
85
+ * OutOfRange if asked to read from an offset past the current
86
+ * file size.
87
+ *
88
+ * There is a fair bit of overlap between FailedPrecondition and
89
+ * OutOfRange. We recommend using OutOfRange (the more specific
90
+ * error) when it applies so that callers who are iterating through
91
+ * a space can easily look for an OutOfRange error to detect when
92
+ * they are done.
93
+ */
94
+ OUT_OF_RANGE = 11,
95
+ /**
96
+ * Unimplemented indicates the operation is not implemented or not
97
+ * supported/enabled in this service.
98
+ */
99
+ UNIMPLEMENTED = 12,
100
+ /**
101
+ * Internal indicates an internal error. This means some invariants
102
+ * expected by the underlying system have been broken. If you see
103
+ * this error, something is very broken.
104
+ */
105
+ INTERNAL = 13,
106
+ /**
107
+ * Unavailable indicates the service is currently unavailable.
108
+ *
109
+ * This is most likely a transient condition and may be corrected by
110
+ * retrying. Though, this might not always be safe to retry if the
111
+ * operation is non-idempotent.
112
+ *
113
+ * The Databricks SDK will generally automatically retry the request
114
+ * with a backoff when encountering this error.
115
+ */
116
+ UNAVAILABLE = 14,
117
+ /** DataLoss indicates unrecoverable data loss or corruption. */
118
+ DATA_LOSS = 15,
119
+ /**
120
+ * Unauthenticated indicates the request does not have valid
121
+ * authentication credentials for the operation.
122
+ */
123
+ UNAUTHENTICATED = 16
124
+ }
125
+ /**
126
+ * Returns the canonical string representation of an error code.
127
+ *
128
+ * If the code is not recognized, "UNKNOWN" is returned. Note that
129
+ * Code.CANCELED maps to "CANCELLED" (British spelling) to match the gRPC
130
+ * convention.
131
+ */
132
+ declare function codeToString(code: Code): string;
133
+ /**
134
+ * Converts a string representation of an error code to its corresponding
135
+ * Code value. If the string does not match any known code, Code.UNKNOWN is
136
+ * returned.
137
+ */
138
+ declare function codeFromString(s: string): Code;
139
+ export { Code, codeToString, codeFromString };
140
+ //# sourceMappingURL=codes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"codes.d.ts","sourceRoot":"","sources":["../../../src/apierror/codes/codes.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;GAIG;AACH,aAAK,IAAI;IACP;;;;;OAKG;IACH,OAAO,IAAI;IAEX,yDAAyD;IACzD,EAAE,IAAI;IAEN,+EAA+E;IAC/E,QAAQ,IAAI;IAEZ;;;;;;OAMG;IACH,gBAAgB,IAAI;IAEpB;;;;;;;OAOG;IACH,iBAAiB,IAAI;IAErB;;;OAGG;IACH,SAAS,IAAI;IAEb;;;OAGG;IACH,cAAc,IAAI;IAElB;;;;;;;OAOG;IACH,iBAAiB,IAAI;IAErB;;;OAGG;IACH,kBAAkB,IAAI;IAEtB;;;;;OAKG;IACH,mBAAmB,IAAI;IAEvB;;;;OAIG;IACH,OAAO,KAAK;IAEZ;;;;;;;;;;;;;;;;OAgBG;IACH,YAAY,KAAK;IAEjB;;;OAGG;IACH,aAAa,KAAK;IAElB;;;;OAIG;IACH,QAAQ,KAAK;IAEb;;;;;;;;;OASG;IACH,WAAW,KAAK;IAEhB,gEAAgE;IAChE,SAAS,KAAK;IAEd;;;OAGG;IACH,eAAe,KAAK;CACrB;AA4BD;;;;;;GAMG;AACH,iBAAS,YAAY,CAAC,IAAI,EAAE,IAAI,GAAG,MAAM,CAExC;AAED;;;;GAIG;AACH,iBAAS,cAAc,CAAC,CAAC,EAAE,MAAM,GAAG,IAAI,CAEvC;AAED,OAAO,EAAC,IAAI,EAAE,YAAY,EAAE,cAAc,EAAC,CAAC"}
@@ -0,0 +1,167 @@
1
+ /**
2
+ * Defines error codes for API errors and their retry semantics.
3
+ *
4
+ * @packageDocumentation
5
+ */
6
+ /**
7
+ * Code is a numeric code for an error.
8
+ *
9
+ * The numeric values are stable and can be relied upon across SDK versions.
10
+ */
11
+ var Code;
12
+ (function (Code) {
13
+ /**
14
+ * Unknown indicates an error that cannot be classified.
15
+ *
16
+ * This code might be used for malformed error responses or error responses
17
+ * using an error code that cannot be mapped to a code in this package.
18
+ */
19
+ Code[Code["UNKNOWN"] = 0] = "UNKNOWN";
20
+ /** OK indicates the operation completed successfully. */
21
+ Code[Code["OK"] = 1] = "OK";
22
+ /** Canceled indicates the operation was canceled (typically by the caller). */
23
+ Code[Code["CANCELED"] = 2] = "CANCELED";
24
+ /**
25
+ * InvalidArgument indicates the client specified an invalid argument.
26
+ *
27
+ * By contrast with FailedPrecondition, InvalidArgument indicates arguments
28
+ * that are problematic regardless of the state of the system. For example,
29
+ * a malformed request parameter.
30
+ */
31
+ Code[Code["INVALID_ARGUMENT"] = 3] = "INVALID_ARGUMENT";
32
+ /**
33
+ * DeadlineExceeded means the operation expired before completion.
34
+ *
35
+ * For operations that modify the state of the system, this error may be
36
+ * returned even if the operation has completed successfully. For
37
+ * example, a successful response from a server could have been delayed
38
+ * long enough for the deadline to expire.
39
+ */
40
+ Code[Code["DEADLINE_EXCEEDED"] = 4] = "DEADLINE_EXCEEDED";
41
+ /**
42
+ * NotFound means a requested entity (e.g. a resource or a file) was
43
+ * not found.
44
+ */
45
+ Code[Code["NOT_FOUND"] = 5] = "NOT_FOUND";
46
+ /**
47
+ * AlreadyExists means an attempt to create an entity failed because one
48
+ * already exists.
49
+ */
50
+ Code[Code["ALREADY_EXISTS"] = 6] = "ALREADY_EXISTS";
51
+ /**
52
+ * PermissionDenied indicates the caller does not have permission to
53
+ * execute the specified operation.
54
+ *
55
+ * This is different from an error returned when the user has exhausted
56
+ * some resource (e.g. too many requests) which is a ResourceExhausted
57
+ * error.
58
+ */
59
+ Code[Code["PERMISSION_DENIED"] = 7] = "PERMISSION_DENIED";
60
+ /**
61
+ * ResourceExhausted indicates some resource has been exhausted, perhaps
62
+ * a per-user quota, or perhaps the entire file system is out of space.
63
+ */
64
+ Code[Code["RESOURCE_EXHAUSTED"] = 8] = "RESOURCE_EXHAUSTED";
65
+ /**
66
+ * FailedPrecondition indicates the operation was rejected because the
67
+ * system is not in a state required for the operation's execution.
68
+ * For example, directory to be deleted may be non-empty, an rmdir
69
+ * operation is applied to a non-directory, etc.
70
+ */
71
+ Code[Code["FAILED_PRECONDITION"] = 9] = "FAILED_PRECONDITION";
72
+ /**
73
+ * Aborted indicates the operation was aborted, typically due to a
74
+ * concurrency issue like sequencer check failures, transaction aborts,
75
+ * etc.
76
+ */
77
+ Code[Code["ABORTED"] = 10] = "ABORTED";
78
+ /**
79
+ * OutOfRange means the operation was attempted past the valid range.
80
+ * E.g., seeking or reading past end of file.
81
+ *
82
+ * Unlike InvalidArgument, this error indicates a problem that may
83
+ * be fixed if the system state changes. For example, a 32-bit file
84
+ * system will generate InvalidArgument if asked to read at an
85
+ * offset that is not in the range [0,2^32-1], but it will generate
86
+ * OutOfRange if asked to read from an offset past the current
87
+ * file size.
88
+ *
89
+ * There is a fair bit of overlap between FailedPrecondition and
90
+ * OutOfRange. We recommend using OutOfRange (the more specific
91
+ * error) when it applies so that callers who are iterating through
92
+ * a space can easily look for an OutOfRange error to detect when
93
+ * they are done.
94
+ */
95
+ Code[Code["OUT_OF_RANGE"] = 11] = "OUT_OF_RANGE";
96
+ /**
97
+ * Unimplemented indicates the operation is not implemented or not
98
+ * supported/enabled in this service.
99
+ */
100
+ Code[Code["UNIMPLEMENTED"] = 12] = "UNIMPLEMENTED";
101
+ /**
102
+ * Internal indicates an internal error. This means some invariants
103
+ * expected by the underlying system have been broken. If you see
104
+ * this error, something is very broken.
105
+ */
106
+ Code[Code["INTERNAL"] = 13] = "INTERNAL";
107
+ /**
108
+ * Unavailable indicates the service is currently unavailable.
109
+ *
110
+ * This is most likely a transient condition and may be corrected by
111
+ * retrying. Though, this might not always be safe to retry if the
112
+ * operation is non-idempotent.
113
+ *
114
+ * The Databricks SDK will generally automatically retry the request
115
+ * with a backoff when encountering this error.
116
+ */
117
+ Code[Code["UNAVAILABLE"] = 14] = "UNAVAILABLE";
118
+ /** DataLoss indicates unrecoverable data loss or corruption. */
119
+ Code[Code["DATA_LOSS"] = 15] = "DATA_LOSS";
120
+ /**
121
+ * Unauthenticated indicates the request does not have valid
122
+ * authentication credentials for the operation.
123
+ */
124
+ Code[Code["UNAUTHENTICATED"] = 16] = "UNAUTHENTICATED";
125
+ })(Code || (Code = {}));
126
+ // Maps Code values to their canonical string representation.
127
+ const CODE_TO_STRING = new Map([
128
+ [Code.UNKNOWN, 'UNKNOWN'],
129
+ [Code.OK, 'OK'],
130
+ [Code.CANCELED, 'CANCELLED'],
131
+ [Code.INVALID_ARGUMENT, 'INVALID_ARGUMENT'],
132
+ [Code.DEADLINE_EXCEEDED, 'DEADLINE_EXCEEDED'],
133
+ [Code.NOT_FOUND, 'NOT_FOUND'],
134
+ [Code.ALREADY_EXISTS, 'ALREADY_EXISTS'],
135
+ [Code.PERMISSION_DENIED, 'PERMISSION_DENIED'],
136
+ [Code.RESOURCE_EXHAUSTED, 'RESOURCE_EXHAUSTED'],
137
+ [Code.FAILED_PRECONDITION, 'FAILED_PRECONDITION'],
138
+ [Code.ABORTED, 'ABORTED'],
139
+ [Code.OUT_OF_RANGE, 'OUT_OF_RANGE'],
140
+ [Code.UNIMPLEMENTED, 'UNIMPLEMENTED'],
141
+ [Code.INTERNAL, 'INTERNAL'],
142
+ [Code.UNAVAILABLE, 'UNAVAILABLE'],
143
+ [Code.DATA_LOSS, 'DATA_LOSS'],
144
+ [Code.UNAUTHENTICATED, 'UNAUTHENTICATED'],
145
+ ]);
146
+ // Maps canonical strings back to Code values.
147
+ const STRING_TO_CODE = new Map([...CODE_TO_STRING.entries()].map(([code, str]) => [str, code]));
148
+ /**
149
+ * Returns the canonical string representation of an error code.
150
+ *
151
+ * If the code is not recognized, "UNKNOWN" is returned. Note that
152
+ * Code.CANCELED maps to "CANCELLED" (British spelling) to match the gRPC
153
+ * convention.
154
+ */
155
+ function codeToString(code) {
156
+ return CODE_TO_STRING.get(code) ?? 'UNKNOWN';
157
+ }
158
+ /**
159
+ * Converts a string representation of an error code to its corresponding
160
+ * Code value. If the string does not match any known code, Code.UNKNOWN is
161
+ * returned.
162
+ */
163
+ function codeFromString(s) {
164
+ return STRING_TO_CODE.get(s) ?? Code.UNKNOWN;
165
+ }
166
+ export { Code, codeToString, codeFromString };
167
+ //# sourceMappingURL=codes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"codes.js","sourceRoot":"","sources":["../../../src/apierror/codes/codes.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH;;;;GAIG;AACH,IAAK,IAiIJ;AAjID,WAAK,IAAI;IACP;;;;;OAKG;IACH,qCAAW,CAAA;IAEX,yDAAyD;IACzD,2BAAM,CAAA;IAEN,+EAA+E;IAC/E,uCAAY,CAAA;IAEZ;;;;;;OAMG;IACH,uDAAoB,CAAA;IAEpB;;;;;;;OAOG;IACH,yDAAqB,CAAA;IAErB;;;OAGG;IACH,yCAAa,CAAA;IAEb;;;OAGG;IACH,mDAAkB,CAAA;IAElB;;;;;;;OAOG;IACH,yDAAqB,CAAA;IAErB;;;OAGG;IACH,2DAAsB,CAAA;IAEtB;;;;;OAKG;IACH,6DAAuB,CAAA;IAEvB;;;;OAIG;IACH,sCAAY,CAAA;IAEZ;;;;;;;;;;;;;;;;OAgBG;IACH,gDAAiB,CAAA;IAEjB;;;OAGG;IACH,kDAAkB,CAAA;IAElB;;;;OAIG;IACH,wCAAa,CAAA;IAEb;;;;;;;;;OASG;IACH,8CAAgB,CAAA;IAEhB,gEAAgE;IAChE,0CAAc,CAAA;IAEd;;;OAGG;IACH,sDAAoB,CAAA;AACtB,CAAC,EAjII,IAAI,KAAJ,IAAI,QAiIR;AAED,6DAA6D;AAC7D,MAAM,cAAc,GAA8B,IAAI,GAAG,CAAC;IACxD,CAAC,IAAI,CAAC,OAAO,EAAE,SAAS,CAAC;IACzB,CAAC,IAAI,CAAC,EAAE,EAAE,IAAI,CAAC;IACf,CAAC,IAAI,CAAC,QAAQ,EAAE,WAAW,C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,EAAC,IAAI,EAAE,YAAY,EAAE,cAAc,EAAC,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Canonical error codes for Databricks API errors.
3
+ *
4
+ * @packageDocumentation
5
+ */
6
+ export { Code, codeToString, codeFromString } from './codes';
7
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/apierror/codes/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,IAAI,EAAE,YAAY,EAAE,cAAc,EAAC,MAAM,SAAS,CAAC"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Canonical error codes for Databricks API errors.
3
+ *
4
+ * @packageDocumentation
5
+ */
6
+ export { Code, codeToString, codeFromString } from './codes';
7
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/apierror/codes/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAEH,OAAO,EAAC,IAAI,EAAE,YAAY,EAAE,cAAc,EAAC,MAAM,SAAS,CAAC"}