@descryy/runtime-orchestrator 0.0.1 → 0.2.0

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.
@@ -85,7 +85,7 @@ export interface AttachToRunningJvmProcessOptions {
85
85
  *
86
86
  * ## Why the attach path needed this too, and why it went unnoticed
87
87
  *
88
- * `JvmRuntimeAdapterOptions.sourceRoots` (`@descryhq-wq/runtime-adapter-jvm`)
88
+ * `JvmRuntimeAdapterOptions.sourceRoots` (`@descryy/runtime-adapter-jvm`)
89
89
  * already fixed this for evidence produced by `createJvmStackTraceParser`
90
90
  * — the JVM prints a bare basename (`ProbeApplication.java`), never a
91
91
  * path, so `resolveSymbolNode` correctly refuses to match on it alone
@@ -101,10 +101,10 @@ export interface AttachToRunningJvmProcessOptions {
101
101
  * ## Reimplemented here, not imported — a deliberate, disclosed duplication
102
102
  *
103
103
  * `packages/orchestrator`'s own `src/` has never taken a real dependency
104
- * on any `@descryhq-wq/runtime-adapter-*` package — only
104
+ * on any `@descryy/runtime-adapter-*` package — only
105
105
  * `@descryy/runtime-adapter-typescript` is one, for an unrelated
106
106
  * default-path reason, and every other language adapter (including
107
- * `@descryhq-wq/runtime-adapter-jvm`) is a devDependency used solely by this
107
+ * `@descryy/runtime-adapter-jvm`) is a devDependency used solely by this
108
108
  * package's own tests. Importing the JVM-specific reconstruction function
109
109
  * into this language-agnostic-by-convention module would be a bigger
110
110
  * architectural change than this gap warrants, so
@@ -45,6 +45,25 @@ export interface AttachToRunningProcessOptions {
45
45
  readonly pid: number;
46
46
  /** Path to a file the target process is already writing its stdout/stderr to. Read in full on every poll — same growing-buffer contract `ManagedProcess.readOutput()` has, not a delta. */
47
47
  readonly logFilePath: string;
48
+ /**
49
+ * True once the caller's observation window has closed. Required, and the
50
+ * reason it is not optional is the bug it was added to fix.
51
+ *
52
+ * A source over an attached target has two independent reasons to end: the
53
+ * target exited, or the caller stopped watching. The liveness check covers
54
+ * only the first, and for a healthy attached service it is never true — so
55
+ * with no second signal the source polls a live buffer forever. Two things
56
+ * follow, and the second is the worse: the final line held in the splitter
57
+ * for want of a newline is never flushed, and a consumer that stops
58
+ * iterating never gets its generator back.
59
+ *
60
+ * The spawn path has always had this signal (`instrumented-execution.ts`
61
+ * flips a `finished` flag immediately before `collector.stop()`, with an
62
+ * ordering comment explaining that stop() would otherwise wait forever).
63
+ * This is the same signal, and defaulting it to "never stops" would leave
64
+ * both failures reachable by simply not passing it.
65
+ */
66
+ readonly stopObserving: () => boolean;
48
67
  readonly pollIntervalMs?: number;
49
68
  }
50
69
  /**
@@ -65,6 +84,11 @@ export declare function isProcessAlive(pid: number): boolean;
65
84
  * "already running before we attached" evidence this is for), followed by
66
85
  * whatever the target writes afterward — indistinguishable, once attached,
67
86
  * from `execute`'s own live tail.
87
+ *
88
+ * **Ending.** The source ends when the caller's window closes or the target
89
+ * exits, whichever comes first — see `stopObserving`. Both halves are needed:
90
+ * the liveness check alone never fires for a healthy target, and the window
91
+ * signal alone would poll a dead one until the caller noticed.
68
92
  */
69
93
  export declare function attachToRunningProcess(options: AttachToRunningProcessOptions): ProcessOutputSource;
70
94
  //# sourceMappingURL=attach-to-running-process.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"attach-to-running-process.d.ts","sourceRoot":"","sources":["../src/attach-to-running-process.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AAIH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,sCAAsC,CAAC;AAIhF,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,2HAA2H;IAC3H,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,2LAA2L;IAC3L,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,cAAc,CAAC,EAAE,MAAM,CAAC;CAClC;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAOnD;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,6BAA6B,GAAG,mBAAmB,CAuBlG"}
1
+ {"version":3,"file":"attach-to-running-process.d.ts","sourceRoot":"","sources":["../src/attach-to-running-process.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AAIH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,sCAAsC,CAAC;AAIhF,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,2HAA2H;IAC3H,QAAQ,CAAC,GAAG,EAAE,MAAM,CAAC;IACrB,2LAA2L;IAC3L,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B;;;;;;;;;;;;;;;;;OAiBG;IACH,QAAQ,CAAC,aAAa,EAAE,MAAM,OAAO,CAAC;IACtC,QAAQ,CAAC,cAAc,CAAC,EAAE,MAAM,CAAC;CAClC;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAOnD;AAED;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,6BAA6B,GAAG,mBAAmB,CA0BlG"}
@@ -66,6 +66,11 @@ export function isProcessAlive(pid) {
66
66
  * "already running before we attached" evidence this is for), followed by
67
67
  * whatever the target writes afterward — indistinguishable, once attached,
68
68
  * from `execute`'s own live tail.
69
+ *
70
+ * **Ending.** The source ends when the caller's window closes or the target
71
+ * exits, whichever comes first — see `stopObserving`. Both halves are needed:
72
+ * the liveness check alone never fires for a healthy target, and the window
73
+ * signal alone would poll a dead one until the caller noticed.
69
74
  */
70
75
  export function attachToRunningProcess(options) {
71
76
  if (!isProcessAlive(options.pid)) {
@@ -83,7 +88,10 @@ export function attachToRunningProcess(options) {
83
88
  throw new Error(`attachToRunningProcess: could not read log file "${options.logFilePath}" for pid ${options.pid}: ${detail}`);
84
89
  }
85
90
  },
86
- isFinished: () => !isProcessAlive(options.pid),
91
+ // A disjunction, not a replacement: either reason genuinely ends the
92
+ // source, and dropping the liveness half would leave a target that dies
93
+ // mid-window polled until the caller happened to notice.
94
+ isFinished: () => options.stopObserving() || !isProcessAlive(options.pid),
87
95
  ...(options.pollIntervalMs !== undefined ? { pollIntervalMs: options.pollIntervalMs } : {}),
88
96
  });
89
97
  }
