@astrale-os/kernel-client 1.0.0-beta.5 → 1.0.0-beta.50
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/dist/auth/authorization.d.ts +10 -5
- package/dist/auth/authorization.js +14 -1
- package/dist/auth/index.d.ts +1 -0
- package/dist/client/admission.js +3 -1
- package/dist/client/client.d.ts +70 -4
- package/dist/client/client.js +209 -32
- package/dist/client/index.d.ts +3 -3
- package/dist/client/index.js +2 -2
- package/dist/client/level.d.ts +58 -0
- package/dist/client/level.js +159 -0
- package/dist/client/request.d.ts +7 -2
- package/dist/client/request.js +11 -7
- package/dist/client/result.d.ts +14 -1
- package/dist/client/result.js +19 -8
- package/dist/client/routing-control.d.ts +11 -15
- package/dist/client/routing-control.js +21 -29
- package/dist/errors/index.d.ts +3 -0
- package/dist/errors/index.js +3 -0
- package/dist/errors/inexpressible-error.d.ts +23 -0
- package/dist/errors/inexpressible-error.js +26 -0
- package/dist/errors/query-input.d.ts +47 -0
- package/dist/errors/query-input.js +85 -0
- package/dist/errors/refusal.d.ts +12 -0
- package/dist/errors/refusal.js +44 -6
- package/dist/errors/response-too-large-error.d.ts +11 -0
- package/dist/errors/response-too-large-error.js +15 -0
- package/dist/errors/stale-route-error.d.ts +1 -1
- package/dist/errors/stale-route-error.js +1 -1
- package/dist/{schema → execution}/admission.d.ts +2 -2
- package/dist/{schema → execution}/admission.js +2 -2
- package/dist/{session/execution.d.ts → execution/contracts.d.ts} +22 -34
- package/dist/execution/contracts.js +1 -0
- package/dist/execution/deadline.d.ts +18 -0
- package/dist/execution/deadline.js +25 -0
- package/dist/execution/execution.d.ts +61 -0
- package/dist/execution/execution.js +132 -0
- package/dist/execution/index.d.ts +4 -0
- package/dist/execution/index.js +3 -0
- package/dist/graph/domain/binding.d.ts +2 -2
- package/dist/graph/domain/binding.js +20 -17
- package/dist/graph/domain/conformance.d.ts +12 -0
- package/dist/graph/domain/conformance.js +18 -0
- package/dist/graph/domain/index.d.ts +1 -0
- package/dist/graph/domain/index.js +1 -1
- package/dist/graph/domain/provenance.d.ts +0 -2
- package/dist/graph/domain/provenance.js +0 -4
- package/dist/graph/graph.d.ts +17 -3
- package/dist/graph/graph.js +4 -1
- package/dist/graph/index.d.ts +3 -3
- package/dist/graph/index.js +1 -1
- package/dist/graph/page-contract.d.ts +66 -1
- package/dist/graph/provenance.d.ts +4 -5
- package/dist/graph/provenance.js +5 -6
- package/dist/graph/query.d.ts +10 -4
- package/dist/graph/query.js +144 -5
- package/dist/graph/query.typecheck.d.ts +81 -0
- package/dist/graph/query.typecheck.js +34 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/schema/contracts.d.ts +54 -79
- package/dist/schema/index.d.ts +2 -2
- package/dist/schema/index.js +1 -1
- package/dist/schema/installation.d.ts +36 -64
- package/dist/schema/installation.js +67 -131
- package/dist/schema/schema.d.ts +10 -16
- package/dist/schema/schema.js +57 -34
- package/dist/session/admission.js +10 -3
- package/dist/session/bound.d.ts +12 -3
- package/dist/session/bound.js +36 -32
- package/dist/session/content/api.d.ts +20 -2
- package/dist/session/content/api.js +17 -7
- package/dist/session/content/files.d.ts +12 -0
- package/dist/session/content/files.js +47 -0
- package/dist/session/content/index.d.ts +1 -1
- package/dist/session/content/input.d.ts +13 -2
- package/dist/session/content/input.js +25 -4
- package/dist/session/content/retry.d.ts +5 -1
- package/dist/session/content/retry.js +21 -31
- package/dist/session/context/index.d.ts +2 -2
- package/dist/session/context/index.js +2 -2
- package/dist/session/context/operation.d.ts +2 -0
- package/dist/session/context/operation.js +5 -0
- package/dist/session/context/policy.d.ts +2 -0
- package/dist/session/context/policy.js +6 -3
- package/dist/session/credential/credentials.d.ts +2 -1
- package/dist/session/credential/credentials.js +62 -29
- package/dist/session/discovery/bundle.d.ts +13 -4
- package/dist/session/discovery/bundle.js +85 -36
- package/dist/session/discovery/discovery.d.ts +1 -1
- package/dist/session/discovery/discovery.js +8 -11
- package/dist/session/discovery/index.d.ts +1 -0
- package/dist/session/discovery/index.js +5 -1
- package/dist/session/discovery/release.d.ts +2 -0
- package/dist/session/discovery/release.js +34 -31
- package/dist/session/discovery/response.d.ts +4 -0
- package/dist/session/discovery/response.js +10 -6
- package/dist/session/discovery/snapshot.d.ts +5 -1
- package/dist/session/discovery/transport.d.ts +37 -3
- package/dist/session/discovery/transport.js +62 -1
- package/dist/session/durable.d.ts +13 -0
- package/dist/session/durable.js +39 -0
- package/dist/session/exchange/exchange.d.ts +3 -2
- package/dist/session/exchange/exchange.js +10 -7
- package/dist/session/exchange/index.d.ts +1 -1
- package/dist/session/exchange/index.js +1 -1
- package/dist/session/exchange/presentation.js +28 -10
- package/dist/session/exchange/source.d.ts +7 -7
- package/dist/session/exchange/source.js +26 -27
- package/dist/session/index.d.ts +5 -4
- package/dist/session/index.js +0 -1
- package/dist/session/options.d.ts +4 -2
- package/dist/session/options.js +3 -3
- package/dist/session/reference.d.ts +27 -6
- package/dist/session/reference.js +18 -3
- package/dist/session/retry.d.ts +12 -0
- package/dist/session/retry.js +23 -0
- package/dist/session/routing/auth.d.ts +9 -3
- package/dist/session/routing/auth.js +4 -3
- package/dist/session/routing/cache.d.ts +12 -5
- package/dist/session/routing/cache.js +56 -48
- package/dist/session/routing/dispatch.d.ts +26 -3
- package/dist/session/routing/dispatch.js +112 -69
- package/dist/session/routing/envelope.d.ts +3 -3
- package/dist/session/routing/index.d.ts +1 -1
- package/dist/session/routing/legacy/release-route.d.ts +12 -0
- package/dist/session/routing/legacy/release-route.js +6 -0
- package/dist/session/routing/recovery.d.ts +3 -6
- package/dist/session/routing/recovery.js +3 -14
- package/dist/session/routing/request.d.ts +2 -1
- package/dist/session/routing/request.js +2 -1
- package/dist/session/routing/result.d.ts +1 -1
- package/dist/session/routing/result.js +5 -1
- package/dist/session/routing/store.js +4 -5
- package/dist/session/session.d.ts +31 -5
- package/dist/session/session.js +70 -22
- package/dist/session/session.typecheck.js +20 -6
- package/dist/session/views/index.d.ts +2 -2
- package/dist/session/views/index.js +2 -2
- package/dist/session/views/kernel.d.ts +31 -0
- package/dist/session/views/kernel.js +30 -0
- package/dist/session/views/legacy/catalog.d.ts +21 -0
- package/dist/session/views/{catalog.js → legacy/catalog.js} +7 -31
- package/dist/session/views/legacy/index.d.ts +14 -0
- package/dist/session/views/legacy/index.js +14 -0
- package/dist/session/views/legacy/resolve.d.ts +46 -0
- package/dist/session/views/legacy/resolve.js +83 -0
- package/dist/session/views/legacy/unplaced.d.ts +22 -0
- package/dist/session/views/legacy/unplaced.js +26 -0
- package/dist/session/views/read.d.ts +49 -0
- package/dist/session/views/read.js +148 -0
- package/dist/session/views/view.d.ts +48 -0
- package/dist/session/views/view.js +74 -0
- package/dist/store/memory.d.ts +1 -3
- package/dist/store/memory.js +61 -112
- package/dist/store/shape.d.ts +33 -12
- package/dist/store/shape.js +125 -16
- package/dist/store/store.d.ts +6 -6
- package/dist/store/store.js +1 -1
- package/dist/transport/auto/decision.d.ts +28 -14
- package/dist/transport/auto/decision.js +39 -32
- package/dist/transport/auto/fallback.d.ts +1 -1
- package/dist/transport/auto/fallback.js +5 -10
- package/dist/transport/auto/transport.d.ts +10 -3
- package/dist/transport/auto/transport.js +41 -32
- package/dist/transport/deadline.d.ts +2 -0
- package/dist/transport/deadline.js +18 -0
- package/dist/transport/failure.d.ts +28 -1
- package/dist/transport/failure.js +63 -1
- package/dist/transport/http/admission.js +8 -35
- package/dist/transport/http/binary-request.d.ts +44 -0
- package/dist/transport/http/binary-request.js +110 -0
- package/dist/transport/http/binary.js +3 -3
- package/dist/transport/http/byte-stream.d.ts +2 -1
- package/dist/transport/http/byte-stream.js +12 -8
- package/dist/transport/http/configuration.d.ts +7 -0
- package/dist/transport/http/configuration.js +2 -0
- package/dist/transport/http/index.d.ts +1 -1
- package/dist/transport/http/index.js +1 -1
- package/dist/transport/http/response.d.ts +13 -1
- package/dist/transport/http/response.js +22 -9
- package/dist/transport/http/stream.d.ts +8 -13
- package/dist/transport/http/stream.js +34 -81
- package/dist/transport/http/transport.d.ts +14 -1
- package/dist/transport/http/transport.js +110 -35
- package/dist/transport/http/unprocessed.d.ts +5 -0
- package/dist/transport/http/unprocessed.js +28 -0
- package/dist/transport/index.d.ts +2 -1
- package/dist/transport/index.js +2 -1
- package/dist/transport/level.d.ts +42 -0
- package/dist/transport/level.js +58 -0
- package/dist/transport/stream.d.ts +52 -0
- package/dist/transport/stream.js +101 -0
- package/dist/transport/transport.d.ts +33 -0
- package/dist/transport/unary.d.ts +9 -0
- package/dist/transport/unary.js +36 -0
- package/dist/transport/websocket/connection.d.ts +13 -4
- package/dist/transport/websocket/connection.js +123 -96
- package/dist/transport/websocket/exchange.d.ts +15 -19
- package/dist/transport/websocket/exchange.js +87 -183
- package/dist/transport/websocket/transport.d.ts +19 -1
- package/dist/transport/websocket/transport.js +50 -21
- package/package.json +9 -7
- package/dist/session/execution.js +0 -34
- package/dist/session/views/catalog.d.ts +0 -19
- package/dist/session/views/resolve.d.ts +0 -13
- package/dist/session/views/resolve.js +0 -21
|
@@ -1,105 +1,80 @@
|
|
|
1
1
|
import type { NodeId } from '@astrale-os/kernel-core/graph/node';
|
|
2
|
-
import type {
|
|
3
|
-
import type { AttemptReport
|
|
4
|
-
import type {
|
|
5
|
-
import type {
|
|
6
|
-
|
|
7
|
-
export type OperationId = installation.OperationId;
|
|
2
|
+
import type { OperationId } from '@astrale-os/kernel-core/schema/installation';
|
|
3
|
+
import type { AttemptReport as InstallAttemptReport, DomainRequest, InstallClass, InstallInput, InstallMode, InstallReceipt, SystemExecutionDetail as InstallDetail, UninstallInput, UninstallOutput as UninstallReceipt, ValidationOptions as InstallValidationOptions } from '@astrale-os/kernel-core/schema/kernel/syscalls/contracts';
|
|
4
|
+
import type { InstallResult } from '@astrale-os/kernel-protocol/schema/installation';
|
|
5
|
+
import type { ExecutionOutcome, ExecutionStatus } from '../execution/index.js';
|
|
6
|
+
export type { OperationId };
|
|
8
7
|
/** Canonical caller input accepted by the Kernel install syscall. */
|
|
9
|
-
export type DomainRequest
|
|
8
|
+
export type { DomainRequest };
|
|
10
9
|
/**
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
* so it is no part of the operation's intent.
|
|
10
|
+
* How long an install, an uninstall or a watch of an install waits at most, `waitMs`, in
|
|
11
|
+
* milliseconds: 110 s by default; `0` reads the status once and answers it. The wait is the
|
|
12
|
+
* Client's own: it is never sent, so it is no part of the operation's intent.
|
|
14
13
|
*/
|
|
15
|
-
export
|
|
16
|
-
readonly
|
|
17
|
-
}
|
|
14
|
+
export interface LifecycleWait {
|
|
15
|
+
readonly waitMs?: number;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* One install: its Kernel input, plus how long the Client waits for its outcome, or, in mode
|
|
19
|
+
* `maintenance`, until its repair session awaits Root's first command.
|
|
20
|
+
*/
|
|
21
|
+
export type InstallRequest = InstallInput & LifecycleWait;
|
|
18
22
|
/** Admitted terminal install receipt returned by the Kernel. */
|
|
19
|
-
export type InstallReceipt
|
|
20
|
-
/** The
|
|
21
|
-
export type
|
|
23
|
+
export type { InstallReceipt };
|
|
24
|
+
/** The committed result of an install: its receipt, or the generations it proved unchanged. */
|
|
25
|
+
export type { InstallResult };
|
|
22
26
|
/** What an install does to the stored data: nothing, applied at once, or revalidated first. */
|
|
23
|
-
export type InstallClass
|
|
24
|
-
export type InstallMode
|
|
27
|
+
export type { InstallClass };
|
|
28
|
+
export type { InstallMode };
|
|
25
29
|
/** The validation options of an install, defaults filled in. */
|
|
26
|
-
export type InstallValidationOptions
|
|
30
|
+
export type { InstallValidationOptions };
|
|
27
31
|
/** The last attempt of a repair session that ended without activating, with its report. */
|
|
28
|
-
export type InstallAttemptReport
|
|
32
|
+
export type { InstallAttemptReport };
|
|
29
33
|
/** What an install or session shows beside its engine state, as Core shapes it. */
|
|
30
|
-
export type InstallDetail
|
|
31
|
-
/** The public failure a rejected install ended with, such as `DATA_MIGRATION_REQUIRED`. */
|
|
32
|
-
export interface InstallFailure {
|
|
33
|
-
readonly code: string;
|
|
34
|
-
readonly message: string;
|
|
35
|
-
readonly family?: string;
|
|
36
|
-
readonly details?: Value;
|
|
37
|
-
}
|
|
34
|
+
export type { InstallDetail };
|
|
38
35
|
/** A terminal install: its committed result, its rejection, or its cancellation. */
|
|
39
|
-
export type InstallOutcome =
|
|
40
|
-
readonly kind: 'completed';
|
|
41
|
-
readonly value: protocolSchema.installation.InstallResult;
|
|
42
|
-
} | {
|
|
43
|
-
readonly kind: 'failed';
|
|
44
|
-
readonly error: InstallFailure;
|
|
45
|
-
} | {
|
|
46
|
-
readonly kind: 'cancelled';
|
|
47
|
-
};
|
|
36
|
+
export type InstallOutcome = ExecutionOutcome<InstallResult>;
|
|
48
37
|
/**
|
|
49
|
-
* The status of one install
|
|
50
|
-
*
|
|
51
|
-
*
|
|
38
|
+
* The status of one install or repair session: the engine `state` the CLI decides on, and the
|
|
39
|
+
* Core `detail` (phase, class, progress, the next command index, the running attempt and the last
|
|
40
|
+
* attempt report).
|
|
52
41
|
*/
|
|
53
|
-
export type InstallStatus
|
|
54
|
-
/** The status of an install, uninstall or session whose Execution node exists. */
|
|
55
|
-
export interface InstallNodeStatus<Outcome = InstallOutcome> {
|
|
56
|
-
readonly id: InstallExecutionId;
|
|
57
|
-
readonly function: NodeId;
|
|
58
|
-
readonly version: `sha256:${string}`;
|
|
59
|
-
readonly state: ExecutionState;
|
|
60
|
-
readonly createdAt: string;
|
|
61
|
-
readonly detail?: InstallDetail;
|
|
62
|
-
/** Present exactly once the Execution is terminal. */
|
|
63
|
-
readonly outcome?: Outcome;
|
|
64
|
-
}
|
|
42
|
+
export type InstallStatus = ExecutionStatus<InstallResult>;
|
|
65
43
|
/**
|
|
66
|
-
*
|
|
67
|
-
*
|
|
44
|
+
* How long a watch of an install lasts at most, and, for a repair session, the index the command
|
|
45
|
+
* it awaits must pass, `after` (`0` by default: any).
|
|
68
46
|
*/
|
|
69
|
-
export interface
|
|
70
|
-
readonly
|
|
71
|
-
readonly state: 'deleted';
|
|
72
|
-
readonly outcome: Outcome;
|
|
73
|
-
/** Absent: the node that recorded them is deleted. */
|
|
74
|
-
readonly function?: never;
|
|
75
|
-
readonly version?: never;
|
|
76
|
-
readonly createdAt?: never;
|
|
77
|
-
readonly detail?: never;
|
|
47
|
+
export interface InstallationWatch extends LifecycleWait {
|
|
48
|
+
readonly after?: number;
|
|
78
49
|
}
|
|
79
50
|
/** One admitted install answer: its Execution, its status, and its result once completed. */
|
|
80
51
|
export interface Installation {
|
|
81
|
-
readonly execution:
|
|
52
|
+
readonly execution: NodeId;
|
|
53
|
+
/**
|
|
54
|
+
* True when the operation id already named this Execution, so the call replayed it and changed
|
|
55
|
+
* nothing; false when this call started it; absent when the Host does not say.
|
|
56
|
+
*/
|
|
57
|
+
readonly replayed?: boolean;
|
|
82
58
|
readonly status: InstallStatus;
|
|
83
59
|
/** The committed result, present exactly when the status is completed. */
|
|
84
|
-
readonly result?:
|
|
60
|
+
readonly result?: InstallResult;
|
|
85
61
|
}
|
|
86
|
-
/**
|
|
87
|
-
export type UninstallRequest = UninstallInput;
|
|
62
|
+
/** One uninstall: its Kernel input, plus how long the Client waits for its outcome. */
|
|
63
|
+
export type UninstallRequest = UninstallInput & LifecycleWait;
|
|
88
64
|
/** Admitted terminal uninstall receipt returned by the Kernel. */
|
|
89
|
-
export type UninstallReceipt
|
|
65
|
+
export type { UninstallReceipt };
|
|
90
66
|
/** A terminal uninstall: its committed receipt, its rejection, or its cancellation. */
|
|
91
|
-
export type UninstallOutcome =
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
} | {
|
|
95
|
-
readonly kind: 'failed';
|
|
96
|
-
readonly error: InstallFailure;
|
|
97
|
-
} | {
|
|
98
|
-
readonly kind: 'cancelled';
|
|
99
|
-
};
|
|
67
|
+
export type UninstallOutcome = ExecutionOutcome<UninstallReceipt>;
|
|
68
|
+
/** The status of one uninstall. */
|
|
69
|
+
export type UninstallStatus = ExecutionStatus<UninstallReceipt>;
|
|
100
70
|
/** One admitted uninstall answer: its Execution, its status, and its receipt once completed. */
|
|
101
71
|
export interface Uninstallation {
|
|
102
|
-
readonly execution:
|
|
103
|
-
|
|
72
|
+
readonly execution: NodeId;
|
|
73
|
+
/**
|
|
74
|
+
* True when the operation id already named this Execution; false when this call started it;
|
|
75
|
+
* absent when the Host does not say.
|
|
76
|
+
*/
|
|
77
|
+
readonly replayed?: boolean;
|
|
78
|
+
readonly status: UninstallStatus;
|
|
104
79
|
readonly result?: UninstallReceipt;
|
|
105
80
|
}
|
package/dist/schema/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { createSchema,
|
|
1
|
+
export { createSchema, type SchemaApi, type SchemaCall, type SchemaOptions, type DomainBundle, type DomainDependencies, type DomainInfo, type InstalledPin, type InstalledRelease, } from './schema.js';
|
|
2
2
|
export { acceptOperationId, createOperationId } from './operation.js';
|
|
3
3
|
export type { InstallationApi, UninstallationApi } from './installation.js';
|
|
4
|
-
export type { DomainRequest, InstallAttemptReport, InstallClass, InstallDetail,
|
|
4
|
+
export type { DomainRequest, InstallAttemptReport, InstallClass, InstallDetail, InstallMode, InstallOutcome, InstallResult, InstallStatus, InstallValidationOptions, Installation, InstallationWatch, InstallReceipt, InstallRequest, LifecycleWait, OperationId, Uninstallation, UninstallOutcome, UninstallReceipt, UninstallRequest, UninstallStatus, } from './contracts.js';
|
package/dist/schema/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { createSchema,
|
|
1
|
+
export { createSchema, } from './schema.js';
|
|
2
2
|
export { acceptOperationId, createOperationId } from './operation.js';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { NodeId } from '@astrale-os/kernel-core/graph/node';
|
|
2
2
|
import type { InstallValidation } from '@astrale-os/kernel-core/schema/kernel/syscalls/contracts';
|
|
3
|
+
import type { ExecutionCall, ExecutionWait } from '../execution/index.js';
|
|
3
4
|
import type { RequestOptions } from '../transport/index.js';
|
|
4
|
-
import type {
|
|
5
|
-
import type { SchemaCall } from './schema.js';
|
|
5
|
+
import type { InstallationWatch, InstallOutcome, InstallStatus, LifecycleWait, UninstallOutcome, UninstallStatus } from './contracts.js';
|
|
6
6
|
/**
|
|
7
7
|
* The install executions of one Instance, through the `K.Execution` Methods of each. Observing
|
|
8
8
|
* and a cooperative cancel are Root's or the initiator's; signals, a forced cancel, resume and
|
|
@@ -10,16 +10,22 @@ import type { SchemaCall } from './schema.js';
|
|
|
10
10
|
*/
|
|
11
11
|
export interface InstallationApi {
|
|
12
12
|
/** The status of one install or repair session. */
|
|
13
|
-
status(execution:
|
|
14
|
-
/** The terminal outcome, waiting at most `waitMs
|
|
15
|
-
result(execution:
|
|
16
|
-
|
|
17
|
-
|
|
13
|
+
status(execution: NodeId, options?: RequestOptions): Promise<InstallStatus>;
|
|
14
|
+
/** The terminal outcome, waiting at most `waitMs` in total; `EXECUTION_PENDING` once it lapses. */
|
|
15
|
+
result(execution: NodeId, wait?: ExecutionWait, options?: RequestOptions): Promise<InstallOutcome>;
|
|
16
|
+
/**
|
|
17
|
+
* Read the status until the repair session awaits a command whose index passes `after`, or the
|
|
18
|
+
* install ends, pauses or expires, or `waitMs` lapses, or the deadline `timeoutMs` sets is within
|
|
19
|
+
* the answer margin (2 s), and answer the last status read. Each read
|
|
20
|
+
* follows the last one after a quarter of the time the watch has lasted, at most one second and
|
|
21
|
+
* never less than that read took: a change is seen within a quarter of the time it took to come.
|
|
22
|
+
*/
|
|
23
|
+
watch(execution: NodeId, watch?: InstallationWatch, options?: RequestOptions): Promise<InstallStatus>;
|
|
18
24
|
/**
|
|
19
25
|
* A waiting repair session attempts its target: the `command:<index>` signal, `index` being
|
|
20
26
|
* the `detail.command` its status announces. A signal already resolved is refused.
|
|
21
27
|
*/
|
|
22
|
-
apply(execution:
|
|
28
|
+
apply(execution: NodeId, command: {
|
|
23
29
|
readonly index: number;
|
|
24
30
|
readonly validation?: InstallValidation;
|
|
25
31
|
}, options?: RequestOptions): Promise<void>;
|
|
@@ -27,19 +33,22 @@ export interface InstallationApi {
|
|
|
27
33
|
* Stop the attempt a repair session runs, `detail.attempt.number`, through its `abort:<attempt>`
|
|
28
34
|
* signal; the session waits again.
|
|
29
35
|
*/
|
|
30
|
-
abort(execution:
|
|
36
|
+
abort(execution: NodeId, attempt: number, options?: RequestOptions): Promise<void>;
|
|
31
37
|
/**
|
|
32
38
|
* A cooperative cancel ends an install before its point of no return with nothing changed, and
|
|
33
|
-
* has a repair session attempt its source schema. `force` kills the run; a live session
|
|
34
|
-
*
|
|
39
|
+
* has a repair session attempt its source schema. `force` kills the run; a live session refuses
|
|
40
|
+
* it `EXECUTION_EXIT_REFUSED`: cancel it cooperatively or apply it.
|
|
35
41
|
*/
|
|
36
|
-
cancel(execution:
|
|
42
|
+
cancel(execution: NodeId, input?: {
|
|
37
43
|
readonly force?: boolean;
|
|
38
44
|
}, options?: RequestOptions): Promise<InstallStatus>;
|
|
39
45
|
/** Resume a paused install or session; a running one is unchanged. */
|
|
40
|
-
resume(execution:
|
|
41
|
-
/**
|
|
42
|
-
|
|
46
|
+
resume(execution: NodeId, options?: RequestOptions): Promise<InstallStatus>;
|
|
47
|
+
/**
|
|
48
|
+
* Delete the Execution, then kill and purge its run; a live session refuses it
|
|
49
|
+
* `EXECUTION_EXIT_REFUSED`: cancel or apply it first.
|
|
50
|
+
*/
|
|
51
|
+
delete(execution: NodeId, options?: RequestOptions): Promise<void>;
|
|
43
52
|
}
|
|
44
53
|
/**
|
|
45
54
|
* The uninstall executions of one Instance, through the same `K.Execution` Methods: a completed
|
|
@@ -47,58 +56,21 @@ export interface InstallationApi {
|
|
|
47
56
|
*/
|
|
48
57
|
export interface UninstallationApi {
|
|
49
58
|
/** The status of one uninstall. */
|
|
50
|
-
status(execution:
|
|
51
|
-
/** The terminal outcome, waiting at most `waitMs
|
|
52
|
-
result(execution:
|
|
53
|
-
readonly waitMs?: number;
|
|
54
|
-
}, options?: RequestOptions): Promise<UninstallOutcome>;
|
|
59
|
+
status(execution: NodeId, options?: RequestOptions): Promise<UninstallStatus>;
|
|
60
|
+
/** The terminal outcome, waiting at most `waitMs` in total; `EXECUTION_PENDING` once it lapses. */
|
|
61
|
+
result(execution: NodeId, wait?: ExecutionWait, options?: RequestOptions): Promise<UninstallOutcome>;
|
|
55
62
|
/** A cooperative cancel ends it before its point of no return; `force` kills the run. */
|
|
56
|
-
cancel(execution:
|
|
63
|
+
cancel(execution: NodeId, input?: {
|
|
57
64
|
readonly force?: boolean;
|
|
58
|
-
}, options?: RequestOptions): Promise<
|
|
65
|
+
}, options?: RequestOptions): Promise<UninstallStatus>;
|
|
59
66
|
/** Resume a paused uninstall; a running one is unchanged. */
|
|
60
|
-
resume(execution:
|
|
67
|
+
resume(execution: NodeId, options?: RequestOptions): Promise<UninstallStatus>;
|
|
61
68
|
/** Delete the Execution, then kill and purge its run. */
|
|
62
|
-
delete(execution:
|
|
69
|
+
delete(execution: NodeId, options?: RequestOptions): Promise<void>;
|
|
63
70
|
}
|
|
64
|
-
/** Admit a completed outcome's value; anything else of the outcome is kept as admitted. */
|
|
65
|
-
export type AcceptValue<Value> = (input: unknown) => Value;
|
|
66
|
-
export type ExecutionOutcomeOf<Value> = {
|
|
67
|
-
readonly kind: 'completed';
|
|
68
|
-
readonly value: Value;
|
|
69
|
-
} | {
|
|
70
|
-
readonly kind: 'failed';
|
|
71
|
-
readonly error: InstallFailure;
|
|
72
|
-
} | {
|
|
73
|
-
readonly kind: 'cancelled';
|
|
74
|
-
};
|
|
75
|
-
/** The `K.Execution` Methods of one Execution, over one call capability; package-private. */
|
|
76
|
-
export declare function executionMethods(call: SchemaCall, options: (input: RequestOptions | undefined) => RequestOptions): Readonly<{
|
|
77
|
-
status: <Value>(id: InstallExecutionId, accept: AcceptValue<Value>, request?: RequestOptions) => Promise<InstallStatus<ExecutionOutcomeOf<Value>>>;
|
|
78
|
-
result<Value>(id: InstallExecutionId, accept: AcceptValue<Value>, wait?: {
|
|
79
|
-
readonly waitMs?: number;
|
|
80
|
-
}, request?: RequestOptions): Promise<ExecutionOutcomeOf<Value>>;
|
|
81
|
-
signal(id: InstallExecutionId, name: string, signalled: unknown, request?: RequestOptions): Promise<void>;
|
|
82
|
-
cancel: <Value>(id: InstallExecutionId, accept: AcceptValue<Value>, input: {
|
|
83
|
-
readonly force?: boolean;
|
|
84
|
-
}, request?: RequestOptions) => Promise<InstallStatus<ExecutionOutcomeOf<Value>>>;
|
|
85
|
-
resume: <Value>(id: InstallExecutionId, accept: AcceptValue<Value>, request?: RequestOptions) => Promise<InstallStatus<ExecutionOutcomeOf<Value>>>;
|
|
86
|
-
delete(id: InstallExecutionId, request?: RequestOptions): Promise<void>;
|
|
87
|
-
/** Admit what a durable call answers at once: the Execution it created or recovered. */
|
|
88
|
-
start(path: PathLike, input: unknown, request?: RequestOptions): Promise<InstallExecutionId>;
|
|
89
|
-
/**
|
|
90
|
-
* Wait within the request deadline for the outcome. A wait that lapsed after waiting, while
|
|
91
|
-
* time remains, waits again; a wait a closing process or a gap with no process failed is sent
|
|
92
|
-
* again. Every other end of the wait, or its deadline, leaves the Execution as it is: its
|
|
93
|
-
* status, read next, says where it is, so the caller never loses the Execution.
|
|
94
|
-
*/
|
|
95
|
-
settle(id: InstallExecutionId, request?: RequestOptions): Promise<void>;
|
|
96
|
-
/** The status after a wait, read again as `settle` sends its wait again, within the deadline. */
|
|
97
|
-
observe<Value>(id: InstallExecutionId, accept: AcceptValue<Value>, request?: RequestOptions): Promise<InstallStatus<ExecutionOutcomeOf<Value>>>;
|
|
98
|
-
}>;
|
|
99
|
-
export type ExecutionMethods = ReturnType<typeof executionMethods>;
|
|
100
71
|
/** The install Methods: a completed outcome carries the result its Protocol owner admits. */
|
|
101
|
-
export declare function createInstallation(
|
|
72
|
+
export declare function createInstallation(call: ExecutionCall): InstallationApi;
|
|
102
73
|
/** The uninstall Methods: a completed outcome carries the receipt Core's contract admits. */
|
|
103
|
-
export declare function createUninstallation(
|
|
104
|
-
|
|
74
|
+
export declare function createUninstallation(call: ExecutionCall): UninstallationApi;
|
|
75
|
+
/** The wait `wait` asks for, in milliseconds: its `waitMs`, or the default. */
|
|
76
|
+
export declare function lifecycleWait(wait: LifecycleWait | undefined): number;
|
|
@@ -1,142 +1,78 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Path } from '@astrale-os/kernel-core/path';
|
|
3
|
-
import { abortSignal, commandSignal, executionOutcome, executionRef, executionStatus, uninstallOutput, } from '@astrale-os/kernel-core/schema/kernel/syscalls/contracts';
|
|
4
|
-
import { execution as methods } from '@astrale-os/kernel-core/schema/kernel/syscalls/references';
|
|
5
|
-
import { MethodKey } from '@astrale-os/kernel-dsl/v1/addressing';
|
|
1
|
+
import { abortSignal, commandSignal, uninstallOutput, } from '@astrale-os/kernel-core/schema/kernel/syscalls/contracts';
|
|
6
2
|
import * as protocolSchema from '@astrale-os/kernel-protocol/schema';
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
/**
|
|
12
|
-
const
|
|
13
|
-
/** A pending answer sooner than this did not wait: the Kernel answers now, so waiting ends. */
|
|
14
|
-
const LAPSED_WAIT_MS = 1_000;
|
|
15
|
-
/** No wait starts with less time left than this before its deadline. */
|
|
16
|
-
const MINIMUM_WAIT_MS = 1_000;
|
|
17
|
-
/** The `K.Execution` Methods of one Execution, over one call capability; package-private. */
|
|
18
|
-
export function executionMethods(call, options) {
|
|
19
|
-
const value = async (id, method, input, request) => {
|
|
20
|
-
const target = Path.instanceMethod(Path.id(id), MethodKey.of(method.owner, method.name));
|
|
21
|
-
const result = await call(invocation(target, input), options(request));
|
|
22
|
-
if (result.kind !== 'value')
|
|
23
|
-
throw new TypeError('Execution Method returned a non-value result.');
|
|
24
|
-
return result.value;
|
|
25
|
-
};
|
|
26
|
-
/**
|
|
27
|
-
* An Execution read has no effect: one a process refused with a retry delay, or a gap with no
|
|
28
|
-
* process on the port failed, is sent again through the pacer, each attempt within `deadline`.
|
|
29
|
-
*/
|
|
30
|
-
const read = (deadline, request, work) => retry(() => work({ ...request, timeoutMs: Math.max(1, deadline - Date.now()) }), {
|
|
31
|
-
maxAttempts: READ_ATTEMPTS,
|
|
32
|
-
shouldRetry: (error, attempt) => Date.now() < deadline &&
|
|
33
|
-
(error instanceof TransportError || RETRY_REFUSALS.shouldRetry(error, attempt)),
|
|
34
|
-
retryAfter: RETRY_REFUSALS.retryAfter,
|
|
35
|
-
});
|
|
36
|
-
const status = async (id, accept, answer) => {
|
|
37
|
-
const admitted = acceptOutput(executionStatus, await answer, 'Execution status');
|
|
38
|
-
if (admitted.id !== id)
|
|
39
|
-
throw new TypeError('Kernel returned the status of another Execution.');
|
|
40
|
-
const outcome = admitted.outcome === undefined ? undefined : outcomeOf(admitted.outcome, accept);
|
|
41
|
-
// A deleted Execution carries the outcome its lifecycle record keeps, whatever its kind.
|
|
42
|
-
if (admitted.state !== 'deleted' &&
|
|
43
|
-
(admitted.state === 'completed') !== (outcome?.kind === 'completed')) {
|
|
44
|
-
throw new TypeError('Execution status and outcome disagree.');
|
|
45
|
-
}
|
|
46
|
-
if (admitted.state === 'deleted')
|
|
47
|
-
return Object.freeze({ id, state: 'deleted', outcome: outcome });
|
|
48
|
-
const { outcome: _outcome, ...rest } = admitted;
|
|
49
|
-
return Object.freeze({ ...rest, ...(outcome === undefined ? {} : { outcome }) });
|
|
50
|
-
};
|
|
51
|
-
return Object.freeze({
|
|
52
|
-
status: (id, accept, request) => status(id, accept, value(id, methods.status, {}, request)),
|
|
53
|
-
async result(id, accept, wait = {}, request) {
|
|
54
|
-
const answer = await value(id, methods.result, { ...wait }, request);
|
|
55
|
-
return outcomeOf(acceptOutput(executionOutcome, answer, 'Execution outcome'), accept);
|
|
56
|
-
},
|
|
57
|
-
async signal(id, name, signalled, request) {
|
|
58
|
-
await value(id, methods.signal, { name, value: signalled }, request);
|
|
59
|
-
},
|
|
60
|
-
cancel: (id, accept, input, request) => status(id, accept, value(id, methods.cancel, { ...input }, request)),
|
|
61
|
-
resume: (id, accept, request) => status(id, accept, value(id, methods.resume, {}, request)),
|
|
62
|
-
async delete(id, request) {
|
|
63
|
-
await value(id, methods.delete, {}, request);
|
|
64
|
-
},
|
|
65
|
-
/** Admit what a durable call answers at once: the Execution it created or recovered. */
|
|
66
|
-
async start(path, input, request) {
|
|
67
|
-
const result = await call(invocation(path, input), options(request));
|
|
68
|
-
if (result.kind !== 'value')
|
|
69
|
-
throw new TypeError('Schema syscall returned a non-value result.');
|
|
70
|
-
const ref = acceptOutput(executionRef, result.value, 'Execution reference');
|
|
71
|
-
return NodeId(ref.id);
|
|
72
|
-
},
|
|
73
|
-
/**
|
|
74
|
-
* Wait within the request deadline for the outcome. A wait that lapsed after waiting, while
|
|
75
|
-
* time remains, waits again; a wait a closing process or a gap with no process failed is sent
|
|
76
|
-
* again. Every other end of the wait, or its deadline, leaves the Execution as it is: its
|
|
77
|
-
* status, read next, says where it is, so the caller never loses the Execution.
|
|
78
|
-
*/
|
|
79
|
-
async settle(id, request) {
|
|
80
|
-
const deadline = Date.now() + (options(request).timeoutMs ?? 0);
|
|
81
|
-
while (deadline - Date.now() >= MINIMUM_WAIT_MS) {
|
|
82
|
-
const started = Date.now();
|
|
83
|
-
try {
|
|
84
|
-
await read(deadline, request, (attempt) => value(id, methods.result, { waitMs: attempt.timeoutMs }, attempt));
|
|
85
|
-
return;
|
|
86
|
-
}
|
|
87
|
-
catch (error) {
|
|
88
|
-
const pending = error instanceof ResponseError && error.reason?.code === 'EXECUTION_PENDING';
|
|
89
|
-
if (!pending || Date.now() - started < LAPSED_WAIT_MS)
|
|
90
|
-
return;
|
|
91
|
-
}
|
|
92
|
-
}
|
|
93
|
-
},
|
|
94
|
-
/** The status after a wait, read again as `settle` sends its wait again, within the deadline. */
|
|
95
|
-
observe(id, accept, request) {
|
|
96
|
-
const deadline = Date.now() + (options(request).timeoutMs ?? 0);
|
|
97
|
-
return read(deadline, request, (attempt) => status(id, accept, value(id, methods.status, {}, attempt)));
|
|
98
|
-
},
|
|
99
|
-
});
|
|
100
|
-
}
|
|
3
|
+
import { acceptOutput, acceptWait, deadlineOf, executionMethods, waitEnd, within, } from '../execution/index.js';
|
|
4
|
+
import { pause } from '../transport/index.js';
|
|
5
|
+
/** How long an install or uninstall waits for what it waits for unless its request says otherwise. */
|
|
6
|
+
const DEFAULT_LIFECYCLE_WAIT_MS = 110_000;
|
|
7
|
+
/** The longest pause between two reads of a watch: a long watch reads once a second. */
|
|
8
|
+
const WATCH_PAUSE_MS = 1_000;
|
|
101
9
|
/** The install Methods: a completed outcome carries the result its Protocol owner admits. */
|
|
102
|
-
export function createInstallation(
|
|
103
|
-
const
|
|
104
|
-
if (uninstallOutput.safeParse(input).success) {
|
|
105
|
-
throw new TypeError('The Execution is an uninstall: read it through SchemaApi.uninstallation.');
|
|
106
|
-
}
|
|
107
|
-
return protocolSchema.installation.acceptResult(input);
|
|
108
|
-
};
|
|
10
|
+
export function createInstallation(call) {
|
|
11
|
+
const { signal, ...methods } = executionMethods(call, acceptInstallResult);
|
|
109
12
|
return Object.freeze({
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
apply: async (execution, command,
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
13
|
+
...methods,
|
|
14
|
+
watch: (execution, watch, options) => watchInstall(methods.status, execution, watch, options),
|
|
15
|
+
apply: async (execution, command, options) => signal(execution, {
|
|
16
|
+
name: commandSignal(ordinal(command.index)),
|
|
17
|
+
value: Object.freeze({
|
|
18
|
+
kind: 'apply',
|
|
19
|
+
...(command.validation === undefined ? {} : { validation: command.validation }),
|
|
20
|
+
}),
|
|
21
|
+
}, options),
|
|
22
|
+
abort: async (execution, attempt, options) => signal(execution, { name: abortSignal(ordinal(attempt)), value: Object.freeze({ kind: 'abort' }) }, options),
|
|
120
23
|
});
|
|
121
24
|
}
|
|
122
25
|
/** The uninstall Methods: a completed outcome carries the receipt Core's contract admits. */
|
|
123
|
-
export function createUninstallation(
|
|
124
|
-
const
|
|
125
|
-
return Object.freeze(
|
|
126
|
-
status: (execution, request) => executions.status(execution, accept, request),
|
|
127
|
-
result: (execution, wait, request) => executions.result(execution, accept, wait, request),
|
|
128
|
-
cancel: (execution, input = {}, request) => executions.cancel(execution, accept, input, request),
|
|
129
|
-
resume: (execution, request) => executions.resume(execution, accept, request),
|
|
130
|
-
delete: (execution, request) => executions.delete(execution, request),
|
|
131
|
-
});
|
|
26
|
+
export function createUninstallation(call) {
|
|
27
|
+
const { signal: _signal, ...methods } = executionMethods(call, acceptUninstallReceipt);
|
|
28
|
+
return Object.freeze(methods);
|
|
132
29
|
}
|
|
133
|
-
|
|
134
|
-
|
|
30
|
+
/** The watch `InstallationApi.watch` describes, over the `status` Method. */
|
|
31
|
+
async function watchInstall(status, execution, watch, options) {
|
|
32
|
+
const waitMs = lifecycleWait(watch);
|
|
33
|
+
const after = watch?.after ?? 0;
|
|
34
|
+
if (!Number.isSafeInteger(after) || after < 0) {
|
|
35
|
+
throw new TypeError('A watched command index is a nonnegative integer.');
|
|
36
|
+
}
|
|
37
|
+
const deadline = deadlineOf(options);
|
|
38
|
+
const started = Date.now();
|
|
39
|
+
// Each read after the first has the answer margin left before the call's deadline to come back.
|
|
40
|
+
const ends = waitEnd(deadline, waitMs);
|
|
41
|
+
for (;;) {
|
|
42
|
+
const read = Date.now();
|
|
43
|
+
const current = await status(execution, within(deadline, options));
|
|
44
|
+
const now = Date.now();
|
|
45
|
+
if (settled(current, after) || now >= ends)
|
|
46
|
+
return current;
|
|
47
|
+
// In whole milliseconds, a timer's own resolution: an instant read never reads again at once.
|
|
48
|
+
await pause(Math.min(WATCH_PAUSE_MS, Math.max(1, now - read, Math.ceil((now - started) / 4)), ends - now), options?.signal);
|
|
49
|
+
// A read starts by the end of the watch at the latest: a timer that woke past it reads no more.
|
|
50
|
+
if (Date.now() > ends)
|
|
51
|
+
return current;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* Whether a watch ends at `status`: its session awaits a command past `after`, or nothing changes
|
|
56
|
+
* it any more without a command: it ended, paused or expired.
|
|
57
|
+
*/
|
|
58
|
+
function settled(status, after) {
|
|
59
|
+
if (status.outcome !== undefined || status.state === 'paused' || status.state === 'expired')
|
|
60
|
+
return true;
|
|
61
|
+
const detail = status.detail;
|
|
62
|
+
return detail?.phase === 'awaiting' && (detail.command ?? 0) > after;
|
|
63
|
+
}
|
|
64
|
+
/** The wait `wait` asks for, in milliseconds: its `waitMs`, or the default. */
|
|
65
|
+
export function lifecycleWait(wait) {
|
|
66
|
+
return acceptWait({ waitMs: wait?.waitMs ?? DEFAULT_LIFECYCLE_WAIT_MS });
|
|
135
67
|
}
|
|
136
|
-
function
|
|
137
|
-
if (
|
|
138
|
-
|
|
139
|
-
|
|
68
|
+
function acceptInstallResult(input) {
|
|
69
|
+
if (uninstallOutput.safeParse(input).success) {
|
|
70
|
+
throw new TypeError('The Execution is an uninstall: read it through SchemaApi.uninstallation.');
|
|
71
|
+
}
|
|
72
|
+
return protocolSchema.installation.acceptResult(input);
|
|
73
|
+
}
|
|
74
|
+
function acceptUninstallReceipt(input) {
|
|
75
|
+
return acceptOutput(uninstallOutput, input, 'uninstall receipt');
|
|
140
76
|
}
|
|
141
77
|
function ordinal(input) {
|
|
142
78
|
if (!Number.isSafeInteger(input) || input < 1) {
|
package/dist/schema/schema.d.ts
CHANGED
|
@@ -1,32 +1,27 @@
|
|
|
1
1
|
import type { Key } from '@astrale-os/kernel-dsl/v1';
|
|
2
|
-
import
|
|
2
|
+
import type { DomainBundle, DomainDependencies, DomainInfo, InstalledPin, InstalledRelease, Limits } from '@astrale-os/kernel-protocol/schema/installation/introspection';
|
|
3
3
|
import type { Call, Result } from '../client/index.js';
|
|
4
4
|
import type { RequestOptions } from '../transport/index.js';
|
|
5
5
|
import type { Installation, InstallRequest, Uninstallation, UninstallRequest } from './contracts.js';
|
|
6
6
|
import { type InstallationApi, type UninstallationApi } from './installation.js';
|
|
7
7
|
export type SchemaCall = (call: Call, options?: RequestOptions) => Promise<Result>;
|
|
8
|
-
export interface SchemaOptions extends
|
|
9
|
-
readonly lifecycleTimeoutMs?: number;
|
|
8
|
+
export interface SchemaOptions extends Limits {
|
|
10
9
|
}
|
|
11
|
-
export type DomainInfo
|
|
12
|
-
export type DomainBundle = protocolSchema.installation.introspection.DomainBundle;
|
|
13
|
-
export type DomainDependencies = protocolSchema.installation.introspection.DomainDependencies;
|
|
14
|
-
export type InstalledRelease = protocolSchema.installation.introspection.InstalledRelease;
|
|
15
|
-
export type InstalledPin = protocolSchema.installation.introspection.InstalledPin;
|
|
16
|
-
export type InstallResult = protocolSchema.installation.InstallResult;
|
|
10
|
+
export type { DomainBundle, DomainDependencies, DomainInfo, InstalledPin, InstalledRelease };
|
|
17
11
|
export interface SchemaApi {
|
|
18
12
|
/**
|
|
19
|
-
* Install Domains: start the durable Execution the install is,
|
|
20
|
-
*
|
|
21
|
-
*
|
|
22
|
-
*
|
|
13
|
+
* Install Domains: start the durable Execution the install is, wait at most `waitMs` (110 s by
|
|
14
|
+
* default) for its outcome, or, in mode `maintenance`, until its repair session awaits Root's
|
|
15
|
+
* first command (`installation.watch`), and answer its status. `timeoutMs`, when given, bounds the
|
|
16
|
+
* whole call. The answer names the Execution with its status; `result` is present once it
|
|
17
|
+
* completed. A rejected install is a terminal `failed` status, never a failed call.
|
|
23
18
|
*/
|
|
24
19
|
install(request: InstallRequest, options?: RequestOptions): Promise<Installation>;
|
|
25
20
|
/** The install executions and repair sessions, through their `K.Execution` Methods. */
|
|
26
21
|
readonly installation: InstallationApi;
|
|
27
22
|
/**
|
|
28
|
-
* Uninstall Domains: start the durable Execution the uninstall is
|
|
29
|
-
*
|
|
23
|
+
* Uninstall Domains: start the durable Execution the uninstall is, wait at most `waitMs` (110 s
|
|
24
|
+
* by default) for its outcome and read its status. `result` is the receipt once it completed.
|
|
30
25
|
*/
|
|
31
26
|
uninstall(request: UninstallRequest, options?: RequestOptions): Promise<Uninstallation>;
|
|
32
27
|
/** The uninstall executions, through their `K.Execution` Methods. */
|
|
@@ -36,6 +31,5 @@ export interface SchemaApi {
|
|
|
36
31
|
dependencies(origin: Key.Origin, options?: RequestOptions): Promise<DomainDependencies>;
|
|
37
32
|
installed(options?: RequestOptions): Promise<readonly InstalledRelease[]>;
|
|
38
33
|
}
|
|
39
|
-
export declare const DEFAULT_SCHEMA_LIFECYCLE_TIMEOUT_MS = 110000;
|
|
40
34
|
/** Bind the canonical Schema lifecycle syscalls to one caller-scoped value-call capability. */
|
|
41
35
|
export declare function createSchema(call: SchemaCall, limits: SchemaOptions): SchemaApi;
|