@elaraai/e3-cli 1.0.79 → 1.0.80
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 +99 -25
- package/dist/src/cli.js +49 -9
- package/dist/src/cli.js.map +1 -1
- package/dist/src/commands/budget.d.ts +32 -0
- package/dist/src/commands/budget.d.ts.map +1 -0
- package/dist/src/commands/budget.js +46 -0
- package/dist/src/commands/budget.js.map +1 -0
- package/dist/src/commands/call.d.ts +2 -1
- package/dist/src/commands/call.d.ts.map +1 -1
- package/dist/src/commands/call.js +5 -3
- package/dist/src/commands/call.js.map +1 -1
- package/dist/src/commands/compact.spec.js +7 -6
- package/dist/src/commands/compact.spec.js.map +1 -1
- package/dist/src/commands/history.d.ts +1 -0
- package/dist/src/commands/history.d.ts.map +1 -1
- package/dist/src/commands/history.js +30 -9
- package/dist/src/commands/history.js.map +1 -1
- package/dist/src/commands/logs.d.ts +2 -2
- package/dist/src/commands/logs.d.ts.map +1 -1
- package/dist/src/commands/logs.js +28 -28
- package/dist/src/commands/logs.js.map +1 -1
- package/dist/src/commands/logs.spec.js +4 -1
- package/dist/src/commands/logs.spec.js.map +1 -1
- package/dist/src/commands/mutate.d.ts +2 -1
- package/dist/src/commands/mutate.d.ts.map +1 -1
- package/dist/src/commands/mutate.js +42 -19
- package/dist/src/commands/mutate.js.map +1 -1
- package/dist/src/commands/reindex.d.ts +12 -0
- package/dist/src/commands/reindex.d.ts.map +1 -0
- package/dist/src/commands/reindex.js +67 -0
- package/dist/src/commands/reindex.js.map +1 -0
- package/dist/src/commands/repo.d.ts +4 -1
- package/dist/src/commands/repo.d.ts.map +1 -1
- package/dist/src/commands/repo.js +32 -16
- package/dist/src/commands/repo.js.map +1 -1
- package/dist/src/commands/run.d.ts +2 -1
- package/dist/src/commands/run.d.ts.map +1 -1
- package/dist/src/commands/run.js +15 -21
- package/dist/src/commands/run.js.map +1 -1
- package/dist/src/commands/set.d.ts.map +1 -1
- package/dist/src/commands/set.js +15 -15
- package/dist/src/commands/set.js.map +1 -1
- package/dist/src/commands/start.d.ts +2 -2
- package/dist/src/commands/start.d.ts.map +1 -1
- package/dist/src/commands/start.js +33 -27
- package/dist/src/commands/start.js.map +1 -1
- package/dist/src/commands/watch.d.ts +4 -2
- package/dist/src/commands/watch.d.ts.map +1 -1
- package/dist/src/commands/watch.js +35 -9
- package/dist/src/commands/watch.js.map +1 -1
- package/dist/src/commands/workspace.d.ts +25 -2
- package/dist/src/commands/workspace.d.ts.map +1 -1
- package/dist/src/commands/workspace.js +173 -21
- package/dist/src/commands/workspace.js.map +1 -1
- package/dist/src/format.d.ts +12 -0
- package/dist/src/format.d.ts.map +1 -1
- package/dist/src/format.js +19 -3
- package/dist/src/format.js.map +1 -1
- package/dist/src/path-resolver.d.ts.map +1 -1
- package/dist/src/path-resolver.js +3 -2
- package/dist/src/path-resolver.js.map +1 -1
- package/dist/src/utils.d.ts +15 -2
- package/dist/src/utils.d.ts.map +1 -1
- package/dist/src/utils.js +25 -7
- package/dist/src/utils.js.map +1 -1
- package/package.json +7 -7
- package/dist/src/commands/jobs.d.ts +0 -25
- package/dist/src/commands/jobs.d.ts.map +0 -1
- package/dist/src/commands/jobs.js +0 -39
- package/dist/src/commands/jobs.js.map +0 -1
package/README.md
CHANGED
|
@@ -15,13 +15,19 @@ Every command that takes `<repo>` accepts either a local path or an `http(s)://`
|
|
|
15
15
|
### Repository
|
|
16
16
|
|
|
17
17
|
```bash
|
|
18
|
-
e3 repo create <repo>
|
|
18
|
+
e3 repo create <repo> [--exist-ok] # Create a new repository
|
|
19
19
|
e3 repo status <repo> # Show repository status
|
|
20
20
|
e3 repo remove <repo> [-r] # Remove a repository (-r removes workspaces first)
|
|
21
|
-
e3 repo gc <repo> [--dry-run]
|
|
21
|
+
e3 repo gc <repo> [--dry-run] [--keep-runs <n>] [--keep-days <d>] # Remove old history and unreferenced objects
|
|
22
22
|
e3 repo list <server-url> # List repositories on a server
|
|
23
23
|
```
|
|
24
24
|
|
|
25
|
+
`repo gc` keeps each workspace's last 10 runs (`--keep-runs`), every run from
|
|
26
|
+
the last 7 days (`--keep-days`) and the run its current state came from, with
|
|
27
|
+
the executions they used; every execution a workspace's current state is served
|
|
28
|
+
from, so a re-run stays cached; and every execution from the last 7 days. The
|
|
29
|
+
rest of the history goes, with the outputs only it kept.
|
|
30
|
+
|
|
25
31
|
### Packages
|
|
26
32
|
|
|
27
33
|
```bash
|
|
@@ -37,13 +43,32 @@ e3 package remove <repo> <pkg> # Remove a package
|
|
|
37
43
|
e3 workspace create <repo> <name> # Create empty workspace
|
|
38
44
|
e3 workspace deploy <repo> <ws> <pkg>[@<ver>] # Deploy a package
|
|
39
45
|
e3 workspace deploy <repo> <ws> --from-zip <path.zip> # Import + create + deploy in one shot
|
|
46
|
+
e3 workspace deploy <repo> <ws> --from-source <file.ts> # Bundle a TypeScript source into a package, then import + create + deploy
|
|
40
47
|
e3 workspace deploy <repo> <ws> … --skip-file-sources # Leave `file`-source inputs unset
|
|
48
|
+
e3 workspace deploy <repo> <ws> … --functions <path...> # Function manifests for East.importFunction packages built elsewhere
|
|
49
|
+
e3 workspace deploy <repo> <ws> … --schema <policy> # A record that cannot be kept as it is: migrate (default), fail, or reset
|
|
50
|
+
e3 workspace deploy <repo> <ws> … --allow-drop-records # Drop a record the package no longer declares, with its state and history
|
|
51
|
+
e3 workspace deploy <repo> <ws> … --plan # Say what the deploy would do to each record and index; write nothing
|
|
41
52
|
e3 workspace export <repo> <ws> <zip> # Export workspace as a package
|
|
42
53
|
e3 workspace list <repo> # List workspaces
|
|
43
54
|
e3 workspace status <repo> <ws> # Detailed workspace status
|
|
44
55
|
e3 workspace remove <repo> <ws> # Remove a workspace
|
|
45
56
|
```
|
|
46
57
|
|
|
58
|
+
A deploy decides what to do with each record before it writes anything. It
|
|
59
|
+
mints a new record's `$init` commit, keeps one whose migrations have all been
|
|
60
|
+
applied (with a `$deploy` commit when the package changed), and runs the
|
|
61
|
+
migrations a workspace has not applied, a `$migrate:<name>` commit each. A
|
|
62
|
+
record whose type changed with no migration, or whose applied steps the
|
|
63
|
+
package's chain does not start with, is refused, and so is a record the
|
|
64
|
+
package no longer declares, unless `--allow-drop-records`. `--schema fail`
|
|
65
|
+
runs no migration and refuses instead; `--schema reset` resets such a record to
|
|
66
|
+
the package's initial value, with a `$reset` commit. `--plan` prints the plan
|
|
67
|
+
and writes nothing. From a zip or a source it imports nothing: it reads the
|
|
68
|
+
package from the zip where it is. A server plans only a package it holds, so
|
|
69
|
+
there it is refused: `e3 package import` the zip, then plan the package by
|
|
70
|
+
name.
|
|
71
|
+
|
|
47
72
|
### Datasets
|
|
48
73
|
|
|
49
74
|
Dataset paths use the flat form `<ws>.<name>`. The CLI resolves `<name>` against inputs and task outputs automatically.
|
|
@@ -51,38 +76,65 @@ Dataset paths use the flat form `<ws>.<name>`. The CLI resolves `<name>` against
|
|
|
51
76
|
```bash
|
|
52
77
|
e3 dataset get <repo> <ws.name> [-f east|json|beast2]
|
|
53
78
|
e3 dataset set <repo> <ws.name> <file> [--type <spec>] [--type-file <path>]
|
|
79
|
+
e3 dataset set <repo> <ws.name> --from-file <path.beast2> # Take a beast2 file in as the value, a segment at a time
|
|
54
80
|
e3 dataset list <repo> <ws> [-l] # List dataset paths (with -l for table view)
|
|
55
81
|
e3 dataset status <repo> <ws.name> # Show one dataset's kind/type/status/size
|
|
56
82
|
e3 dataset find <repo> <ws> <pattern> # Substring or glob (`*`, `?`) match across names
|
|
57
83
|
```
|
|
58
84
|
|
|
85
|
+
### Records
|
|
86
|
+
|
|
87
|
+
A record is written only through its mutations — a raw `dataset set` on one is
|
|
88
|
+
refused — and `-w` names the workspace that holds it. Read its state with
|
|
89
|
+
`dataset get`, like any dataset.
|
|
90
|
+
|
|
91
|
+
```bash
|
|
92
|
+
e3 mutate <repo> <record.mutation> [args...] -w <ws> [-v] # Apply a mutation; args are .east literals or .beast2/.json/.east files
|
|
93
|
+
e3 history <repo> <record> -w <ws> [--limit <n>] [--from <hash>] [--delta] # The commit chain, newest first (--delta: local repositories)
|
|
94
|
+
e3 reindex <repo> <record> -w <ws> [--index <name>] # Rebuild an index from the record (every one by default)
|
|
95
|
+
e3 compact <repo> <record> -w <ws> # Collapse the history to a $compact root; the state is kept
|
|
96
|
+
```
|
|
97
|
+
|
|
59
98
|
### Tasks
|
|
60
99
|
|
|
61
100
|
```bash
|
|
62
101
|
e3 task list <repo> <ws> # List tasks with execution status
|
|
63
|
-
e3 task logs <repo> <ws.task>
|
|
64
|
-
e3 task logs <repo> <ws.task> --
|
|
102
|
+
e3 task logs <repo> <ws.task> # The last 200 lines of a task's logs (-n <lines> for more, --all for the whole log)
|
|
103
|
+
e3 task logs <repo> <ws.task> --follow # Tail, then stream live output
|
|
104
|
+
e3 task logs <repo> --execution <taskHash>/<inputsHash>/<executionId> # One execution's own log — a unit a split task's log names (local repositories)
|
|
65
105
|
```
|
|
66
106
|
|
|
67
107
|
### Dataflow execution
|
|
68
108
|
|
|
69
109
|
```bash
|
|
70
|
-
e3 dataflow run <repo> <ws> [--filter <p>] [-j <n>] [--force] [-v]
|
|
110
|
+
e3 dataflow run <repo> <ws> [--filter <p>] [-j <n>] [--memory <size>] [--force] [-v]
|
|
71
111
|
```
|
|
72
112
|
|
|
73
|
-
`-j` / `--jobs <n>`
|
|
74
|
-
e3
|
|
75
|
-
merge units of its
|
|
76
|
-
come first served, whatever launched it).
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
113
|
+
`-j` / `--jobs <n>` and `--memory <size>` are the budget of the runner processes
|
|
114
|
+
e3 spawns. `-j` is its cores: the runners in flight at once, across the
|
|
115
|
+
dataflow's tasks and the pieces and merge units of its split tasks alike (every
|
|
116
|
+
runner takes one, first come first served, whatever launched it). `--memory` is
|
|
117
|
+
the memory those runners may reserve between them, as `8G` or `512M`. They
|
|
118
|
+
default to `E3_JOBS` and `E3_MEMORY`, else to what e3 may use: the CPUs of its
|
|
119
|
+
affinity mask, capped by a cgroup quota, and the cgroup's `memory.max` or else
|
|
120
|
+
physical memory, less a reserve for e3 and the OS.
|
|
121
|
+
|
|
122
|
+
A unit of a split task reserves the largest peak memory a unit of its stage
|
|
123
|
+
(its pieces, or one level of its merges) has reached in the run, so each stage
|
|
124
|
+
runs its first unit alone and then fans out. Anything else reserves nothing. On
|
|
125
|
+
Linux and macOS a guard stops the newest such unit when the runners together
|
|
126
|
+
pass the budget, and runs it again once there is room.
|
|
127
|
+
|
|
128
|
+
`e3 watch`, `e3 run`, `e3 call`, `e3 mutate`, `e3 reindex` and
|
|
129
|
+
`e3 workspace deploy` take the same two flags for a local repository. Against a
|
|
130
|
+
server they are refused: it runs the work under its own budget
|
|
131
|
+
(`e3-api-server -j` / `--memory`).
|
|
132
|
+
|
|
133
|
+
A local run's per-execution scratch directories are created inside the
|
|
134
|
+
repository, under `<repo>/tmp/scratch` — on the object store's filesystem, so
|
|
135
|
+
an output that is not a collection is stored by a link rather than a copy — or
|
|
136
|
+
under `E3_SCRATCH_DIR` when it is set. A scratch directory left by a dead process is removed by the
|
|
137
|
+
next run or `e3 repo gc`.
|
|
86
138
|
|
|
87
139
|
`-v` / `--verbose` forwards `-v` to each task's runner so it prints a timing/perf
|
|
88
140
|
block to the task's logs (`e3 task logs <repo> <ws.task>`) — identical across
|
|
@@ -94,25 +146,46 @@ Also on `e3 run`, `e3 call`, and `e3 mutate` — local and remote repositories
|
|
|
94
146
|
After a successful run, the CLI prints the task output paths so you can read them straight away:
|
|
95
147
|
|
|
96
148
|
```
|
|
97
|
-
Summary:
|
|
149
|
+
Summary:
|
|
150
|
+
Executed: 2
|
|
151
|
+
Cached: 0
|
|
152
|
+
Failed: 0
|
|
153
|
+
Skipped: 0
|
|
154
|
+
Duration: 412ms
|
|
155
|
+
|
|
98
156
|
Outputs:
|
|
99
|
-
dev.greet
|
|
100
|
-
dev.shout
|
|
157
|
+
dev.greet 14 B
|
|
158
|
+
dev.shout 16 B
|
|
101
159
|
```
|
|
102
160
|
|
|
103
161
|
### Ad-hoc task execution
|
|
104
162
|
|
|
105
163
|
```bash
|
|
106
164
|
e3 run <repo> <pkg.task> <inputs...> -o <out>
|
|
107
|
-
e3 run <repo> <pkg@1.0.0.task> <in.beast2> -o <out.beast2> [-v]
|
|
165
|
+
e3 run <repo> <pkg@1.0.0.task> <in.beast2> -o <out.beast2> [--force] [-v] [-j <n>] [--memory <size>]
|
|
108
166
|
```
|
|
109
167
|
|
|
168
|
+
### Function calls
|
|
169
|
+
|
|
170
|
+
```bash
|
|
171
|
+
e3 call <repo> <pkg.fn> [args...] # Call by package: pkg.fn or pkg@1.0.0.fn
|
|
172
|
+
e3 call <repo> -w <ws> <fn> [args...] # Call the workspace's deployed package
|
|
173
|
+
e3 call <repo> <pkg.fn> 2 3 -o sum.beast2 # Write the raw result to a file
|
|
174
|
+
```
|
|
175
|
+
|
|
176
|
+
Arguments are `.east` literals or paths to `.beast2` / `.json` / `.east` files,
|
|
177
|
+
parsed against the function's parameter types. A call triggers no dataflow and
|
|
178
|
+
writes nothing to the repository.
|
|
179
|
+
|
|
110
180
|
### Watch / live development
|
|
111
181
|
|
|
112
182
|
```bash
|
|
113
|
-
e3 watch <source.ts> <repo> <ws> [--start] [-j <n>] [--abort-on-change]
|
|
183
|
+
e3 watch <source.ts> <repo> <ws> [--start] [--schema <policy>] [-j <n>] [--memory <size>] [--abort-on-change] [--functions <path...>]
|
|
114
184
|
```
|
|
115
185
|
|
|
186
|
+
`--schema` is the deploy's (`e3 workspace deploy`); a record whose type changes
|
|
187
|
+
with no migration stops the watch, naming `--schema=reset`.
|
|
188
|
+
|
|
116
189
|
### Authentication
|
|
117
190
|
|
|
118
191
|
```bash
|
|
@@ -145,7 +218,7 @@ The completion script delegates dynamic lookups (workspace names, dataset paths,
|
|
|
145
218
|
|
|
146
219
|
### Defaulting the repository
|
|
147
220
|
|
|
148
|
-
When the positional `<repo>` is optional (every command that takes one as the first argument, except `run` and `watch`), the value is resolved in this order:
|
|
221
|
+
When the positional `<repo>` is optional (every command that takes one as the first argument, except `run`, `call`, `mutate`, `history`, `compact`, `reindex` and `watch`), the value is resolved in this order:
|
|
149
222
|
|
|
150
223
|
1. Explicit positional argument.
|
|
151
224
|
2. `E3_REPO` environment variable.
|
|
@@ -191,6 +264,7 @@ release may reshape it. Application code should use
|
|
|
191
264
|
| `e3 workspace import <repo> <ws> <zip>` | `e3 workspace deploy <repo> <ws> --from-zip <zip>` |
|
|
192
265
|
| `e3 run <repo> <pkg>/<task>` | `e3 run <repo> <pkg>.<task>` |
|
|
193
266
|
| `e3 watch <repo> <ws> <source>` | `e3 watch <source> <repo> <ws>` |
|
|
267
|
+
| `--concurrency <n>`, `--partition-concurrency <n>` | `-j <n>` / `--jobs <n>` |
|
|
194
268
|
|
|
195
269
|
## Example
|
|
196
270
|
|
|
@@ -259,7 +333,7 @@ BSL 1.1. See [LICENSE.md](./LICENSE.md).
|
|
|
259
333
|
- [@elaraai/e3](https://www.npmjs.com/package/@elaraai/e3): SDK for authoring e3 packages with typed tasks and pipelines
|
|
260
334
|
- [@elaraai/e3-core](https://www.npmjs.com/package/@elaraai/e3-core): Object store, dataflow orchestrator, execution state
|
|
261
335
|
- [@elaraai/e3-types](https://www.npmjs.com/package/@elaraai/e3-types): Shared type definitions for e3 packages
|
|
262
|
-
- [@elaraai/e3-cli](https://www.npmjs.com/package/@elaraai/e3-cli): `e3 repo`, `e3 package`, `e3 workspace`, `e3
|
|
336
|
+
- [@elaraai/e3-cli](https://www.npmjs.com/package/@elaraai/e3-cli): `e3 repo`, `e3 package`, `e3 workspace`, `e3 dataflow run`, `e3 watch`, `e3 task logs` commands
|
|
263
337
|
- [@elaraai/e3-api-client](https://www.npmjs.com/package/@elaraai/e3-api-client): HTTP client for remote e3 repositories
|
|
264
338
|
- [@elaraai/e3-api-server](https://www.npmjs.com/package/@elaraai/e3-api-server): REST API server for e3 repositories
|
|
265
339
|
- [@elaraai/e3-api-tests](https://www.npmjs.com/package/@elaraai/e3-api-tests): Shared API compliance test suites
|
package/dist/src/cli.js
CHANGED
|
@@ -24,7 +24,9 @@
|
|
|
24
24
|
* transport is detected from the argument.
|
|
25
25
|
*/
|
|
26
26
|
import { createRequire } from 'node:module';
|
|
27
|
-
import { Command
|
|
27
|
+
import { Command } from 'commander';
|
|
28
|
+
import { configureFramePool } from '@elaraai/east';
|
|
29
|
+
import { DEFAULT_KEEP_DAYS, DEFAULT_KEEP_RUNS, DOOR_FRAME_WORKERS } from '@elaraai/e3-core';
|
|
28
30
|
const require = createRequire(import.meta.url);
|
|
29
31
|
const packageJson = require('../../package.json');
|
|
30
32
|
import { repoCommand } from './commands/repo.js';
|
|
@@ -39,6 +41,7 @@ import { callCommand } from './commands/call.js';
|
|
|
39
41
|
import { mutateCommand } from './commands/mutate.js';
|
|
40
42
|
import { historyCommand } from './commands/history.js';
|
|
41
43
|
import { compactCommand } from './commands/compact.js';
|
|
44
|
+
import { reindexCommand } from './commands/reindex.js';
|
|
42
45
|
import { logsCommand, DEFAULT_TAIL_LINES } from './commands/logs.js';
|
|
43
46
|
import { datasetStatusCommand } from './commands/dataset-status.js';
|
|
44
47
|
import { findCommand } from './commands/find.js';
|
|
@@ -49,6 +52,15 @@ import { completionCommand } from './commands/completion.js';
|
|
|
49
52
|
import { installCommand as completionInstall, uninstallCommand as completionUninstall } from './commands/completion-install.js';
|
|
50
53
|
import { completeCommand } from './commands/complete.js';
|
|
51
54
|
import { withDefaultRepo, defaultRepoArg } from './utils.js';
|
|
55
|
+
// The store door frames on two workers; a command that runs units caps them
|
|
56
|
+
// from its budget.
|
|
57
|
+
configureFramePool({ workers: DOOR_FRAME_WORKERS });
|
|
58
|
+
// The budget every command that runs units takes, for a local repository: a
|
|
59
|
+
// server runs the work under its own.
|
|
60
|
+
const JOBS = ['-j, --jobs <n>', 'Cores: runner processes to keep in flight, a task or a unit each (local repositories; default: $E3_JOBS, else the CPUs available to e3)'];
|
|
61
|
+
const MEMORY = ['--memory <size>', 'Memory those runner processes may reserve between them, as 8G or 512M (local repositories; default: $E3_MEMORY, else the memory available to e3, less a reserve for e3 and the OS)'];
|
|
62
|
+
// What a deploy does with a record it cannot keep as it is.
|
|
63
|
+
const SCHEMA = ['--schema <policy>', "What to do with a record the deploy cannot keep as it is: migrate (run the migrations the workspace has not applied; the default), fail (run none, and refuse) or reset (reset it to the package's initial value)"];
|
|
52
64
|
const program = new Command();
|
|
53
65
|
program
|
|
54
66
|
.name('e3')
|
|
@@ -75,10 +87,12 @@ program
|
|
|
75
87
|
.argument('[repo]', 'Repository path or URL (default: $E3_REPO or .)')
|
|
76
88
|
.action(withDefaultRepo(repoCommand.status)))
|
|
77
89
|
.addCommand(new Command('gc')
|
|
78
|
-
.description('Remove unreferenced objects')
|
|
90
|
+
.description('Remove the run and execution history the repository no longer keeps, and unreferenced objects')
|
|
79
91
|
.argument('[repo]', 'Repository path or URL (default: $E3_REPO or .)')
|
|
80
92
|
.option('--dry-run', 'Report what would be deleted without deleting')
|
|
81
93
|
.option('--min-age <ms>', 'Minimum file age in ms before deletion', '60000')
|
|
94
|
+
.option('--keep-runs <n>', `Runs of each workspace to keep however old, the latest first, with the executions they used (default: ${DEFAULT_KEEP_RUNS})`)
|
|
95
|
+
.option('--keep-days <d>', `Days of runs and executions to keep however many (default: ${DEFAULT_KEEP_DAYS})`)
|
|
82
96
|
.action(withDefaultRepo(repoCommand.gc)))
|
|
83
97
|
.addCommand(new Command('list')
|
|
84
98
|
.description('List repositories on a server')
|
|
@@ -132,7 +146,12 @@ program
|
|
|
132
146
|
.option('--from-source <path>', 'Bundle a TypeScript source file into a package, then import and deploy (creates the workspace if needed)')
|
|
133
147
|
.option('--functions <path...>', 'Function manifests (east-py / east-node export-functions) for East.importFunction packages built elsewhere; a package of this uv or npm workspace is exported and linked by itself')
|
|
134
148
|
.option('--skip-file-sources', "Deploy without reading the package's file sources; those inputs stay unset until `e3 dataset set --from-file`")
|
|
149
|
+
.option(...SCHEMA)
|
|
150
|
+
.option('--allow-drop-records', 'Drop a record the package no longer declares, with its state and history')
|
|
151
|
+
.option('--plan', 'Say what the deploy would do to each record and index, and write nothing')
|
|
135
152
|
.option('--quiet', 'Suppress progress and success output (errors only)')
|
|
153
|
+
.option(...JOBS)
|
|
154
|
+
.option(...MEMORY)
|
|
136
155
|
.action(withDefaultRepo(workspaceCommand.deploy)))
|
|
137
156
|
.addCommand(new Command('export')
|
|
138
157
|
.description('Export workspace as a package')
|
|
@@ -176,7 +195,7 @@ program
|
|
|
176
195
|
.argument('[file]', 'Path to .east, .beast2, .json, or .csv file')
|
|
177
196
|
.option('--type <typespec>', 'Inline .east type specification (required for .json/.csv)')
|
|
178
197
|
.option('--type-file <path>', 'Read .east type specification from a file (alternative to --type)')
|
|
179
|
-
.option('--from-file <path>', '
|
|
198
|
+
.option('--from-file <path>', 'Take an existing .beast2 file in as the value — read a segment at a time, never whole, and never modified')
|
|
180
199
|
.action(withDefaultRepo(setCommand)))
|
|
181
200
|
.addCommand(new Command('list')
|
|
182
201
|
.description('List dataset paths in a workspace')
|
|
@@ -213,7 +232,7 @@ program
|
|
|
213
232
|
.option('-n, --lines <n>', `Show the last <n> lines (default: ${DEFAULT_TAIL_LINES})`)
|
|
214
233
|
.option('--all', 'Show the whole log instead of the last lines')
|
|
215
234
|
.option('--follow', 'Follow log output')
|
|
216
|
-
.option('--execution <ref>', "View one execution's logs by <taskHash>/<inputsHash>/<executionId>, as a
|
|
235
|
+
.option('--execution <ref>', "View one execution's logs by <taskHash>/<inputsHash>/<executionId>, as a split task's log names its units (local repositories)")
|
|
217
236
|
.action(withDefaultRepo(logsCommand)));
|
|
218
237
|
// ---------------------------------------------------------------------------
|
|
219
238
|
// dataflow
|
|
@@ -226,9 +245,8 @@ program
|
|
|
226
245
|
.argument('[repo]', 'Repository path or URL (default: $E3_REPO or .)')
|
|
227
246
|
.argument('<ws>', 'Workspace name')
|
|
228
247
|
.option('--filter <pattern>', 'Only run tasks matching pattern')
|
|
229
|
-
.option(
|
|
230
|
-
.
|
|
231
|
-
.addOption(new Option('--partition-concurrency <n>', 'Deprecated: use --jobs').hideHelp())
|
|
248
|
+
.option(...JOBS)
|
|
249
|
+
.option(...MEMORY)
|
|
232
250
|
.option('--force', 'Force re-execution even if cached')
|
|
233
251
|
.option('-v, --verbose', "Pass -v to each task's runner (timing/perf to stderr)")
|
|
234
252
|
.action(withDefaultRepo(startCommand)));
|
|
@@ -248,6 +266,8 @@ program
|
|
|
248
266
|
.option('-o, --output <path>', 'Output file path')
|
|
249
267
|
.option('--force', 'Force re-execution even if cached')
|
|
250
268
|
.option('-v, --verbose', "Pass -v to the runner (timing/perf to stderr)")
|
|
269
|
+
.option(...JOBS)
|
|
270
|
+
.option(...MEMORY)
|
|
251
271
|
.action(runCommand);
|
|
252
272
|
// ---------------------------------------------------------------------------
|
|
253
273
|
// call — named package functions (graph-free, persists nothing)
|
|
@@ -261,6 +281,8 @@ program
|
|
|
261
281
|
.option('-w, --workspace <ws>', 'Call against the package deployed in a workspace')
|
|
262
282
|
.option('-o, --output <path>', 'Write the result to a .beast2 file instead of printing')
|
|
263
283
|
.option('-v, --verbose', "Pass -v to the runner (timing/perf to stderr; local or remote)")
|
|
284
|
+
.option(...JOBS)
|
|
285
|
+
.option(...MEMORY)
|
|
264
286
|
.action(callCommand);
|
|
265
287
|
// ---------------------------------------------------------------------------
|
|
266
288
|
// mutate — apply a mutation to a record (the only write door; audited commit)
|
|
@@ -273,6 +295,8 @@ program
|
|
|
273
295
|
.argument('[args...]', 'Arguments: .east literals or .beast2/.json/.east file paths')
|
|
274
296
|
.option('-w, --workspace <ws>', 'Workspace holding the record (required)')
|
|
275
297
|
.option('-v, --verbose', "Pass -v to the reducer's runner (timing/perf to stderr; local or remote)")
|
|
298
|
+
.option(...JOBS)
|
|
299
|
+
.option(...MEMORY)
|
|
276
300
|
.action(mutateCommand);
|
|
277
301
|
// ---------------------------------------------------------------------------
|
|
278
302
|
// history — a record's commit history (newest first)
|
|
@@ -285,6 +309,7 @@ program
|
|
|
285
309
|
.option('-w, --workspace <ws>', 'Workspace holding the record (required)')
|
|
286
310
|
.option('--limit <n>', 'Maximum number of commits to show')
|
|
287
311
|
.option('--from <hash>', 'Commit hash to start the walk at (page cursor)')
|
|
312
|
+
.option('--delta', "Show what each commit changed, per target (local repositories)")
|
|
288
313
|
.action(historyCommand);
|
|
289
314
|
// ---------------------------------------------------------------------------
|
|
290
315
|
// compact — drop a record's prior commit chain (state unchanged)
|
|
@@ -297,6 +322,20 @@ program
|
|
|
297
322
|
.option('-w, --workspace <ws>', 'Workspace holding the record (required)')
|
|
298
323
|
.action(compactCommand);
|
|
299
324
|
// ---------------------------------------------------------------------------
|
|
325
|
+
// reindex — rebuild a record's secondary indexes from its primary
|
|
326
|
+
// ---------------------------------------------------------------------------
|
|
327
|
+
program
|
|
328
|
+
.command('reindex')
|
|
329
|
+
.description("Rebuild a record's secondary indexes from its primary (the state is unchanged)")
|
|
330
|
+
.argument('<repo>', 'Repository path')
|
|
331
|
+
.argument('<record>', 'Record name')
|
|
332
|
+
.option('-w, --workspace <ws>', 'Workspace holding the record (required)')
|
|
333
|
+
.option('--index <name>', 'Rebuild one index (default: every index the record declares)')
|
|
334
|
+
.option('-v, --verbose', "Pass -v to the index programs' runner (timing/perf to stderr)")
|
|
335
|
+
.option(...JOBS)
|
|
336
|
+
.option(...MEMORY)
|
|
337
|
+
.action(reindexCommand);
|
|
338
|
+
// ---------------------------------------------------------------------------
|
|
300
339
|
// watch — source first, workspace second
|
|
301
340
|
// ---------------------------------------------------------------------------
|
|
302
341
|
program
|
|
@@ -306,8 +345,9 @@ program
|
|
|
306
345
|
.argument('<repo>', 'Repository path or URL')
|
|
307
346
|
.argument('<workspace>', 'Workspace name')
|
|
308
347
|
.option('--start', 'Execute dataflow after each deploy')
|
|
309
|
-
.option(
|
|
310
|
-
.
|
|
348
|
+
.option(...SCHEMA)
|
|
349
|
+
.option(...JOBS)
|
|
350
|
+
.option(...MEMORY)
|
|
311
351
|
.option('--abort-on-change', 'Abort running execution when file changes')
|
|
312
352
|
.option('--functions <path...>', 'Function manifests (east-py / east-node export-functions) for East.importFunction packages built elsewhere; a package of this uv or npm workspace is exported and linked by itself')
|
|
313
353
|
.action(watchCommand);
|
package/dist/src/cli.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cli.js","sourceRoot":"","sources":["../../src/cli.ts"],"names":[],"mappings":";AAEA;;;GAGG;AAEH;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAC;AAE5C,MAAM,OAAO,GAAG,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC;AAC/C,MAAM,WAAW,GAAG,OAAO,CAAC,oBAAoB,CAAwB,CAAC;AAEzE,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC3D,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,YAAY,EAAE,MAAM,qBAAqB,CAAC;AACnD,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AACjD,OAAO,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AACrD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AACvD,OAAO,EAAE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,CAC1C;KACA,UAAU,CACT,IAAI,OAAO,CAAC,MAAM,CAAC;KAChB,WAAW,CAAC,8BAA8B,CAAC;KAC3C,MAAM,CAAC,GAAG,EAAE,CAAC,iBAAiB,CAAC,MAAM,CAAC,CAAC,CAC3C,CAAC;AAEJ,OAAO;KACJ,OAAO,CAAC,YAAY,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,CAAC;KACvC,QAAQ,CAAC,SAAS,EAAE,6CAA6C,CAAC;KAClE,QAAQ,CAAC,YAAY,EAAE,qDAAqD,CAAC;KAC7E,MAAM,CAAC,eAAe,CAAC,CAAC;AAE3B,OAAO,CAAC,KAAK,EAAE,CAAC"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025 Elara AI Pty Ltd
|
|
3
|
+
* Licensed under BSL 1.1. See LICENSE for details.
|
|
4
|
+
*/
|
|
5
|
+
import { type Budget } from '@elaraai/e3-core';
|
|
6
|
+
/** The flags that name a budget. */
|
|
7
|
+
export interface BudgetFlags {
|
|
8
|
+
/** `--jobs <n>` / `-j <n>`: the cores. */
|
|
9
|
+
jobs?: string;
|
|
10
|
+
/** `--memory <size>`: the memory. */
|
|
11
|
+
memory?: string;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* Resolves a command's budget — each of `--jobs` and `--memory`, else
|
|
15
|
+
* `E3_JOBS` and `E3_MEMORY`, else what this process may use — and caps e3's
|
|
16
|
+
* own frame pool, the one the store door frames on, from it.
|
|
17
|
+
*
|
|
18
|
+
* A value that is not a positive integer of cores or a memory size is an
|
|
19
|
+
* argument error: NaN would launch nothing and die later as "Dataflow stuck".
|
|
20
|
+
*
|
|
21
|
+
* @param flags - The parsed flags, when the command takes them
|
|
22
|
+
* @returns The budget
|
|
23
|
+
*/
|
|
24
|
+
export declare function commandBudget(flags?: BudgetFlags): Budget;
|
|
25
|
+
/**
|
|
26
|
+
* Refuses `-j` and `--memory` against a server, whose own budget runs the
|
|
27
|
+
* work.
|
|
28
|
+
*
|
|
29
|
+
* @param flags - The parsed flags
|
|
30
|
+
*/
|
|
31
|
+
export declare function refuseRemoteBudget(flags: BudgetFlags): void;
|
|
32
|
+
//# sourceMappingURL=budget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"budget.d.ts","sourceRoot":"","sources":["../../../src/commands/budget.ts"],"names":[],"mappings":"AAAA;;;GAGG;AASH,OAAO,EAAqC,KAAK,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAGlF,oCAAoC;AACpC,MAAM,WAAW,WAAW;IAC1B,0CAA0C;IAC1C,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,qCAAqC;IACrC,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,aAAa,CAAC,KAAK,GAAE,WAAgB,GAAG,MAAM,CAS7D;AAED;;;;;GAKG;AACH,wBAAgB,kBAAkB,CAAC,KAAK,EAAE,WAAW,GAAG,IAAI,CAI3D"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) 2025 Elara AI Pty Ltd
|
|
3
|
+
* Licensed under BSL 1.1. See LICENSE for details.
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* The budget of a command that runs units: the cores and the memory its
|
|
7
|
+
* runner processes take from — a dataflow's tasks and the units of its split
|
|
8
|
+
* tasks, a function call, a mutation, an index build.
|
|
9
|
+
*/
|
|
10
|
+
import { configureFramePool } from '@elaraai/east';
|
|
11
|
+
import { DOOR_FRAME_WORKERS, resolveBudget } from '@elaraai/e3-core';
|
|
12
|
+
import { exitError } from '../utils.js';
|
|
13
|
+
/**
|
|
14
|
+
* Resolves a command's budget — each of `--jobs` and `--memory`, else
|
|
15
|
+
* `E3_JOBS` and `E3_MEMORY`, else what this process may use — and caps e3's
|
|
16
|
+
* own frame pool, the one the store door frames on, from it.
|
|
17
|
+
*
|
|
18
|
+
* A value that is not a positive integer of cores or a memory size is an
|
|
19
|
+
* argument error: NaN would launch nothing and die later as "Dataflow stuck".
|
|
20
|
+
*
|
|
21
|
+
* @param flags - The parsed flags, when the command takes them
|
|
22
|
+
* @returns The budget
|
|
23
|
+
*/
|
|
24
|
+
export function commandBudget(flags = {}) {
|
|
25
|
+
let budget;
|
|
26
|
+
try {
|
|
27
|
+
budget = resolveBudget(flags);
|
|
28
|
+
}
|
|
29
|
+
catch (err) {
|
|
30
|
+
exitError(err instanceof Error ? err.message : String(err));
|
|
31
|
+
}
|
|
32
|
+
configureFramePool({ workers: Math.min(DOOR_FRAME_WORKERS, budget.cores) });
|
|
33
|
+
return budget;
|
|
34
|
+
}
|
|
35
|
+
/**
|
|
36
|
+
* Refuses `-j` and `--memory` against a server, whose own budget runs the
|
|
37
|
+
* work.
|
|
38
|
+
*
|
|
39
|
+
* @param flags - The parsed flags
|
|
40
|
+
*/
|
|
41
|
+
export function refuseRemoteBudget(flags) {
|
|
42
|
+
if (flags.jobs !== undefined || flags.memory !== undefined) {
|
|
43
|
+
exitError("-j and --memory budget a local repository's runners: a server runs the work under its own budget");
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
//# sourceMappingURL=budget.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"budget.js","sourceRoot":"","sources":["../../../src/commands/budget.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;GAIG;AAEH,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AACnD,OAAO,EAAE,kBAAkB,EAAE,aAAa,EAAe,MAAM,kBAAkB,CAAC;AAClF,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAUxC;;;;;;;;;;GAUG;AACH,MAAM,UAAU,aAAa,CAAC,QAAqB,EAAE;IACnD,IAAI,MAAc,CAAC;IACnB,IAAI,CAAC;QACH,MAAM,GAAG,aAAa,CAAC,KAAK,CAAC,CAAC;IAChC,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,SAAS,CAAC,GAAG,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC;IAC9D,CAAC;IACD,kBAAkB,CAAC,EAAE,OAAO,EAAE,IAAI,CAAC,GAAG,CAAC,kBAAkB,EAAE,MAAM,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;IAC5E,OAAO,MAAM,CAAC;AAChB,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,kBAAkB,CAAC,KAAkB;IACnD,IAAI,KAAK,CAAC,IAAI,KAAK,SAAS,IAAI,KAAK,CAAC,MAAM,KAAK,SAAS,EAAE,CAAC;QAC3D,SAAS,CAAC,kGAAkG,CAAC,CAAC;IAChH,CAAC;AACH,CAAC"}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
* Licensed under BSL 1.1. See LICENSE for details.
|
|
4
4
|
*/
|
|
5
5
|
import { type EastTypeValue } from '@elaraai/east';
|
|
6
|
+
import { type BudgetFlags } from './budget.js';
|
|
6
7
|
/**
|
|
7
8
|
* Parse a function spec. With --workspace a bare `fn` is allowed (the
|
|
8
9
|
* package comes from the deployment); otherwise `pkg.fn` / `pkg@ver.fn`.
|
|
@@ -20,7 +21,7 @@ export declare function encodeArg(raw: string, typeValue: EastTypeValue, index:
|
|
|
20
21
|
/**
|
|
21
22
|
* `e3 call` entry point.
|
|
22
23
|
*/
|
|
23
|
-
export declare function callCommand(repoArg: string, fnSpec: string, args: string[], options: {
|
|
24
|
+
export declare function callCommand(repoArg: string, fnSpec: string, args: string[], options: BudgetFlags & {
|
|
24
25
|
workspace?: string;
|
|
25
26
|
output?: string;
|
|
26
27
|
verbose?: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"call.d.ts","sourceRoot":"","sources":["../../../src/commands/call.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAmBH,OAAO,EASL,KAAK,aAAa,EAEnB,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"call.d.ts","sourceRoot":"","sources":["../../../src/commands/call.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAmBH,OAAO,EASL,KAAK,aAAa,EAEnB,MAAM,eAAe,CAAC;AAoBvB,OAAO,EAAqC,KAAK,WAAW,EAAE,MAAM,aAAa,CAAC;AAgBlF;;;GAGG;AACH,wBAAgB,iBAAiB,CAC/B,IAAI,EAAE,MAAM,EACZ,eAAe,EAAE,OAAO,GACvB;IAAE,IAAI,CAAC,EAAE,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAE,CAOjD;AAED;;;GAGG;AACH,wBAAsB,SAAS,CAAC,GAAG,EAAE,MAAM,EAAE,SAAS,EAAE,aAAa,EAAE,KAAK,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC,CA4BzG;AA+LD;;GAEG;AACH,wBAAsB,WAAW,CAC/B,OAAO,EAAE,MAAM,EACf,MAAM,EAAE,MAAM,EACd,IAAI,EAAE,MAAM,EAAE,EACd,OAAO,EAAE,WAAW,GAAG;IAAE,SAAS,CAAC,EAAE,MAAM,CAAC;IAAC,MAAM,CAAC,EAAE,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,OAAO,CAAA;CAAE,GAChF,OAAO,CAAC,IAAI,CAAC,CAaf"}
|
|
@@ -24,6 +24,7 @@ import { decodeFunctionObject } from '@elaraai/e3-types';
|
|
|
24
24
|
import { functionDescribe, functionCall, workspaceFunctionDescribe, workspaceFunctionCall, packageList as packageListRemote, } from '@elaraai/e3-api-client';
|
|
25
25
|
import { parseRepoLocation, formatError, exitError } from '../utils.js';
|
|
26
26
|
import { parseTaskSpec } from './run.js';
|
|
27
|
+
import { commandBudget, refuseRemoteBudget } from './budget.js';
|
|
27
28
|
// Local calls have no transport ceiling — be generous but still bounded.
|
|
28
29
|
const LOCAL_LIMITS = {
|
|
29
30
|
timeoutMs: 10 * 60_000,
|
|
@@ -130,7 +131,7 @@ async function renderResult(result, outputType, outputPath) {
|
|
|
130
131
|
/**
|
|
131
132
|
* Call a function in a local repository (no server round trip).
|
|
132
133
|
*/
|
|
133
|
-
async function callLocal(repoPath, spec, workspace, rawArgs, outputPath, verbose) {
|
|
134
|
+
async function callLocal(repoPath, spec, workspace, rawArgs, budget, outputPath, verbose) {
|
|
134
135
|
const storage = new LocalStorage();
|
|
135
136
|
let pkgName;
|
|
136
137
|
let version;
|
|
@@ -165,7 +166,7 @@ async function callLocal(repoPath, spec, workspace, rawArgs, outputPath, verbose
|
|
|
165
166
|
for (let i = 0; i < rawArgs.length; i++) {
|
|
166
167
|
args.push(await encodeArg(rawArgs[i], signature.inputTypes[i], i));
|
|
167
168
|
}
|
|
168
|
-
const runner = new LocalTaskRunner(repoPath);
|
|
169
|
+
const runner = new LocalTaskRunner(repoPath, budget);
|
|
169
170
|
const bodyIr = await storage.objects.read(repoPath, fnObj.bodyIr);
|
|
170
171
|
const detached = await runner.runDetached({
|
|
171
172
|
bodyIr,
|
|
@@ -238,9 +239,10 @@ export async function callCommand(repoArg, fnSpec, args, options) {
|
|
|
238
239
|
const spec = parseFunctionSpec(fnSpec, options.workspace !== undefined);
|
|
239
240
|
const location = await parseRepoLocation(repoArg);
|
|
240
241
|
if (location.type === 'local') {
|
|
241
|
-
await callLocal(location.path, spec, options.workspace, args, options.output, options.verbose);
|
|
242
|
+
await callLocal(location.path, spec, options.workspace, args, commandBudget(options), options.output, options.verbose);
|
|
242
243
|
}
|
|
243
244
|
else {
|
|
245
|
+
refuseRemoteBudget(options);
|
|
244
246
|
await callRemote(location.baseUrl, location.repo, location.token, spec, options.workspace, args, options.output, options.verbose);
|
|
245
247
|
}
|
|
246
248
|
}
|