@@ -1 +1 @@
1
- {"version":3,"file":"attach-to-running-process.js","sourceRoot":"","sources":["../src/attach-to-running-process.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCG;AAEH,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAIvC,OAAO,EAAE,gCAAgC,EAAE,MAAM,4BAA4B,CAAC;AAW9E;;;;;GAKG;AACH,MAAM,UAAU,cAAc,CAAC,GAAW;IACxC,IAAI,CAAC;QACH,OAAO,CAAC,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC;QACrB,OAAO,IAAI,CAAC;IACd,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAQ,KAA+B,CAAC,IAAI,KAAK,OAAO,CAAC;IAC3D,CAAC;AACH,CAAC;AAED;;;;;;;;;;;GAWG;AACH,MAAM,UAAU,sBAAsB,CAAC,OAAsC;IAC3E,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE,CAAC;QACjC,MAAM,IAAI,KAAK,CACb,+BAA+B,OAAO,CAAC,GAAG,SAAS,OAAO,CAAC,SAAS,qCAAqC;YACvG,6FAA6F,CAChG,CAAC;IACJ,CAAC;IAED,OAAO,gCAAgC,CAAC;QACtC,SAAS,EAAE,OAAO,CAAC,SAAS;QAC5B,UAAU,EAAE,GAAG,EAAE;YACf,IAAI,CAAC;gBACH,OAAO,YAAY,CAAC,OAAO,C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QACjC,MAAM,IAAI,KAAK,CACb,+BAA+B,OAAO,CAAC,GAAG,SAAS,OAAO,CAAC,SAAS,qCAAqC;YACvG,6FAA6F,CAChG,CAAC;IACJ,CAAC;IAED,OAAO,gCAAgC,CAAC;QACtC,SAAS,EAAE,OAAO,CAAC,SAAS;QAC5B,UAAU,EAAE,GAAG,EAAE;YACf,IAAI,CAAC;gBACH,OAAO,YAAY,CAAC,OAAO,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC;YACnD,CAAC;YAAC,OAAO,KAAK,EAAE,CAAC;gBACf,MAAM,MAAM,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;gBACtE,MAAM,IAAI,KAAK,CACb,oDAAoD,OAAO,CAAC,WAAW,aAAa,OAAO,CAAC,GAAG,KAAK,MAAM,EAAE,CAC7G,CAAC;YACJ,CAAC;QACH,CAAC;QACD,qEAAqE;QACrE,wEAAwE;QACxE,yDAAyD;QACzD,UAAU,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,aAAa,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,GAAG,CAAC;QACzE,GAAG,CAAC,OAAO,CAAC,cAAc,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,cAAc,EAAE,OAAO,CAAC,cAAc,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KAC5F,CAAC,CAAC;AACL,CAAC"}
package/dist/index.d.ts CHANGED
@@ -12,8 +12,8 @@ export type { RespawnCommand, RespawnCommandSource, RespawnAndSuperviseOptions,
12
12
  export { respawnAndSupervise, inferRespawnCommandFromProc } from "./respawn-and-supervise.ts";
13
13
  export type { CgroupResourceLimits, CgroupMoveResult, } from "./cgroup-partial-restriction.ts";
14
14
  export { CGROUP_PARTIAL_RESTRICTION_SCOPE, cgroupV2Capability, findDelegatedCgroupAncestor, moveProcessIntoRestrictedCgroup, } from "./cgroup-partial-restriction.ts";
15
- export type { InstrumentedExecutionInput, InstrumentedExecutionResult } from "./instrumented-execution.ts";
16
- export { runInstrumentedExecution, createSourceRootResolver } from "./instrumented-execution.ts";
15
+ export type { InstrumentedExecutionInput, InstrumentedExecutionResult, ExecutionBudgetOutcome } from "./instrumented-execution.ts";
16
+ export { runInstrumentedExecution, createSourceRootResolver, applyOutboundLaunch } from "./instrumented-execution.ts";
17
17
  export type { BackendObservationMechanism, RunRemoteLogObservationInput, RunRemoteLogObservationResult, } from "./profile-backend-observation.ts";
18
18
  export { backendObservationMechanismFor, runRemoteLogObservation } from "./profile-backend-observation.ts";
19
19
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,iCAAiC,EAAE,MAAM,4BAA4B,CAAC;AACpF,OAAO,EAAE,gCAAgC,EAAE,MAAM,4BAA4B,CAAC;AAC9E,YAAY,EAAE,6BAA6B,EAAE,MAAM,gCAAgC,CAAC;AACpF,OAAO,EAAE,sBAAsB,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AACxF,YAAY,EAAE,iCAAiC,EAAE,MAAM,qCAAqC,CAAC;AAC7F,OAAO,EAAE,0BAA0B,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAC3G,YAAY,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,YAAY,EAAE,gCAAgC,EAAE,MAAM,oCAAoC,CAAC;AAC3F,OAAO,EAAE,yBAAyB,EAAE,MAAM,oCAAoC,CAAC;AAC/E,YAAY,EACV,cAAc,EACd,oBAAoB,EACpB,0BAA0B,EAC1B,yBAAyB,GAC1B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,mBAAmB,EAAE,2BAA2B,EAAE,MAAM,4BAA4B,CAAC;AAC9F,YAAY,EAC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AAY,EACV,oBAAoB,EACpB,gBAAgB,GACjB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACL,gCAAgC,EAChC,kBAAkB,EAClB,2BAA2B,EAC3B,+BAA+B,GAChC,MAAM,iCAAiC,CAAC;AACzC,YAAY,EAAE,0BAA0B,EAAE,2BAA2B,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AACnI,OAAO,EAAE,wBAAwB,EAAE,wBAAwB,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAC;AACtH,YAAY,EACV,2BAA2B,EAC3B,4BAA4B,EAC5B,6BAA6B,GAC9B,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EAAE,8BAA8B,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC"}
package/dist/index.js CHANGED
@@ -5,6 +5,6 @@ export { connectCdp } from "./cdp-client.js";
5
5
  export { attachToRunningJvmProcess } from "./attach-to-running-jvm-process.js";
6
6
  export { respawnAndSupervise, inferRespawnCommandFromProc } from "./respawn-and-supervise.js";
7
7
  export { CGROUP_PARTIAL_RESTRICTION_SCOPE, cgroupV2Capability, findDelegatedCgroupAncestor, moveProcessIntoRestrictedCgroup, } from "./cgroup-partial-restriction.js";
8
- export { runInstrumentedExecution, createSourceRootResolver } from "./instrumented-execution.js";
8
+ export { runInstrumentedExecution, createSourceRootResolver, applyOutboundLaunch } from "./instrumented-execution.js";
9
9
  export { backendObservationMechanismFor, runRemoteLogObservation } from "./profile-backend-observation.js";
10
10
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gCAAgC,EAAE,MAAM,4BAA4B,CAAC;AAE9E,OAAO,EAAE,sBAAsB,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAExF,OAAO,EAAE,0BAA0B,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAE3G,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAE7C,OAAO,EAAE,yBAAyB,EAAE,MAAM,oCAAoC,CAAC;AAO/E,OAAO,EAAE,mBAAmB,EAAE,2BAA2B,EAAE,MAAM,4BAA4B,CAAC;AAK9F,OAAO,EACL,gCAAgC,EAChC,kBAAkB,EAClB,2BAA2B,EAC3B,+BAA+B,GAChC,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EAAE,wBAAwB,EAAE,wBAAwB,EAAE,MAAM,6BAA6B,CAAC;AAMjG,OAAO,EAAE,8BAA8B,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gCAAgC,EAAE,MAAM,4BAA4B,CAAC;AAE9E,OAAO,EAAE,sBAAsB,EAAE,cAAc,EAAE,MAAM,gCAAgC,CAAC;AAExF,OAAO,EAAE,0BAA0B,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAC;AAE3G,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAE7C,OAAO,EAAE,yBAAyB,EAAE,MAAM,oCAAoC,CAAC;AAO/E,OAAO,EAAE,mBAAmB,EAAE,2BAA2B,EAAE,MAAM,4BAA4B,CAAC;AAK9F,OAAO,EACL,gCAAgC,EAChC,kBAAkB,EAClB,2BAA2B,EAC3B,+BAA+B,GAChC,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EAAE,wBAAwB,EAAE,wBAAwB,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAC;AAMtH,OAAO,EAAE,8BAA8B,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC"}
@@ -27,7 +27,7 @@
27
27
  * place that judges it.
28
28
  */
29
29
  import type { Evidence, Execution, ExecutionConfiguration, ProcessHandle, ServiceRootLookup } from "@descryy/runtime-contracts";
30
- import type { RuntimeAdapter } from "@descryy/runtime-backend-observation";
30
+ import type { RuntimeAdapter, OutboundHttpLaunch } from "@descryy/runtime-backend-observation";
31
31
  import { type CreateExecutionInput, type RunOptions } from "@descryy/runtime-controller";
32
32
  import { EvidenceStore } from "@descryy/runtime-evidence-store";
33
33
  export interface InstrumentedExecutionInput {
@@ -95,6 +95,37 @@ export interface InstrumentedExecutionResult {
95
95
  }[];
96
96
  /** Set when `run()` refused before spawning anything. Evidence is empty and that is a refusal, not an absence of failures. */
97
97
  readonly validationError: string | null;
98
+ /**
99
+ * What the declared whole-execution budget actually did to this run.
100
+ *
101
+ * `ExecutionConfiguration.timeoutMs` is published to callers as the
102
+ * whole-execution budget, and before this it bounded only how long a
103
+ * *service* was allowed to live: `ExecutionController` armed a timer that
104
+ * killed the processes, and this function then slept the full
105
+ * `observeForMs` anyway, drained collectors and returned. Measured, not
106
+ * theoretical — a 1500ms budget with a 12000ms window returned after
107
+ * 12288ms with zero evidence, because the services had been dead for the
108
+ * last 10.8s of a window nothing shortened.
109
+ *
110
+ * Reported as a struct rather than left implicit in the elapsed time so a
111
+ * caller can say *which* of the two it got: a full window that found
112
+ * nothing, or a window cut short before it could. Those are the same two
113
+ * claims the five report categories exist to keep apart, one layer down.
114
+ */
115
+ readonly budget: ExecutionBudgetOutcome;
116
+ }
117
+ /** See `InstrumentedExecutionResult.budget`. */
118
+ export interface ExecutionBudgetOutcome {
119
+ /** `ExecutionConfiguration.timeoutMs`, verbatim. */
120
+ readonly declaredMs: number;
121
+ /** Wall-clock time this function actually took. */
122
+ readonly elapsedMs: number;
123
+ /** What `observeForMs` asked for. */
124
+ readonly requestedObservationMs: number;
125
+ /** What the budget left for it. Less than `requestedObservationMs` means the window was cut short. */
126
+ readonly observedForMs: number;
127
+ /** True when the run finished past its own deadline — teardown of real processes can overshoot even a bounded window. */
128
+ readonly exceeded: boolean;
98
129
  }
99
130
  /**
100
131
  * Builds the origin → source-root lookup a collector reads through
@@ -107,5 +138,15 @@ export interface InstrumentedExecutionResult {
107
138
  * configuration cannot know the port, so only the running process can say.
108
139
  */
109
140
  export declare function createSourceRootResolver(processes: readonly ProcessHandle[], configuration: ExecutionConfiguration): (origin: string) => ServiceRootLookup;
141
+ /**
142
+ * Rewrites every spawnable service so it launches with outbound
143
+ * instrumentation in place.
144
+ *
145
+ * The declaration comes from the adapter and names no language; this function
146
+ * applies it and also names none. `attach`-mode services are skipped: their
147
+ * process is already running, so there is no launch left to influence, and
148
+ * pretending otherwise would claim instrumentation that is not there.
149
+ */
150
+ export declare function applyOutboundLaunch(execution: CreateExecutionInput, launch: OutboundHttpLaunch): CreateExecutionInput;
110
151
  export declare function runInstrumentedExecution(input: InstrumentedExecutionInput): Promise<InstrumentedExecutionResult>;
111
152
  //# sourceMappingURL=instrumented-execution.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"instrumented-execution.d.ts","sourceRoot":"","sources":["../src/instrumented-execution.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAEH,OAAO,KAAK,EAEV,QAAQ,EACR,SAAS,EACT,sBAAsB,EACtB,aAAa,EACb,iBAAiB,EAClB,MAAM,4BAA4B,CAAC;AAEpC,OAAO,KAAK,EAAE,cAAc,EAAuB,MAAM,sCAAsC,CAAC;AAEhG,OAAO,EAEL,KAAK,oBAAoB,EACzB,KAAK,UAAU,EAGhB,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAC;AAKhE,MAAM,WAAW,0BAA0B;IACzC,oIAAoI;IACpI,QAAQ,CAAC,SAAS,EAAE,oBAAoB,CAAC;IACzC,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAC;IAChC,8FAA8F;IAC9F,QAAQ,CAAC,OAAO,EAAE,cAAc,CAAC;IACjC,qIAAqI;IACrI,QAAQ,CAAC,KAAK,EAAE,aAAa,CAAC;IAC9B;;;;;OAKG;IACH,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B;;;;;;;;;;;;;;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AM,CAAC;QAAC,QAAQ,CAAC,YAAY,EAAE,UAAU,CAAC,OAAO,4BAA4B,EAAE,SAAS,CAAC,cAAc,CAAC,CAAC,CAAA;KAAE,EAAE,CAAC;IAC/K,8HAA8H;IAC9H,QAAQ,CAAC,eAAe,EAAE,MAAM,GAAG,IAAI,CAAC;IACxC;;;;;;;;;;;;;;;;OAgBG;IACH,QAAQ,CAAC,MAAM,EAAE,sBAAsB,CAAC;CACzC;AAED,gDAAgD;AAChD,MAAM,WAAW,sBAAsB;IACrC,oDAAoD;IACpD,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,mDAAmD;IACnD,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,qCAAqC;IACrC,QAAQ,CAAC,sBAAsB,EAAE,MAAM,CAAC;IACxC,sGAAsG;IACtG,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;IAC/B,yHAAyH;IACzH,QAAQ,CAAC,QAAQ,EAAE,OAAO,CAAC;CAC5B;AAED;;;;;;;;;GASG;AACH,wBAAgB,wBAAwB,CACtC,SAAS,EAAE,SAAS,aAAa,EAAE,EACnC,aAAa,EAAE,sBAAsB,GACpC,CAAC,MAAM,EAAE,MAAM,KAAK,iBAAiB,CAEvC;AAED;;;;;;;;GAQG;AACH,wBAAgB,mBAAmB,CACjC,SAAS,EAAE,oBAAoB,EAC/B,MAAM,EAAE,kBAAkB,GACzB,oBAAoB,CAyBtB;AAED,wBAAsB,wBAAwB,CAAC,KAAK,EAAE,0BAA0B,GAAG,OAAO,CAAC,2BAA2B,CAAC,CA6jBtH"}
@@ -26,8 +26,10 @@
26
26
  * them in here would make the one place that assembles the runtime also the
27
27
  * place that judges it.
28
28
  */
29
+ import { delimiter } from "node:path";
29
30
  import { resolveServiceRootForOrigin } from "@descryy/runtime-contracts";
30
31
  import { createInboundProxy } from "@descryy/runtime-backend-observation";
32
+ import { createExternalRequestCollector } from "@descryy/runtime-external-service-observation";
31
33
  import { ExecutionController, checkDependencyVersions, checkEnvironmentVersion, } from "@descryy/runtime-controller";
32
34
  import { EvidenceStore } from "@descryy/runtime-evidence-store";
33
35
  import { createPollingProcessOutputSource } from "./polling-output-source.js";
@@ -45,9 +47,82 @@ import { COLLECTOR_VERSION } from "./collector-version.js";
45
47
  export function createSourceRootResolver(processes, configuration) {
46
48
  return (origin) => resolveServiceRootForOrigin(origin, { processes, configuration });
47
49
  }
50
+ /**
51
+ * Rewrites every spawnable service so it launches with outbound
52
+ * instrumentation in place.
53
+ *
54
+ * The declaration comes from the adapter and names no language; this function
55
+ * applies it and also names none. `attach`-mode services are skipped: their
56
+ * process is already running, so there is no launch left to influence, and
57
+ * pretending otherwise would claim instrumentation that is not there.
58
+ */
59
+ export function applyOutboundLaunch(execution, launch) {
60
+ const services = {};
61
+ for (const [name, service] of Object.entries(execution.configuration.services)) {
62
+ if (service.command === undefined) {
63
+ services[name] = service;
64
+ continue;
65
+ }
66
+ const prepend = new Set(launch.prependToExisting ?? []);
67
+ const env = { ...service.env };
68
+ for (const [key, value] of Object.entries(launch.env ?? {})) {
69
+ // A variable the target already relies on is extended, not replaced --
70
+ // `PYTHONPATH` is the live case, and replacing it stops the application
71
+ // finding its own modules, which is breaking it in order to watch it.
72
+ const existing = prepend.has(key) ? (service.env?.[key] ?? process.env[key] ?? "") : "";
73
+ env[key] = existing === "" ? value : `${value}${delimiter}${existing}`;
74
+ }
75
+ services[name] = {
76
+ ...service,
77
+ ...(Object.keys(env).length === 0 ? {} : { env }),
78
+ ...(launch.interpreterArgs === undefined || launch.interpreterArgs.length === 0
79
+ ? {}
80
+ : { interpreterArgs: [...(service.interpreterArgs ?? []), ...launch.interpreterArgs] }),
81
+ };
82
+ }
83
+ return { ...execution, configuration: { ...execution.configuration, services } };
84
+ }
48
85
  export async function runInstrumentedExecution(input) {
49
- const configuration = input.execution.configuration;
50
- const controller = ExecutionController.create(input.execution);
86
+ // **The outbound half, which nothing assembled before this.** The mechanism
87
+ // -- an outbound call captured at its own call site, joined to the route it
88
+ // reached in another process -- existed and was proven, but only a test
89
+ // ever wired it: `runInstrumentedExecution` started
90
+ // `createBackendCollectors` and nothing else, so no production path
91
+ // observed an outbound call at all.
92
+ //
93
+ // It takes two things, not one. A collector to read the marker lines, and a
94
+ // *launch* that puts the client instrumentation inside the target process
95
+ // before any application code can capture an unpatched client. The second
96
+ // is language-specific, so it is declared on the adapter and merely applied
97
+ // here. An adapter that declares nothing gets neither -- the run proceeds,
98
+ // no outbound collector is started, and nothing claims one was.
99
+ // The budget clock starts here, not at `controller.run()`. The controller
100
+ // arms its own timer for the same number a few statements later, so this
101
+ // deadline is the marginally earlier — and therefore the conservative — of
102
+ // the two; a caller who declared a bound never waits past it because this
103
+ // function took some of it before the controller was even created.
104
+ const budgetStartedAt = Date.now();
105
+ const outboundLaunch = input.adapter.outboundHttpLaunch?.() ?? null;
106
+ const launchedExecution = outboundLaunch === null ? input.execution : applyOutboundLaunch(input.execution, outboundLaunch);
107
+ const configuration = launchedExecution.configuration;
108
+ /**
109
+ * Every exit from this function reports the same struct, built from the one
110
+ * clock. Written as a closure rather than repeated at each `return` because
111
+ * there are four of them and the failure mode of the alternative — one
112
+ * return that quietly reports a different number — is exactly the class of
113
+ * bug this whole field exists to make visible.
114
+ */
115
+ const budgetOutcome = (observedForMs) => {
116
+ const elapsedMs = Date.now() - budgetStartedAt;
117
+ return {
118
+ declaredMs: configuration.timeoutMs,
119
+ elapsedMs,
120
+ requestedObservationMs: input.observeForMs,
121
+ observedForMs,
122
+ exceeded: elapsedMs > configuration.timeoutMs,
123
+ };
124
+ };
125
+ const controller = ExecutionController.create(launchedExecution);
51
126
  // Closes §34's remaining "runtime self-observability" gap after RT-219:
52
127
  // `controller.run()` has exactly one throw path (`controller.ts`'s own
53
128
  // `spawnProcess` catch/rethrow, after it has already recorded the
@@ -93,10 +168,17 @@ export async function runInstrumentedExecution(input) {
93
168
  evidence: [harnessEvidence],
94
169
  collectorCapabilities: [],
95
170
  validationError: `ExecutionController.run() threw: ${detail}`,
171
+ budget: budgetOutcome(0),
96
172
  };
97
173
  }
98
174
  if (controller.validationError !== null) {
99
- return { execution, evidence: [], collectorCapabilities: [], validationError: controller.validationError };
175
+ return {
176
+ execution,
177
+ evidence: [],
178
+ collectorCapabilities: [],
179
+ validationError: controller.validationError,
180
+ budget: budgetOutcome(0),
181
+ };
100
182
  }
101
183
  // One source per spawned service. `serviceName` is what joins a handle
102
184
  // back to its configuration entry, and a handle without one cannot be
@@ -106,6 +188,17 @@ export async function runInstrumentedExecution(input) {
106
188
  // forever on a source still watching a live buffer.
107
189
  let finished = false;
108
190
  const sources = [];
191
+ // A **second, independent** source per process, kept with the service name
192
+ // that produced it.
193
+ //
194
+ // Not the same source object as the backend collector's, and this is the
195
+ // whole subtlety: `createPollingProcessOutputSource` yields each line
196
+ // exactly once, so two collectors sharing one source do not both see the
197
+ // output -- they race for it, and the first consumer wins. Sharing it made
198
+ // the backend log collector eat every `DESCRY_EXTERNAL_REQUEST` line and
199
+ // the outbound collector report nothing, which reads exactly like a service
200
+ // that made no outbound calls.
201
+ const namedSources = [];
109
202
  for (const handle of execution.processes) {
110
203
  if (handle.serviceName === null)
111
204
  continue;
@@ -115,8 +208,31 @@ export async function runInstrumentedExecution(input) {
115
208
  readOutput: () => controller.readProcessOutput(serviceName),
116
209
  isFinished: () => finished,
117
210
  }));
211
+ namedSources.push({
212
+ serviceName,
213
+ source: createPollingProcessOutputSource({
214
+ processId: handle.processId,
215
+ readOutput: () => controller.readProcessOutput(serviceName),
216
+ isFinished: () => finished,
217
+ }),
218
+ });
118
219
  }
119
220
  const backendCollectors = input.adapter.createBackendCollectors(sources);
221
+ // Started only when the launch above actually installed instrumentation.
222
+ // A collector reading a process that was never instrumented would report
223
+ // "no outbound calls" for a service making them, which is the one answer
224
+ // worse than declining to look.
225
+ //
226
+ // `createExternalRequestCollector` itself names no language; the only
227
+ // language-specific value it needs is the adapter's own stack parser, which
228
+ // is what turns a captured call site into a file and a line.
229
+ const outboundCollectors = outboundLaunch === null
230
+ ? []
231
+ : namedSources.map(({ source, serviceName }) => createExternalRequestCollector({
232
+ source,
233
+ service: serviceName,
234
+ stackTraceParser: input.adapter.stackTraceParser,
235
+ }));
120
236
  const emitted = [];
121
237
  // `DEC-NEXT-fault-layer-empirical-confirmation.md`'s `dependency`/
122
238
  // `environment` mechanisms -- the producer side of the same shape RT-219
@@ -250,7 +366,7 @@ export async function runInstrumentedExecution(input) {
250
366
  });
