@dbx-tools/databricks 0.6.180 → 0.6.183
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/README.md +4 -22
- package/index.ts +1 -2
- package/lib/index.d.ts +15 -0
- package/lib/index.js +15 -1033
- package/lib/src/cloud.d.ts +80 -0
- package/lib/src/cloud.js +240 -0
- package/lib/src/databricks-fs.d.ts +93 -0
- package/lib/src/databricks-fs.js +327 -0
- package/lib/src/databricks-path.d.ts +67 -0
- package/lib/src/databricks-path.js +113 -0
- package/lib/src/net.d.ts +29 -0
- package/lib/src/net.js +68 -0
- package/lib/src/workspace.d.ts +43 -0
- package/lib/src/workspace.js +110 -0
- package/lib/tsconfig.tsbuildinfo +1 -0
- package/package.json +38 -20
- package/src/_bindings-ffi.ts +0 -396
- package/src/_bindings.ts +0 -102
- package/src/bindings.ts +0 -11
package/README.md
CHANGED
|
@@ -10,8 +10,6 @@ Key features:
|
|
|
10
10
|
|
|
11
11
|
- Workspace URL and numeric workspace id resolution from AppKit context,
|
|
12
12
|
Databricks SDK config, env, and config files.
|
|
13
|
-
- Rust-backed Databricks App detection shared with authentication providers.
|
|
14
|
-
- Cached detection of whether the Databricks CLI auth surface is available.
|
|
15
13
|
- `DatabricksFileSystem` (`FileSystem` over workspace files, UC volumes, and DBFS)
|
|
16
14
|
with intelligent roots: `/Workspace/...`, `/Volumes/...` (also `/Volume/...` and
|
|
17
15
|
`catalog.schema.volume`), `~` → `/Workspace/Users/<userName>`, and `/dbfs/...`.
|
|
@@ -23,27 +21,13 @@ Key features:
|
|
|
23
21
|
- DNS A/AAAA lookup helpers for Databricks and adjacent service hosts.
|
|
24
22
|
- Memoized outbound public-IP discovery for setup and diagnostics.
|
|
25
23
|
|
|
26
|
-
## Detect The Runtime
|
|
27
|
-
|
|
28
|
-
```ts
|
|
29
|
-
import { databricksCliAvailable, isDatabricksApp } from "@dbx-tools/databricks";
|
|
30
|
-
|
|
31
|
-
const inApp = isDatabricksApp();
|
|
32
|
-
const hasDatabricksAuth = databricksCliAvailable();
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
`isDatabricksApp()` honors `DBX_TOOLS_DATABRICKS_APP_ENV`, then requires a
|
|
36
|
-
valid `DATABRICKS_APP_NAME`, HTTP(S) `DATABRICKS_HOST`, and
|
|
37
|
-
`DATABRICKS_APP_PORT`. `databricksCliAvailable()` caches whether
|
|
38
|
-
`databricks auth --help` succeeds for the process. The generated bindings and
|
|
39
|
-
the package's direct TypeScript modules share this package root.
|
|
40
|
-
|
|
41
24
|
## Relationship To Native AppKit
|
|
42
25
|
|
|
43
26
|
Use native AppKit for its standard workspace client and plugin integrations.
|
|
44
|
-
Use this package when code
|
|
45
|
-
|
|
46
|
-
|
|
27
|
+
Use this package when code needs Databricks filesystem root normalization,
|
|
28
|
+
cloud region discovery, network helpers, or workspace identity fallbacks
|
|
29
|
+
outside an AppKit request. Use [`@dbx-tools/client`](../client) for Rust-backed
|
|
30
|
+
App detection and authentication.
|
|
47
31
|
|
|
48
32
|
## Databricks filesystem
|
|
49
33
|
|
|
@@ -127,8 +111,6 @@ short-lived reuse.
|
|
|
127
111
|
- `workspace` - workspace URL/id, `tryGetWorkspaceClient` / `getWorkspaceClient`, and current username.
|
|
128
112
|
- `cloud` - provider/region detection from public cloud IP ranges.
|
|
129
113
|
- `net` - DNS A/AAAA resolution and outbound public-IP discovery.
|
|
130
|
-
- package root - Rust-backed `isDatabricksApp` and
|
|
131
|
-
`databricksCliAvailable`.
|
|
132
114
|
|
|
133
115
|
Zerobus endpoint construction builds on these helpers in
|
|
134
116
|
[`@dbx-tools/databricks-zerobus`](../databricks-zerobus).
|
package/index.ts
CHANGED
|
@@ -3,8 +3,7 @@
|
|
|
3
3
|
// Hand edits are overwritten on the next watch; this file is read-only.
|
|
4
4
|
|
|
5
5
|
export const PACKAGE_IDENTIFIER = "@dbx-tools/databricks";
|
|
6
|
-
export const PACKAGE_VERSION = "0.6.
|
|
7
|
-
export * from "./src/bindings.ts";
|
|
6
|
+
export const PACKAGE_VERSION = "0.6.183";
|
|
8
7
|
export * as cloud from "./src/cloud.ts";
|
|
9
8
|
export * as databricksFS from "./src/databricks-fs.ts";
|
|
10
9
|
export * as databricksPath from "./src/databricks-path.ts";
|
package/lib/index.d.ts
ADDED
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export declare const PACKAGE_IDENTIFIER = "@dbx-tools/databricks";
|
|
2
|
+
export declare const PACKAGE_VERSION = "0.6.183";
|
|
3
|
+
export * as cloud from "./src/cloud.ts";
|
|
4
|
+
export * as databricksFS from "./src/databricks-fs.ts";
|
|
5
|
+
export * as databricksPath from "./src/databricks-path.ts";
|
|
6
|
+
export * as net from "./src/net.ts";
|
|
7
|
+
export * as workspace from "./src/workspace.ts";
|
|
8
|
+
export { RANGE_CACHE_TTL_MS, CloudProvider } from "./src/cloud.ts";
|
|
9
|
+
export type { CloudLocation } from "./src/cloud.ts";
|
|
10
|
+
export { DatabricksFileSystem } from "./src/databricks-fs.ts";
|
|
11
|
+
export type { DatabricksFileSystemOptions } from "./src/databricks-fs.ts";
|
|
12
|
+
export { isHomeRelativePath } from "./src/databricks-path.ts";
|
|
13
|
+
export type { DatabricksFilesBackend, NormalizeDatabricksRootOptions, ResolveDatabricksRootOptions } from "./src/databricks-path.ts";
|
|
14
|
+
export { getPublicIp } from "./src/net.ts";
|
|
15
|
+
export type { WorkspaceClient } from "./src/workspace.ts";
|