251
367
  }
252
368
  }
253
- const collectors = [...backendCollectors, ...proxies.map((entry) => entry.proxy.collector)];
369
+ const collectors = [...backendCollectors, ...outboundCollectors, ...proxies.map((entry) => entry.proxy.collector)];
254
370
  const context = {
255
371
  executionId: execution.executionId,
256
372
  configuration,
@@ -345,19 +461,165 @@ export async function runInstrumentedExecution(input) {
345
461
  if (port !== null)
346
462
  proxyPorts[entry.serviceName] = port;
347
463
  }
348
- await input.onReady?.({ execution, proxyPorts });
349
- await new Promise((resolve) => setTimeout(resolve, input.observeForMs));
350
- // Order matters: the sources must be told the process is done before
351
- // stop() awaits their drain, or stop() waits forever on a generator
352
- // still polling a live buffer.
353
- finished = true;
354
- await Promise.all(collectors.map((collector) => collector.stop()));
355
- await controller.stop();
464
+ // **Everything from here to the teardown is wrapped, because a throw above
465
+ // the teardown used to leak the whole execution.**
466
+ //
467
+ // `onReady` is caller code and is documented not to be caught — correctly,
468
+ // since turning a caller's failed setup into a clean run would be the
469
+ // silent-degradation failure this repo rules against. But "not caught" and
470
+ // "not cleaned up" are two different promises and only the first was ever
471
+ // made: when `onReady` threw, `finished = true`, the collector `stop()` loop
472
+ // and `controller.stop()` were all skipped, so the polling output sources
473
+ // kept polling a live buffer, the spawned child was never killed, and the
474
+ // controller's timer held the event loop open. Measured: the call rejects in
475
+ // 270ms with the caller's own error, and the process then never exits.
476
+ //
477
+ // The exception still propagates, uncaught by any handler that changes it,
478
+ // to the same caller with the same stack — the documented contract is
479
+ // untouched. Only the leak goes away.
480
+ //
481
+ // Found the expensive way: a worktree missing the fixture app's
482
+ // `node_modules` made a test's `onReady` throw after a correctly bounded
483
+ // ten-second readiness wait, and the suite then hung for twenty minutes.
484
+ // `scripts/preflight.mjs` predicts that dependency gap and calls its worst
485
+ // case "a readiness timeout that looks like a slow boot" — milder than what
486
+ // actually happened, which is what makes this a defect rather than an
487
+ // inconvenience: a guard whose stated worst case is better than reality
488
+ // teaches people to trust it less than they should.
489
+ let observationMs = 0;
490
+ let bodyFailure = null;
491
+ let teardownFailure = null;
492
+ try {
493
+ await input.onReady?.({ execution, proxyPorts });
494
+ // **The observation window is bounded by the declared budget, not just by
495
+ // `observeForMs`.** This line used to be an unconditional sleep for the
496
+ // full requested window, which made `timeoutMs` an upper bound on how long
497
+ // a service was allowed to live and no bound at all on how long the caller
498
+ // was made to wait. The two numbers then diverged silently, and in the
499
+ // worst direction: `ExecutionController`'s own timer had already killed
500
+ // every process at the deadline, so the remainder of the window watched
501
+ // dead processes and produced nothing. Measured — a 1500ms budget with a
502
+ // 12000ms window returned after 12288ms with zero evidence.
503
+ //
504
+ // Clamped rather than aborted. There is real work left after this point
505
+ // (draining collectors, reaping children) that owns OS resources and must
506
+ // still run; cancelling it to hit the number exactly would leak the
507
+ // processes the budget exists to bound. So the deadline decides how long we
508
+ // *watch*, and the overshoot from teardown is reported rather than hidden —
509
+ // `budget.exceeded` is what says the run finished past its own bound.
510
+ const remainingMs = budgetStartedAt + configuration.timeoutMs - Date.now();
511
+ observationMs = Math.max(0, Math.min(input.observeForMs, remainingMs));
512
+ if (observationMs > 0) {
513
+ await new Promise((resolve) => setTimeout(resolve, observationMs));
514
+ }
515
+ // A window that was cut short is a degradation, and rule 7 says every
516
+ // fallback is labelled. `execution.state` already carries `TIMED_OUT` when
517
+ // the controller's own timer fired, but that says the *services* were
518
+ // stopped early — it does not say the observation was, and a run whose
519
+ // budget expired before the controller ever armed (or after it had already
520
+ // completed) leaves no trace in the state at all.
521
+ //
522
+ // Tagged `source: "harness"` with `COLLECTOR_ERROR`: this is the runtime
523
+ // observing itself rather than any watched domain, and the event type's own
524
+ // documented purpose is to keep "found nothing" apart from "stopped
525
+ // looking". A truncated window is precisely the second one, so it needs no
526
+ // new event type of its own.
527
+ if (observationMs < input.observeForMs) {
528
+ emitted.push(input.store.write({
529
+ executionId: execution.executionId,
530
+ timestamp: new Date().toISOString(),
531
+ source: "harness",
532
+ service: null,
533
+ process: null,
534
+ eventType: "COLLECTOR_ERROR",
535
+ payload: {
536
+ raw: `the observation window was cut short by the declared whole-execution budget: ` +
537
+ `observed for ${String(observationMs)}ms of the ${String(input.observeForMs)}ms requested, ` +
538
+ `against a ${String(configuration.timeoutMs)}ms budget. Evidence from this run is partial — ` +
539
+ `absence of an event is not evidence the application did not produce one.`,
540
+ collectorId: "orchestrator:execution-budget",
541
+ },
542
+ traceId: null,
543
+ requestId: null,
544
+ correlationId: null,
545
+ graphNodeId: null,
546
+ sourceLocation: null,
547
+ stackTrace: null,
548
+ confidence: 1,
549
+ collectorVersion: COLLECTOR_VERSION,
550
+ }));
551
+ }
552
+ }
553
+ catch (error) {
554
+ // Held, not handled. Rethrown below, unchanged, once the teardown in the
555
+ // `finally` has run.
556
+ bodyFailure = { error };
557
+ }
558
+ finally {
559
+ // Order matters: the sources must be told the process is done before
560
+ // stop() awaits their drain, or stop() waits forever on a generator
561
+ // still polling a live buffer.
562
+ finished = true;
563
+ try {
564
+ await Promise.all(collectors.map((collector) => collector.stop()));
565
+ await controller.stop();
566
+ }
567
+ catch (teardownError) {
568
+ // On the ordinary path a teardown failure is the only failure there is,
569
+ // so it propagates exactly as it always did — held here and rethrown
570
+ // below rather than thrown from inside the `finally`, which is the one
571
+ // place a throw really can discard an in-flight exception.
572
+ if (bodyFailure === null) {
573
+ teardownFailure = { error: teardownError };
574
+ }
575
+ else {
576
+ // When something already failed above, the caller's own error is the
577
+ // actionable one and a teardown failure must not replace it — a plain
578
+ // `finally` would silently substitute the second for the first, which
579
+ // is the same class of mistake as the leak this block exists to fix.
580
+ // So it is written to the evidence store instead of thrown, tagged
581
+ // `harness` (RT-219) because it is the runtime's own machinery
582
+ // breaking rather than anything about the observed application. It is
583
+ // not in the returned array — there is no return on this path — but
584
+ // the store is durable and is what `evidencePath` points at, so the
585
+ // record survives the throw.
586
+ input.store.write({
587
+ executionId: execution.executionId,
588
+ timestamp: new Date().toISOString(),
589
+ source: "harness",
590
+ service: null,
591
+ process: null,
592
+ eventType: "COLLECTOR_ERROR",
593
+ payload: {
594
+ raw: "teardown also failed while unwinding from an earlier failure, and is recorded rather than " +
595
+ `thrown so it does not mask it: ${teardownError instanceof Error ? `${teardownError.name}: ${teardownError.message}` : String(teardownError)}`,
596
+ collectorId: "orchestrator:teardown",
597
+ },
598
+ traceId: null,
599
+ requestId: null,
600
+ correlationId: null,
601
+ graphNodeId: null,
602
+ sourceLocation: null,
603
+ stackTrace: null,
604
+ confidence: 1,
605
+ collectorVersion: COLLECTOR_VERSION,
606
+ });
607
+ }
608
+ }
609
+ }
610
+ // Rethrown untouched — the same error object, the same stack, to the same
611
+ // caller. The caller's own failure wins over a teardown failure when both
612
+ // happened, because it is the one they can act on.
613
+ if (bodyFailure !== null)
614
+ throw bodyFailure.error;
615
+ if (teardownFailure !== null)
616
+ throw teardownFailure.error;
356
617
  return {
357
618
  execution: controller.execution,
358
619
  evidence: emitted,
359
620
  collectorCapabilities: collectors.map((collector) => ({ collectorId: collector.collectorId, capabilities: collector.capabilities() })),
360
621
  validationError: null,
622
+ budget: budgetOutcome(observationMs),
361
623
  };
362
624
  }
363
625
  //# sourceMappingURL=instrumented-execution.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"instrumented-execution.js","sourceRoot":"","sources":["../src/instrumented-execution.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAUH,OAAO,EAAE,2BAA2B,EAAE,MAAM,4BAA4B,CAAC;AAEzE,OAAO,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAC;AAC1E,OAAO,EACL,mB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AAO,EAAE;wBACP,GAAG,EACD,4FAA4F;4BAC5F,kCAAkC,aAAa,YAAY,KAAK,CAAC,CAAC,CAAC,GAAG,aAAa,CAAC,IAAI,KAAK,aAAa,CAAC,OAAO,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,aAAa,CAAC,EAAE;wBAChJ,WAAW,EAAE,uBAAuB;qBACrC;oBACD,OAAO,EAAE,IAAI;oBACb,SAAS,EAAE,IAAI;oBACf,aAAa,EAAE,IAAI;oBACnB,WAAW,EAAE,IAAI;oBACjB,cAAc,EAAE,IAAI;oBACpB,UAAU,EAAE,IAAI;oBAChB,UAAU,EAAE,CAAC;oBACb,gBAAgB,EAAE,iBAAiB;iBACpC,CAAC,CAAC;YACL,CAAC;QACH,CAAC;IACH,CAAC;IAED,0EAA0E;IAC1E,0EAA0E;IAC1E,mDAAmD;IACnD,IAAI,WAAW,KAAK,IAAI;QAAE,MAAM,WAAW,CAAC,KAAK,CAAC;IAClD,IAAI,eAAe,KAAK,IAAI;QAAE,MAAM,eAAe,CAAC,KAAK,CAAC;IAE1D,OAAO;QACL,SAAS,EAAE,UAAU,CAAC,SAAS;QAC/B,QAAQ,EAAE,OAAO;QACjB,qBAAqB,EAAE,UAAU,CAAC,GAAG,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,CAAC,EAAE,WAAW,EAAE,SAAS,CAAC,WAAW,EAAE,YAAY,EAAE,SAAS,CAAC,YAAY,EAAE,EAAE,CAAC,CAAC;QACtI,eAAe,EAAE,IAAI;QACrB,MAAM,EAAE,aAAa,CAAC,aAAa,CAAC;KACrC,CAAC;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@descryy/runtime-orchestrator",
3
- "version": "0.0.1",
3
+ "version": "0.2.0",
4
4
  "type": "module",
5
5
  "description": "Assembles the runtime: controller-spawned services, live process output, collectors from a RuntimeAdapter, and a CollectorContext that can resolve script origins to source roots.",
6
6
  "license": "UNLICENSED",
@@ -24,22 +24,23 @@
24
24
  "build": "tsc -b"
25
25
  },
26
26
  "dependencies": {
27
- "@descryy/runtime-contracts": "0.0.0",
28
- "@descryy/runtime-backend-observation": "0.0.0",
29
- "@descryy/runtime-controller": "0.0.0",
30
- "@descryy/runtime-evidence-store": "0.0.0",
31
- "@descryy/runtime-adapter-typescript": "0.0.0",
32
- "@descryy/runtime-environment-profile": "0.0.1",
33
- "@descryy/runtime-remote-log-ingestion": "0.0.0"
27
+ "@descryy/runtime-contracts": "0.2.0",
28
+ "@descryy/runtime-backend-observation": "0.2.0",
29
+ "@descryy/runtime-controller": "0.2.0",
30
+ "@descryy/runtime-evidence-store": "0.2.0",
31
+ "@descryy/runtime-adapter-typescript": "0.2.0",
32
+ "@descryy/runtime-environment-profile": "0.2.0",
33
+ "@descryy/runtime-remote-log-ingestion": "0.2.0",
34
+ "@descryy/runtime-external-service-observation": "0.2.0"
34
35
  },
35
36
  "devDependencies": {
36
- "@descryhq-wq/runtime-adapter-csharp": "*",
37
- "@descryhq-wq/runtime-adapter-go": "*",
38
- "@descryhq-wq/runtime-adapter-jvm": "*",
39
- "@descryhq-wq/runtime-adapter-php": "*",
40
- "@descryhq-wq/runtime-adapter-python": "*",
41
- "@descryhq-wq/runtime-adapter-ruby": "*",
42
- "@descryhq-wq/runtime-adapter-rust": "*",
43
- "@descryhq-wq/runtime-adapter-swift": "*"
37
+ "@descryy/runtime-adapter-csharp": "*",
38
+ "@descryy/runtime-adapter-go": "*",
39
+ "@descryy/runtime-adapter-jvm": "*",
40
+ "@descryy/runtime-adapter-php": "*",
41
+ "@descryy/runtime-adapter-python": "*",
42
+ "@descryy/runtime-adapter-ruby": "*",
43
+ "@descryy/runtime-adapter-rust": "*",
44
+ "@descryy/runtime-adapter-swift": "*"
44
45
  }
45
46
  }