@blue-labs/document-processor 2.0.0-rc.6 → 2.0.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.
- package/dist/engine/channel-runner.d.ts +3 -0
- package/dist/engine/channel-runner.d.ts.map +1 -1
- package/dist/engine/processor-engine.d.ts.map +1 -1
- package/dist/index.js +447 -403
- package/dist/registry/processors/myos-timeline-channel-processor.d.ts +1 -0
- package/dist/registry/processors/myos-timeline-channel-processor.d.ts.map +1 -1
- package/dist/registry/processors/shared/timeline-recency.d.ts +3 -0
- package/dist/registry/processors/shared/timeline-recency.d.ts.map +1 -0
- package/dist/registry/processors/timeline-channel-processor.d.ts +1 -0
- package/dist/registry/processors/timeline-channel-processor.d.ts.map +1 -1
- package/dist/registry/types.d.ts +5 -0
- package/dist/registry/types.d.ts.map +1 -1
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -1,39 +1,39 @@
|
|
|
1
|
-
import { blueIds as m, ContractSchema as
|
|
2
|
-
import { getQuickJS as
|
|
3
|
-
import { BlueNode as d, blueNodeField as V, withTypeBlueId as
|
|
1
|
+
import { blueIds as m, ContractSchema as nt, ChannelSchema as rt, HandlerSchema as it, MarkerSchema as st, DocumentUpdateChannelSchema as ot, EmbeddedNodeChannelSchema as at, LifecycleEventChannelSchema as ct, TriggeredEventChannelSchema as lt, ChannelEventCheckpointSchema as ut, ProcessingInitializedMarkerSchema as dt, ProcessEmbeddedSchema as ht, ProcessingTerminatedMarkerSchema as ft, repository as pt } from "@blue-repository/core";
|
|
2
|
+
import { getQuickJS as mt } from "quickjs-emscripten";
|
|
3
|
+
import { BlueNode as d, blueNodeField as V, withTypeBlueId as gt, BlueIdCalculator as Et, Blue as yt, MergingProcessors as P } from "@blue-labs/language";
|
|
4
4
|
import fe from "picomatch";
|
|
5
|
-
import { z as b, ZodError as
|
|
6
|
-
import { TimelineChannelSchema as
|
|
7
|
-
import { MyOSTimelineChannelSchema as
|
|
5
|
+
import { z as b, ZodError as Me } from "zod";
|
|
6
|
+
import { TimelineChannelSchema as wt, OperationSchema as z, SequentialWorkflowSchema as St, SequentialWorkflowOperationSchema as bt, TimelineEntrySchema as v, blueIds as R, TriggerEventSchema as pe, JavaScriptCodeSchema as me, UpdateDocumentSchema as ge, OperationRequestSchema as ne, repository as Ct } from "@blue-repository/conversation";
|
|
7
|
+
import { MyOSTimelineChannelSchema as It, DocumentAnchorsSchema as vt, DocumentLinksSchema as kt, MyOSParticipantsOrchestrationSchema as Tt, MyOSSessionInteractionSchema as Rt, MyOSWorkerAgencySchema as Pt, blueIds as D, MyOSTimelineEntrySchema as Ee, repository as Nt } from "@blue-repository/myos";
|
|
8
8
|
import { isNullable as re } from "@blue-labs/shared-utils";
|
|
9
|
-
function
|
|
9
|
+
function Mt(i) {
|
|
10
10
|
return { ok: !0, value: i };
|
|
11
11
|
}
|
|
12
|
-
function
|
|
12
|
+
function Ot(i) {
|
|
13
13
|
return { ok: !1, error: i };
|
|
14
14
|
}
|
|
15
|
-
function
|
|
15
|
+
function gi(i) {
|
|
16
16
|
return i.ok;
|
|
17
17
|
}
|
|
18
|
-
function
|
|
18
|
+
function Ei(i) {
|
|
19
19
|
return !i.ok;
|
|
20
20
|
}
|
|
21
|
-
function
|
|
22
|
-
return i.ok ?
|
|
21
|
+
function yi(i, e) {
|
|
22
|
+
return i.ok ? Mt(e(i.value)) : i;
|
|
23
23
|
}
|
|
24
|
-
function
|
|
25
|
-
return i.ok ? i :
|
|
24
|
+
function wi(i, e) {
|
|
25
|
+
return i.ok ? i : Ot(e(i.error));
|
|
26
26
|
}
|
|
27
|
-
function
|
|
27
|
+
function Si(i, e) {
|
|
28
28
|
return i.ok ? e(i.value) : i;
|
|
29
29
|
}
|
|
30
|
-
function
|
|
30
|
+
function bi(i, e) {
|
|
31
31
|
return i.ok ? i.value : e;
|
|
32
32
|
}
|
|
33
|
-
function
|
|
33
|
+
function Ci(i, e) {
|
|
34
34
|
return i.ok ? i.value : e(i.error);
|
|
35
35
|
}
|
|
36
|
-
function
|
|
36
|
+
function Ii(i, e) {
|
|
37
37
|
return i.ok ? e.ok(i.value) : e.err(i.error);
|
|
38
38
|
}
|
|
39
39
|
const E = {
|
|
@@ -56,14 +56,14 @@ const E = {
|
|
|
56
56
|
return { kind: "UnsupportedOp", operation: i, reason: e };
|
|
57
57
|
}
|
|
58
58
|
};
|
|
59
|
-
function
|
|
59
|
+
function At(i) {
|
|
60
60
|
return Object.freeze([...i]);
|
|
61
61
|
}
|
|
62
|
-
const
|
|
62
|
+
const Dt = {
|
|
63
63
|
of(i, e, t) {
|
|
64
64
|
return {
|
|
65
65
|
document: i,
|
|
66
|
-
triggeredEvents:
|
|
66
|
+
triggeredEvents: At(e),
|
|
67
67
|
totalGas: t,
|
|
68
68
|
capabilityFailure: !1,
|
|
69
69
|
failureReason: null
|
|
@@ -78,66 +78,66 @@ const At = {
|
|
|
78
78
|
failureReason: e ?? null
|
|
79
79
|
};
|
|
80
80
|
}
|
|
81
|
-
},
|
|
81
|
+
}, Oe = Dt, Bt = [
|
|
82
82
|
"embedded",
|
|
83
83
|
"initialized",
|
|
84
84
|
"terminated",
|
|
85
85
|
"checkpoint"
|
|
86
|
-
],
|
|
86
|
+
], _t = [
|
|
87
87
|
m["Document Update Channel"],
|
|
88
88
|
m["Triggered Event Channel"],
|
|
89
89
|
m["Lifecycle Event Channel"],
|
|
90
90
|
m["Embedded Node Channel"]
|
|
91
|
-
], Ae = "embedded",
|
|
92
|
-
|
|
93
|
-
),
|
|
94
|
-
function
|
|
91
|
+
], Ae = "embedded", De = "initialized", Be = "terminated", T = "checkpoint", oe = new Set(
|
|
92
|
+
Bt
|
|
93
|
+
), _e = new Set(_t);
|
|
94
|
+
function Lt(i) {
|
|
95
95
|
return i != null && oe.has(i);
|
|
96
96
|
}
|
|
97
97
|
function ae(i) {
|
|
98
|
-
return i != null &&
|
|
98
|
+
return i != null && _e.has(
|
|
99
99
|
i
|
|
100
100
|
);
|
|
101
101
|
}
|
|
102
|
-
const
|
|
102
|
+
const vi = {
|
|
103
103
|
KEY_EMBEDDED: Ae,
|
|
104
|
-
KEY_INITIALIZED:
|
|
105
|
-
KEY_TERMINATED:
|
|
104
|
+
KEY_INITIALIZED: De,
|
|
105
|
+
KEY_TERMINATED: Be,
|
|
106
106
|
KEY_CHECKPOINT: T,
|
|
107
107
|
RESERVED_CONTRACT_KEYS: oe,
|
|
108
|
-
PROCESSOR_MANAGED_CHANNEL_BLUE_IDS:
|
|
109
|
-
isReservedContractKey:
|
|
108
|
+
PROCESSOR_MANAGED_CHANNEL_BLUE_IDS: _e,
|
|
109
|
+
isReservedContractKey: Lt,
|
|
110
110
|
isProcessorManagedChannelBlueId: ae
|
|
111
|
-
}, B = "/contracts", ie = `${B}/${
|
|
111
|
+
}, B = "/contracts", ie = `${B}/${De}`, Le = `${B}/${Be}`, $t = `${B}/${Ae}`, $e = `${B}/${T}`, xe = "/lastEvents", Fe = "/lastSignatures";
|
|
112
112
|
function Q(i) {
|
|
113
113
|
return `${B}/${i}`;
|
|
114
114
|
}
|
|
115
|
-
function Fe(i, e) {
|
|
116
|
-
return `${Q(i)}${$e}/${e}`;
|
|
117
|
-
}
|
|
118
115
|
function ze(i, e) {
|
|
119
116
|
return `${Q(i)}${xe}/${e}`;
|
|
120
117
|
}
|
|
121
|
-
|
|
118
|
+
function Ue(i, e) {
|
|
119
|
+
return `${Q(i)}${Fe}/${e}`;
|
|
120
|
+
}
|
|
121
|
+
const ki = {
|
|
122
122
|
RELATIVE_CONTRACTS: B,
|
|
123
123
|
RELATIVE_INITIALIZED: ie,
|
|
124
|
-
RELATIVE_TERMINATED:
|
|
125
|
-
RELATIVE_EMBEDDED:
|
|
126
|
-
RELATIVE_CHECKPOINT:
|
|
127
|
-
LAST_EVENTS_SUFFIX:
|
|
128
|
-
LAST_SIGNATURES_SUFFIX:
|
|
124
|
+
RELATIVE_TERMINATED: Le,
|
|
125
|
+
RELATIVE_EMBEDDED: $t,
|
|
126
|
+
RELATIVE_CHECKPOINT: $e,
|
|
127
|
+
LAST_EVENTS_SUFFIX: xe,
|
|
128
|
+
LAST_SIGNATURES_SUFFIX: Fe,
|
|
129
129
|
relativeContractsEntry: Q,
|
|
130
|
-
relativeCheckpointLastEvent:
|
|
131
|
-
relativeCheckpointLastSignature:
|
|
130
|
+
relativeCheckpointLastEvent: ze,
|
|
131
|
+
relativeCheckpointLastSignature: Ue
|
|
132
132
|
};
|
|
133
|
-
function
|
|
133
|
+
function Ve(i) {
|
|
134
134
|
return i == null || i.length === 0;
|
|
135
135
|
}
|
|
136
136
|
function y(i) {
|
|
137
|
-
return
|
|
137
|
+
return Ve(i) ? "/" : i.startsWith("/") ? i : `/${i}`;
|
|
138
138
|
}
|
|
139
139
|
function S(i) {
|
|
140
|
-
return
|
|
140
|
+
return Ve(i) ? "/" : i.startsWith("/") ? i : `/${i}`;
|
|
141
141
|
}
|
|
142
142
|
function ye(i) {
|
|
143
143
|
if (i == null)
|
|
@@ -151,7 +151,7 @@ function ye(i) {
|
|
|
151
151
|
e = e.substring(0, e.length - 1);
|
|
152
152
|
return e;
|
|
153
153
|
}
|
|
154
|
-
function
|
|
154
|
+
function Ti(i, e) {
|
|
155
155
|
const t = ye(i), n = ye(e);
|
|
156
156
|
return t.length === 0 && n.length === 0 ? "/" : t.length === 0 ? `/${n}` : n.length === 0 ? `/${t}` : `/${t}/${n}`;
|
|
157
157
|
}
|
|
@@ -159,7 +159,7 @@ function w(i, e) {
|
|
|
159
159
|
const t = y(i), n = S(e);
|
|
160
160
|
return t === "/" ? n : n === "/" || n.length === 1 ? t : `${t}${n}`;
|
|
161
161
|
}
|
|
162
|
-
function
|
|
162
|
+
function xt(i, e) {
|
|
163
163
|
const t = y(i), n = S(e);
|
|
164
164
|
if (t === "/" || !n.startsWith(t))
|
|
165
165
|
return n;
|
|
@@ -168,11 +168,11 @@ function Lt(i, e) {
|
|
|
168
168
|
const r = n.substring(t.length);
|
|
169
169
|
return r.length === 0 ? "/" : r.startsWith("/") ? r : `/${r}`;
|
|
170
170
|
}
|
|
171
|
-
function
|
|
171
|
+
function Ft(i) {
|
|
172
172
|
return i && i.__esModule && Object.prototype.hasOwnProperty.call(i, "default") ? i.default : i;
|
|
173
173
|
}
|
|
174
174
|
var X, we;
|
|
175
|
-
function
|
|
175
|
+
function zt() {
|
|
176
176
|
return we || (we = 1, X = function i(e) {
|
|
177
177
|
if (typeof e == "number" && isNaN(e))
|
|
178
178
|
throw new Error("NaN is not allowed");
|
|
@@ -186,29 +186,29 @@ function xt() {
|
|
|
186
186
|
}, "")}}`;
|
|
187
187
|
}), X;
|
|
188
188
|
}
|
|
189
|
-
var
|
|
190
|
-
const
|
|
191
|
-
function
|
|
189
|
+
var Ut = zt();
|
|
190
|
+
const Vt = /* @__PURE__ */ Ft(Ut);
|
|
191
|
+
function Ht(i, e) {
|
|
192
192
|
return i.nodeToJson(e, "official");
|
|
193
193
|
}
|
|
194
|
-
function
|
|
195
|
-
const t =
|
|
196
|
-
return
|
|
194
|
+
function Kt(i, e) {
|
|
195
|
+
const t = Ht(i, e);
|
|
196
|
+
return Vt(t);
|
|
197
197
|
}
|
|
198
|
-
function
|
|
199
|
-
return e ?
|
|
198
|
+
function He(i, e) {
|
|
199
|
+
return e ? Kt(i, e) : null;
|
|
200
200
|
}
|
|
201
201
|
function Se(i, e) {
|
|
202
|
-
const t =
|
|
202
|
+
const t = He(i, e);
|
|
203
203
|
return t == null ? 0 : new TextEncoder().encode(t).length;
|
|
204
204
|
}
|
|
205
|
-
function
|
|
205
|
+
function Ke(i) {
|
|
206
206
|
return typeof i == "object" && i !== null && !Array.isArray(i);
|
|
207
207
|
}
|
|
208
|
-
function
|
|
208
|
+
function Wt(i) {
|
|
209
209
|
return i.replace(/~1/g, "/").replace(/~0/g, "~");
|
|
210
210
|
}
|
|
211
|
-
function
|
|
211
|
+
function Gt(i) {
|
|
212
212
|
if (i.length === 0 || !/^\d+$/.test(i))
|
|
213
213
|
return !1;
|
|
214
214
|
const e = Number(i);
|
|
@@ -217,7 +217,7 @@ function Kt(i) {
|
|
|
217
217
|
function x(i, e = !0) {
|
|
218
218
|
if (Array.isArray(i))
|
|
219
219
|
return e ? i.map((r) => x(r, !0)) : i.slice();
|
|
220
|
-
if (!
|
|
220
|
+
if (!Ke(i))
|
|
221
221
|
return i;
|
|
222
222
|
if (Object.prototype.hasOwnProperty.call(i, "value")) {
|
|
223
223
|
const r = i.value;
|
|
@@ -231,24 +231,24 @@ function x(i, e = !0) {
|
|
|
231
231
|
n[r] = e ? x(s, !0) : s;
|
|
232
232
|
return n;
|
|
233
233
|
}
|
|
234
|
-
function
|
|
234
|
+
function qt(i, e) {
|
|
235
235
|
if (e === "")
|
|
236
236
|
return i;
|
|
237
237
|
if (!e.startsWith("/"))
|
|
238
238
|
throw new TypeError('JSON pointer must start with "/"');
|
|
239
|
-
const t = e.split("/").slice(1).map((r) =>
|
|
239
|
+
const t = e.split("/").slice(1).map((r) => Wt(r));
|
|
240
240
|
let n = i;
|
|
241
241
|
for (const r of t) {
|
|
242
242
|
if (n == null)
|
|
243
243
|
return;
|
|
244
244
|
if (Array.isArray(n)) {
|
|
245
|
-
if (!
|
|
245
|
+
if (!Gt(r))
|
|
246
246
|
return;
|
|
247
247
|
const s = Number(r);
|
|
248
248
|
n = n[s];
|
|
249
249
|
continue;
|
|
250
250
|
}
|
|
251
|
-
if (
|
|
251
|
+
if (Ke(n)) {
|
|
252
252
|
n = n[r];
|
|
253
253
|
continue;
|
|
254
254
|
}
|
|
@@ -256,15 +256,15 @@ function Wt(i, e) {
|
|
|
256
256
|
}
|
|
257
257
|
return n;
|
|
258
258
|
}
|
|
259
|
-
const
|
|
259
|
+
const Jt = 500, jt = 32 * 1024 * 1024;
|
|
260
260
|
class ce {
|
|
261
261
|
modulePromise;
|
|
262
262
|
moduleInstance;
|
|
263
263
|
async evaluate({
|
|
264
264
|
code: e,
|
|
265
265
|
bindings: t,
|
|
266
|
-
timeout: n =
|
|
267
|
-
memoryLimit: r =
|
|
266
|
+
timeout: n = Jt,
|
|
267
|
+
memoryLimit: r = jt
|
|
268
268
|
}) {
|
|
269
269
|
const o = (await this.ensureModule()).newRuntime();
|
|
270
270
|
o.setMemoryLimit(r);
|
|
@@ -290,7 +290,7 @@ class ce {
|
|
|
290
290
|
}
|
|
291
291
|
}
|
|
292
292
|
async ensureModule() {
|
|
293
|
-
return this.moduleInstance ? this.moduleInstance : (this.modulePromise || (this.modulePromise =
|
|
293
|
+
return this.moduleInstance ? this.moduleInstance : (this.modulePromise || (this.modulePromise = mt().then((e) => (this.moduleInstance = e, e))), this.modulePromise);
|
|
294
294
|
}
|
|
295
295
|
wrapCode(e) {
|
|
296
296
|
return `(async () => {
|
|
@@ -333,7 +333,7 @@ ${e}
|
|
|
333
333
|
const a = e.dump(s);
|
|
334
334
|
if (typeof a != "string")
|
|
335
335
|
throw new TypeError("canon.at pointer must be a string");
|
|
336
|
-
const c =
|
|
336
|
+
const c = qt(o, a);
|
|
337
337
|
return this.createReturnHandle(e, c);
|
|
338
338
|
} catch (r) {
|
|
339
339
|
const s = r instanceof Error ? r.message : String(r);
|
|
@@ -492,43 +492,43 @@ ${e}
|
|
|
492
492
|
}
|
|
493
493
|
}
|
|
494
494
|
const be = 120;
|
|
495
|
-
function
|
|
495
|
+
function Qt(i) {
|
|
496
496
|
return i.length <= be ? i : `${i.slice(0, be - 3)}...`;
|
|
497
497
|
}
|
|
498
|
-
class
|
|
498
|
+
class We extends Error {
|
|
499
499
|
constructor(e, t) {
|
|
500
|
-
super(`Failed to evaluate code block: ${
|
|
500
|
+
super(`Failed to evaluate code block: ${Qt(e)}`, { cause: t }), this.code = e, this.cause = t, this.name = "CodeBlockEvaluationError";
|
|
501
501
|
}
|
|
502
502
|
}
|
|
503
|
-
const
|
|
503
|
+
const Ge = /^\$\{([\s\S]*)\}$/, Yt = /\$\{([\s\S]+?)\}/, qe = /\$\{([\s\S]+?)\}/g;
|
|
504
504
|
function G(i) {
|
|
505
|
-
if (typeof i != "string" || !
|
|
505
|
+
if (typeof i != "string" || !Ge.test(i))
|
|
506
506
|
return !1;
|
|
507
507
|
const e = i.indexOf("${"), t = i.lastIndexOf("${");
|
|
508
508
|
return e === t;
|
|
509
509
|
}
|
|
510
|
-
function
|
|
511
|
-
return typeof i != "string" ? !1 :
|
|
510
|
+
function Zt(i) {
|
|
511
|
+
return typeof i != "string" ? !1 : Ge.test(i) ? !0 : Yt.test(i);
|
|
512
512
|
}
|
|
513
|
-
function
|
|
513
|
+
function Xt(i) {
|
|
514
514
|
if (!G(i))
|
|
515
515
|
throw new Error(`Invalid expression: ${i}`);
|
|
516
516
|
return i.slice(2, -1);
|
|
517
517
|
}
|
|
518
|
-
async function
|
|
518
|
+
async function Je(i, e, t) {
|
|
519
519
|
const n = `return await (${e});`;
|
|
520
520
|
try {
|
|
521
521
|
return await i.evaluate({ code: n, bindings: t });
|
|
522
522
|
} catch (r) {
|
|
523
|
-
throw new
|
|
523
|
+
throw new We(e, r);
|
|
524
524
|
}
|
|
525
525
|
}
|
|
526
|
-
async function
|
|
526
|
+
async function en(i, e, t) {
|
|
527
527
|
let n = "", r = 0;
|
|
528
|
-
for (const s of e.matchAll(
|
|
528
|
+
for (const s of e.matchAll(qe)) {
|
|
529
529
|
const o = s[0], a = s[1], c = s.index ?? 0;
|
|
530
530
|
n += e.slice(r, c);
|
|
531
|
-
const l = await
|
|
531
|
+
const l = await Je(
|
|
532
532
|
i,
|
|
533
533
|
a,
|
|
534
534
|
t
|
|
@@ -537,7 +537,7 @@ async function Zt(i, e, t) {
|
|
|
537
537
|
}
|
|
538
538
|
return n += e.slice(r), n;
|
|
539
539
|
}
|
|
540
|
-
function
|
|
540
|
+
function je({
|
|
541
541
|
include: i,
|
|
542
542
|
exclude: e = [],
|
|
543
543
|
options: t
|
|
@@ -565,21 +565,21 @@ async function q(i) {
|
|
|
565
565
|
if (l !== void 0) {
|
|
566
566
|
if (typeof l == "string" && r(a)) {
|
|
567
567
|
if (G(l)) {
|
|
568
|
-
const h =
|
|
568
|
+
const h = Xt(l);
|
|
569
569
|
o.gasMeter().chargeExpression(h);
|
|
570
|
-
const p = await
|
|
570
|
+
const p = await Je(
|
|
571
571
|
e,
|
|
572
572
|
h,
|
|
573
573
|
n
|
|
574
574
|
);
|
|
575
575
|
return o.blue.jsonValueToNode(p ?? null);
|
|
576
|
-
} else if (
|
|
577
|
-
const h = new RegExp(
|
|
576
|
+
} else if (Zt(l)) {
|
|
577
|
+
const h = new RegExp(qe);
|
|
578
578
|
let p = 0;
|
|
579
579
|
for (h.lastIndex = 0; h.exec(l); )
|
|
580
580
|
p += 1;
|
|
581
581
|
o.gasMeter().chargeTemplate(p, l);
|
|
582
|
-
const I = await
|
|
582
|
+
const I = await en(
|
|
583
583
|
e,
|
|
584
584
|
l,
|
|
585
585
|
n
|
|
@@ -617,17 +617,17 @@ async function q(i) {
|
|
|
617
617
|
}
|
|
618
618
|
return c;
|
|
619
619
|
}
|
|
620
|
-
const le =
|
|
620
|
+
const le = nt, _ = rt.merge(
|
|
621
621
|
le
|
|
622
622
|
).extend({
|
|
623
623
|
path: b.string().optional(),
|
|
624
624
|
definition: V().optional()
|
|
625
|
-
}),
|
|
625
|
+
}), Qe = it.merge(le), C = st.merge(le), tn = b.object({
|
|
626
626
|
op: b.enum(["ADD", "REPLACE", "REMOVE"]),
|
|
627
627
|
path: b.string(),
|
|
628
628
|
val: V().optional()
|
|
629
|
-
}),
|
|
630
|
-
|
|
629
|
+
}), Ri = gt("JsonPatch")(
|
|
630
|
+
tn
|
|
631
631
|
).superRefine((i, e) => {
|
|
632
632
|
i.op === "REMOVE" && i.val !== void 0 && e.addIssue({
|
|
633
633
|
code: b.ZodIssueCode.custom,
|
|
@@ -638,32 +638,32 @@ const le = et, _ = tt.merge(
|
|
|
638
638
|
message: `${i.op} operations must include a value`,
|
|
639
639
|
path: ["val"]
|
|
640
640
|
});
|
|
641
|
-
}),
|
|
641
|
+
}), nn = ot.merge(
|
|
642
642
|
_
|
|
643
|
-
),
|
|
643
|
+
), rn = at.merge(
|
|
644
644
|
_
|
|
645
|
-
),
|
|
645
|
+
), sn = ct.merge(
|
|
646
646
|
_
|
|
647
|
-
),
|
|
647
|
+
), on = lt.merge(_), an = wt.merge(
|
|
648
648
|
_
|
|
649
|
-
),
|
|
649
|
+
), cn = It.merge(_), ln = ut.merge(C).extend({
|
|
650
650
|
lastSignatures: b.record(b.string()).optional()
|
|
651
|
-
}),
|
|
651
|
+
}), un = dt.merge(C), dn = ht.merge(
|
|
652
652
|
C
|
|
653
|
-
),
|
|
653
|
+
), hn = ft.merge(C), fn = z.merge(
|
|
654
654
|
C
|
|
655
|
-
),
|
|
655
|
+
), pn = vt.merge(C), mn = kt.merge(
|
|
656
656
|
C
|
|
657
|
-
),
|
|
657
|
+
), gn = Tt.merge(C), En = Rt.merge(C), yn = Pt.merge(
|
|
658
658
|
C
|
|
659
|
-
),
|
|
659
|
+
), Pi = V(), wn = St.merge(Qe).extend({
|
|
660
660
|
steps: b.array(V()).optional()
|
|
661
|
-
}),
|
|
662
|
-
|
|
661
|
+
}), Sn = bt.merge(
|
|
662
|
+
Qe
|
|
663
663
|
).extend({
|
|
664
664
|
steps: b.array(V()).optional()
|
|
665
665
|
});
|
|
666
|
-
function
|
|
666
|
+
function bn(i) {
|
|
667
667
|
if (!Array.isArray(i.blueIds) || i.blueIds.length === 0)
|
|
668
668
|
throw new Error("Contract processors must declare at least one BlueId");
|
|
669
669
|
for (const e of i.blueIds)
|
|
@@ -671,11 +671,11 @@ function wn(i) {
|
|
|
671
671
|
throw new Error("Contract processor BlueIds must be non-empty strings");
|
|
672
672
|
}
|
|
673
673
|
function K(i, e) {
|
|
674
|
-
|
|
674
|
+
bn(i);
|
|
675
675
|
for (const t of i.blueIds)
|
|
676
676
|
e.set(t, i);
|
|
677
677
|
}
|
|
678
|
-
class
|
|
678
|
+
class Cn {
|
|
679
679
|
processorsByBlueId = /* @__PURE__ */ new Map();
|
|
680
680
|
handlerProcessors = /* @__PURE__ */ new Map();
|
|
681
681
|
channelProcessors = /* @__PURE__ */ new Map();
|
|
@@ -725,17 +725,27 @@ class Sn {
|
|
|
725
725
|
}
|
|
726
726
|
}
|
|
727
727
|
function Ce(i, e) {
|
|
728
|
+
return e && i.isTypeOf(e, v, { checkSchemaExtensions: !0 }) ? i.nodeToSchemaOutput(e, v) : null;
|
|
729
|
+
}
|
|
730
|
+
function Ye(i, e, t) {
|
|
731
|
+
const n = Ce(i, e), r = Ce(i, t);
|
|
732
|
+
if (!n || !r)
|
|
733
|
+
return !0;
|
|
734
|
+
const s = n.timestamp, o = r.timestamp;
|
|
735
|
+
return typeof s != "number" || typeof o != "number" ? !0 : s >= o;
|
|
736
|
+
}
|
|
737
|
+
function Ie(i, e) {
|
|
728
738
|
return i.isTypeOf(e, Ee) ? i.nodeToSchemaOutput(e, Ee) : i.isTypeOf(e, v) ? i.nodeToSchemaOutput(e, v) : null;
|
|
729
739
|
}
|
|
730
|
-
class
|
|
740
|
+
class In {
|
|
731
741
|
kind = "channel";
|
|
732
742
|
blueIds = [D["MyOS Timeline Channel"]];
|
|
733
|
-
schema =
|
|
743
|
+
schema = cn;
|
|
734
744
|
matches(e, t) {
|
|
735
745
|
const { event: n, blue: r } = t;
|
|
736
746
|
if (!n)
|
|
737
747
|
return !1;
|
|
738
|
-
const s =
|
|
748
|
+
const s = Ie(r, n);
|
|
739
749
|
if (!s)
|
|
740
750
|
return !1;
|
|
741
751
|
const o = s.timeline?.timelineId;
|
|
@@ -743,13 +753,17 @@ class bn {
|
|
|
743
753
|
}
|
|
744
754
|
channelize(e, t) {
|
|
745
755
|
const { event: n, blue: r } = t;
|
|
746
|
-
return !n || !
|
|
756
|
+
return !n || !Ie(r, n) ? null : n.clone();
|
|
757
|
+
}
|
|
758
|
+
isNewerEvent(e, t, n) {
|
|
759
|
+
const { event: r, blue: s } = t;
|
|
760
|
+
return r ? Ye(s, r, n) : !0;
|
|
747
761
|
}
|
|
748
762
|
}
|
|
749
|
-
class
|
|
763
|
+
class vn {
|
|
750
764
|
kind = "channel";
|
|
751
765
|
blueIds = [R["Timeline Channel"]];
|
|
752
|
-
schema =
|
|
766
|
+
schema = an;
|
|
753
767
|
matches(e, t) {
|
|
754
768
|
const { event: n, blue: r } = t;
|
|
755
769
|
if (!n || !r.isTypeOf(n, v))
|
|
@@ -761,9 +775,13 @@ class Cn {
|
|
|
761
775
|
const { event: n, blue: r } = t;
|
|
762
776
|
return !n || !r.isTypeOf(n, v) ? null : n.clone();
|
|
763
777
|
}
|
|
778
|
+
isNewerEvent(e, t, n) {
|
|
779
|
+
const { event: r, blue: s } = t;
|
|
780
|
+
return r ? Ye(s, r, n) : !0;
|
|
781
|
+
}
|
|
764
782
|
}
|
|
765
783
|
function ue(i) {
|
|
766
|
-
const { context: e, eventNode: t, stepResults: n } = i, r =
|
|
784
|
+
const { context: e, eventNode: t, stepResults: n } = i, r = Tn(e);
|
|
767
785
|
return {
|
|
768
786
|
event: e.blue.nodeToJson(t, "simple"),
|
|
769
787
|
eventCanonical: e.blue.nodeToJson(t, "official"),
|
|
@@ -771,13 +789,13 @@ function ue(i) {
|
|
|
771
789
|
document: r
|
|
772
790
|
};
|
|
773
791
|
}
|
|
774
|
-
const
|
|
775
|
-
function
|
|
792
|
+
const kn = /* @__PURE__ */ new Set(["blueId", "name", "description", "value"]);
|
|
793
|
+
function Tn(i) {
|
|
776
794
|
const e = (s) => {
|
|
777
795
|
if (s === "/")
|
|
778
796
|
return !1;
|
|
779
797
|
const o = s.lastIndexOf("/"), a = s.substring(o + 1);
|
|
780
|
-
return
|
|
798
|
+
return kn.has(a);
|
|
781
799
|
}, t = (s) => {
|
|
782
800
|
const o = s == null ? "/" : typeof s == "string" ? s : (() => {
|
|
783
801
|
throw new TypeError("document() expects a string pointer");
|
|
@@ -790,7 +808,7 @@ function kn(i) {
|
|
|
790
808
|
}, r = (s) => n(s, "simple");
|
|
791
809
|
return r.canonical = (s) => n(s, "official"), r;
|
|
792
810
|
}
|
|
793
|
-
class
|
|
811
|
+
class Rn {
|
|
794
812
|
supportedBlueIds = [R["Trigger Event"]];
|
|
795
813
|
evaluator = new ce();
|
|
796
814
|
async execute(e) {
|
|
@@ -802,10 +820,10 @@ class vn {
|
|
|
802
820
|
evaluator: this.evaluator,
|
|
803
821
|
node: t,
|
|
804
822
|
bindings: ue(e),
|
|
805
|
-
shouldResolve:
|
|
823
|
+
shouldResolve: je({
|
|
806
824
|
include: ["/event", "/event/**"]
|
|
807
825
|
}),
|
|
808
|
-
shouldDescend:
|
|
826
|
+
shouldDescend: Pn(),
|
|
809
827
|
context: n
|
|
810
828
|
}), o = n.blue.nodeToSchemaOutput(
|
|
811
829
|
r,
|
|
@@ -818,14 +836,14 @@ class vn {
|
|
|
818
836
|
n.emitEvent(o.clone());
|
|
819
837
|
}
|
|
820
838
|
}
|
|
821
|
-
function
|
|
822
|
-
return (i, e) => i === "/event" || !i.startsWith("/event/") ? !0 : !
|
|
839
|
+
function Pn() {
|
|
840
|
+
return (i, e) => i === "/event" || !i.startsWith("/event/") ? !0 : !Nn(e);
|
|
823
841
|
}
|
|
824
|
-
function
|
|
842
|
+
function Nn(i) {
|
|
825
843
|
const e = i.getProperties?.();
|
|
826
844
|
return e ? !!e.contracts : !1;
|
|
827
845
|
}
|
|
828
|
-
class
|
|
846
|
+
class Mn {
|
|
829
847
|
supportedBlueIds = [R["JavaScript Code"]];
|
|
830
848
|
evaluator = new ce();
|
|
831
849
|
async execute(e) {
|
|
@@ -849,7 +867,7 @@ class Pn {
|
|
|
849
867
|
});
|
|
850
868
|
return this.handleEvents(c, t), c;
|
|
851
869
|
} catch (c) {
|
|
852
|
-
throw new
|
|
870
|
+
throw new We(o, c);
|
|
853
871
|
}
|
|
854
872
|
}
|
|
855
873
|
handleEvents(e, t) {
|
|
@@ -863,7 +881,7 @@ class Pn {
|
|
|
863
881
|
}
|
|
864
882
|
}
|
|
865
883
|
}
|
|
866
|
-
class
|
|
884
|
+
class On {
|
|
867
885
|
supportedBlueIds = [R["Update Document"]];
|
|
868
886
|
evaluator = new ce();
|
|
869
887
|
async execute(e) {
|
|
@@ -874,7 +892,7 @@ class Nn {
|
|
|
874
892
|
evaluator: this.evaluator,
|
|
875
893
|
node: n,
|
|
876
894
|
bindings: ue(e),
|
|
877
|
-
shouldResolve:
|
|
895
|
+
shouldResolve: je({
|
|
878
896
|
include: ["/changeset", "/changeset/**"]
|
|
879
897
|
}),
|
|
880
898
|
context: t
|
|
@@ -909,11 +927,11 @@ class Nn {
|
|
|
909
927
|
}
|
|
910
928
|
}
|
|
911
929
|
const de = [
|
|
912
|
-
new
|
|
913
|
-
new
|
|
914
|
-
new
|
|
930
|
+
new Rn(),
|
|
931
|
+
new Mn(),
|
|
932
|
+
new On()
|
|
915
933
|
];
|
|
916
|
-
class
|
|
934
|
+
class Ze {
|
|
917
935
|
executorIndex;
|
|
918
936
|
constructor(e = de) {
|
|
919
937
|
const t = /* @__PURE__ */ new Map();
|
|
@@ -960,13 +978,13 @@ class Qe {
|
|
|
960
978
|
return n && typeof n == "string" && n.length > 0 ? n : `Step${t + 1}`;
|
|
961
979
|
}
|
|
962
980
|
}
|
|
963
|
-
class
|
|
981
|
+
class An {
|
|
964
982
|
kind = "handler";
|
|
965
983
|
blueIds = [R["Sequential Workflow"]];
|
|
966
|
-
schema =
|
|
984
|
+
schema = wn;
|
|
967
985
|
runner;
|
|
968
986
|
constructor(e = de) {
|
|
969
|
-
this.runner = new
|
|
987
|
+
this.runner = new Ze(e);
|
|
970
988
|
}
|
|
971
989
|
async matches(e, t) {
|
|
972
990
|
const n = t.event();
|
|
@@ -977,12 +995,12 @@ class Mn {
|
|
|
977
995
|
n && await this.runner.run({ workflow: e, eventNode: n, context: t });
|
|
978
996
|
}
|
|
979
997
|
}
|
|
980
|
-
class
|
|
998
|
+
class Dn {
|
|
981
999
|
kind = "marker";
|
|
982
1000
|
blueIds = [R.Operation];
|
|
983
|
-
schema =
|
|
1001
|
+
schema = fn;
|
|
984
1002
|
}
|
|
985
|
-
function
|
|
1003
|
+
function Xe(i) {
|
|
986
1004
|
const e = i.channel;
|
|
987
1005
|
if (typeof e == "string") {
|
|
988
1006
|
const t = e.trim();
|
|
@@ -991,11 +1009,11 @@ function Ye(i) {
|
|
|
991
1009
|
}
|
|
992
1010
|
return null;
|
|
993
1011
|
}
|
|
994
|
-
function
|
|
1012
|
+
function Bn(i, e) {
|
|
995
1013
|
const t = i.getProperties()?.document;
|
|
996
1014
|
return t instanceof d ? e.blue.calculateBlueIdSync(t) : null;
|
|
997
1015
|
}
|
|
998
|
-
function
|
|
1016
|
+
function _n(i, e) {
|
|
999
1017
|
if (e.isTypeOf(i, ne, {
|
|
1000
1018
|
checkSchemaExtensions: !0
|
|
1001
1019
|
}))
|
|
@@ -1011,11 +1029,11 @@ function Dn(i, e) {
|
|
|
1011
1029
|
}
|
|
1012
1030
|
return null;
|
|
1013
1031
|
}
|
|
1014
|
-
function
|
|
1032
|
+
function Ln(i, e, t, n) {
|
|
1015
1033
|
const { blue: r } = n, s = i.operation;
|
|
1016
1034
|
return !(!s || t.operation !== s || i.event && !r.isTypeOfNode(e, i.event));
|
|
1017
1035
|
}
|
|
1018
|
-
function
|
|
1036
|
+
function $n(i, e) {
|
|
1019
1037
|
const t = i.operation;
|
|
1020
1038
|
if (!t)
|
|
1021
1039
|
return null;
|
|
@@ -1025,13 +1043,13 @@ function _n(i, e) {
|
|
|
1025
1043
|
const s = e.blue.nodeToSchemaOutput(
|
|
1026
1044
|
r,
|
|
1027
1045
|
z
|
|
1028
|
-
), o =
|
|
1046
|
+
), o = Xe(s);
|
|
1029
1047
|
return { operationNode: r, operation: s, channelKey: o };
|
|
1030
1048
|
}
|
|
1031
|
-
function
|
|
1049
|
+
function xn(i, e) {
|
|
1032
1050
|
return !(i && e && i !== e);
|
|
1033
1051
|
}
|
|
1034
|
-
function
|
|
1052
|
+
function Fn(i, e, t) {
|
|
1035
1053
|
const n = i.getProperties()?.request, r = e.getProperties()?.request;
|
|
1036
1054
|
if (!(n instanceof d) || !(r instanceof d))
|
|
1037
1055
|
return !1;
|
|
@@ -1043,10 +1061,10 @@ function $n(i, e, t) {
|
|
|
1043
1061
|
}
|
|
1044
1062
|
return !0;
|
|
1045
1063
|
}
|
|
1046
|
-
function
|
|
1064
|
+
function zn(i, e, t) {
|
|
1047
1065
|
if (!i || i.allowNewerVersion !== !1)
|
|
1048
1066
|
return !0;
|
|
1049
|
-
const n =
|
|
1067
|
+
const n = Bn(e, t);
|
|
1050
1068
|
if (!n)
|
|
1051
1069
|
return !0;
|
|
1052
1070
|
const r = t.resolvePointer("/"), s = t.documentAt(r);
|
|
@@ -1055,15 +1073,15 @@ function xn(i, e, t) {
|
|
|
1055
1073
|
const c = (s.getContracts()?.initialized ?? null)?.get("/documentId") ?? null, l = typeof c == "string" && c.length > 0 ? c : t.blue.calculateBlueIdSync(s);
|
|
1056
1074
|
return n === l;
|
|
1057
1075
|
}
|
|
1058
|
-
class
|
|
1076
|
+
class Un {
|
|
1059
1077
|
kind = "handler";
|
|
1060
1078
|
blueIds = [
|
|
1061
1079
|
R["Sequential Workflow Operation"]
|
|
1062
1080
|
];
|
|
1063
|
-
schema =
|
|
1081
|
+
schema = Sn;
|
|
1064
1082
|
runner;
|
|
1065
1083
|
constructor(e = de) {
|
|
1066
|
-
this.runner = new
|
|
1084
|
+
this.runner = new Ze(e);
|
|
1067
1085
|
}
|
|
1068
1086
|
deriveChannel(e, t) {
|
|
1069
1087
|
const n = e.operation;
|
|
@@ -1075,13 +1093,13 @@ class Fn {
|
|
|
1075
1093
|
}))
|
|
1076
1094
|
return null;
|
|
1077
1095
|
const s = t.blue.nodeToSchemaOutput(r.node, z);
|
|
1078
|
-
return s ?
|
|
1096
|
+
return s ? Xe(s) : null;
|
|
1079
1097
|
}
|
|
1080
1098
|
async matches(e, t) {
|
|
1081
1099
|
const n = t.event();
|
|
1082
1100
|
if (!n)
|
|
1083
1101
|
return !1;
|
|
1084
|
-
const r =
|
|
1102
|
+
const r = _n(
|
|
1085
1103
|
n,
|
|
1086
1104
|
t.blue
|
|
1087
1105
|
);
|
|
@@ -1091,17 +1109,17 @@ class Fn {
|
|
|
1091
1109
|
r,
|
|
1092
1110
|
ne
|
|
1093
1111
|
);
|
|
1094
|
-
if (!s || !
|
|
1112
|
+
if (!s || !Ln(e, n, s, t))
|
|
1095
1113
|
return !1;
|
|
1096
|
-
const o =
|
|
1114
|
+
const o = $n(e, t);
|
|
1097
1115
|
if (!o)
|
|
1098
1116
|
return !1;
|
|
1099
1117
|
const a = typeof e.channel == "string" ? e.channel.trim() : "", c = a.length > 0 ? a : null;
|
|
1100
|
-
return !(!
|
|
1118
|
+
return !(!xn(o.channelKey, c) || !Fn(
|
|
1101
1119
|
r,
|
|
1102
1120
|
o.operationNode,
|
|
1103
1121
|
t.blue
|
|
1104
|
-
) || s?.allowNewerVersion === !1 && !
|
|
1122
|
+
) || s?.allowNewerVersion === !1 && !zn(s, r, t));
|
|
1105
1123
|
}
|
|
1106
1124
|
async execute(e, t) {
|
|
1107
1125
|
const n = t.event();
|
|
@@ -1118,11 +1136,11 @@ class Y {
|
|
|
1118
1136
|
}
|
|
1119
1137
|
static create() {
|
|
1120
1138
|
return new Y(
|
|
1121
|
-
new
|
|
1139
|
+
new Cn()
|
|
1122
1140
|
);
|
|
1123
1141
|
}
|
|
1124
1142
|
registerDefaults() {
|
|
1125
|
-
return this.registry.register(new
|
|
1143
|
+
return this.registry.register(new In()), this.registry.register(new vn()), this.registry.register(new An()), this.registry.register(new Dn()), this.registry.register(new Un()), this;
|
|
1126
1144
|
}
|
|
1127
1145
|
register(e) {
|
|
1128
1146
|
return this.registry.register(e), this;
|
|
@@ -1132,10 +1150,10 @@ class Y {
|
|
|
1132
1150
|
}
|
|
1133
1151
|
}
|
|
1134
1152
|
const se = m["Channel Event Checkpoint"];
|
|
1135
|
-
function
|
|
1153
|
+
function et(i) {
|
|
1136
1154
|
return typeof i.order == "number" ? i.order : 0;
|
|
1137
1155
|
}
|
|
1138
|
-
class
|
|
1156
|
+
class Vn {
|
|
1139
1157
|
constructor(e, t, n) {
|
|
1140
1158
|
this.bindingKey = e, this.bindingContract = t, this.bindingBlueId = n;
|
|
1141
1159
|
}
|
|
@@ -1149,10 +1167,10 @@ class zn {
|
|
|
1149
1167
|
return this.bindingBlueId;
|
|
1150
1168
|
}
|
|
1151
1169
|
order() {
|
|
1152
|
-
return
|
|
1170
|
+
return et(this.bindingContract);
|
|
1153
1171
|
}
|
|
1154
1172
|
}
|
|
1155
|
-
class
|
|
1173
|
+
class Hn {
|
|
1156
1174
|
constructor(e, t, n) {
|
|
1157
1175
|
this.bindingKey = e, this.bindingContract = t, this.bindingBlueId = n;
|
|
1158
1176
|
}
|
|
@@ -1166,16 +1184,16 @@ class Un {
|
|
|
1166
1184
|
return this.bindingBlueId;
|
|
1167
1185
|
}
|
|
1168
1186
|
order() {
|
|
1169
|
-
return
|
|
1187
|
+
return et(this.bindingContract);
|
|
1170
1188
|
}
|
|
1171
1189
|
}
|
|
1172
|
-
class
|
|
1190
|
+
class A {
|
|
1173
1191
|
constructor(e, t, n, r, s) {
|
|
1174
1192
|
this.channels = e, this.handlersByChannel = t, this.markerStore = n, this.embeddedPathsInternal = r, this.checkpointDeclared = s;
|
|
1175
1193
|
}
|
|
1176
1194
|
checkpointDeclared;
|
|
1177
1195
|
static fromComponents(e, t, n, r, s) {
|
|
1178
|
-
return new
|
|
1196
|
+
return new A(
|
|
1179
1197
|
e,
|
|
1180
1198
|
t,
|
|
1181
1199
|
n,
|
|
@@ -1184,10 +1202,10 @@ class O {
|
|
|
1184
1202
|
);
|
|
1185
1203
|
}
|
|
1186
1204
|
static builder() {
|
|
1187
|
-
return new
|
|
1205
|
+
return new Kn();
|
|
1188
1206
|
}
|
|
1189
1207
|
static empty() {
|
|
1190
|
-
return
|
|
1208
|
+
return A.builder().build();
|
|
1191
1209
|
}
|
|
1192
1210
|
markers() {
|
|
1193
1211
|
return new Map(
|
|
@@ -1226,7 +1244,7 @@ class O {
|
|
|
1226
1244
|
handlersFor(e) {
|
|
1227
1245
|
const t = this.handlersByChannel.get(e);
|
|
1228
1246
|
return !t || t.length === 0 ? [] : [...t].map(
|
|
1229
|
-
(n) => new
|
|
1247
|
+
(n) => new Hn(n.key, n.contract, n.blueId)
|
|
1230
1248
|
).sort((n, r) => {
|
|
1231
1249
|
const s = n.order() - r.order();
|
|
1232
1250
|
return s !== 0 ? s : n.key().localeCompare(r.key());
|
|
@@ -1234,7 +1252,7 @@ class O {
|
|
|
1234
1252
|
}
|
|
1235
1253
|
channelsOfType(...e) {
|
|
1236
1254
|
const t = e.length > 0 ? new Set(e) : null, n = Array.from(this.channels.values()).filter((r) => !t || t.has(r.blueId)).map(
|
|
1237
|
-
(r) => new
|
|
1255
|
+
(r) => new Vn(r.key, r.contract, r.blueId)
|
|
1238
1256
|
);
|
|
1239
1257
|
return n.sort((r, s) => {
|
|
1240
1258
|
const o = r.order() - s.order();
|
|
@@ -1242,7 +1260,7 @@ class O {
|
|
|
1242
1260
|
}), n;
|
|
1243
1261
|
}
|
|
1244
1262
|
}
|
|
1245
|
-
class
|
|
1263
|
+
class Kn {
|
|
1246
1264
|
channels = /* @__PURE__ */ new Map();
|
|
1247
1265
|
handlersByChannel = /* @__PURE__ */ new Map();
|
|
1248
1266
|
markerStore = /* @__PURE__ */ new Map();
|
|
@@ -1285,7 +1303,7 @@ class Vn {
|
|
|
1285
1303
|
return this.markerStore.set(e, { key: e, contract: t, blueId: n }), this;
|
|
1286
1304
|
}
|
|
1287
1305
|
build() {
|
|
1288
|
-
return
|
|
1306
|
+
return A.fromComponents(
|
|
1289
1307
|
new Map(this.channels),
|
|
1290
1308
|
new Map(
|
|
1291
1309
|
Array.from(this.handlersByChannel.entries(), ([e, t]) => [
|
|
@@ -1304,7 +1322,7 @@ class g extends Error {
|
|
|
1304
1322
|
super(e || "Processor fatal error"), this.processorError = t, this.name = "ProcessorFatalError";
|
|
1305
1323
|
}
|
|
1306
1324
|
}
|
|
1307
|
-
class
|
|
1325
|
+
class Wn {
|
|
1308
1326
|
constructor(e, t, n) {
|
|
1309
1327
|
this.blue = e, this.registry = t, this.builtinChannelSchemas = n;
|
|
1310
1328
|
}
|
|
@@ -1393,7 +1411,7 @@ class Hn {
|
|
|
1393
1411
|
return this.builtinChannelSchemas.has(e) ? !0 : this.registry.lookupChannel(e) != null;
|
|
1394
1412
|
}
|
|
1395
1413
|
isZodError(e) {
|
|
1396
|
-
return e instanceof
|
|
1414
|
+
return e instanceof Me;
|
|
1397
1415
|
}
|
|
1398
1416
|
}
|
|
1399
1417
|
class U extends Error {
|
|
@@ -1401,15 +1419,7 @@ class U extends Error {
|
|
|
1401
1419
|
super(e ?? "MustUnderstand failure"), this.name = "MustUnderstandFailure";
|
|
1402
1420
|
}
|
|
1403
1421
|
}
|
|
1404
|
-
const
|
|
1405
|
-
[
|
|
1406
|
-
Kn,
|
|
1407
|
-
en
|
|
1408
|
-
],
|
|
1409
|
-
[
|
|
1410
|
-
Wn,
|
|
1411
|
-
tn
|
|
1412
|
-
],
|
|
1422
|
+
const Gn = m["Document Update Channel"], qn = m["Embedded Node Channel"], Jn = m["Lifecycle Event Channel"], jn = m["Triggered Event Channel"], ve = m["Process Embedded"], Qn = m["Processing Initialized Marker"], Yn = m["Processing Terminated Marker"], Zn = m["Channel Event Checkpoint"], Xn = D["Document Anchors"], er = D["Document Links"], tr = D["MyOS Participants Orchestration"], nr = D["MyOS Session Interaction"], rr = D["MyOS Worker Agency"], ke = /* @__PURE__ */ new Map([
|
|
1413
1423
|
[
|
|
1414
1424
|
Gn,
|
|
1415
1425
|
nn
|
|
@@ -1417,19 +1427,19 @@ const Kn = m["Document Update Channel"], Wn = m["Embedded Node Channel"], Gn = m
|
|
|
1417
1427
|
[
|
|
1418
1428
|
qn,
|
|
1419
1429
|
rn
|
|
1420
|
-
]
|
|
1421
|
-
]), nr = /* @__PURE__ */ new Map([
|
|
1430
|
+
],
|
|
1422
1431
|
[
|
|
1423
1432
|
Jn,
|
|
1424
|
-
|
|
1433
|
+
sn
|
|
1425
1434
|
],
|
|
1426
1435
|
[
|
|
1427
1436
|
jn,
|
|
1428
|
-
|
|
1429
|
-
]
|
|
1437
|
+
on
|
|
1438
|
+
]
|
|
1439
|
+
]), ir = /* @__PURE__ */ new Map([
|
|
1430
1440
|
[
|
|
1431
1441
|
Qn,
|
|
1432
|
-
|
|
1442
|
+
un
|
|
1433
1443
|
],
|
|
1434
1444
|
[
|
|
1435
1445
|
Yn,
|
|
@@ -1437,7 +1447,7 @@ const Kn = m["Document Update Channel"], Wn = m["Embedded Node Channel"], Gn = m
|
|
|
1437
1447
|
],
|
|
1438
1448
|
[
|
|
1439
1449
|
Zn,
|
|
1440
|
-
|
|
1450
|
+
ln
|
|
1441
1451
|
],
|
|
1442
1452
|
[
|
|
1443
1453
|
Xn,
|
|
@@ -1450,11 +1460,19 @@ const Kn = m["Document Update Channel"], Wn = m["Embedded Node Channel"], Gn = m
|
|
|
1450
1460
|
[
|
|
1451
1461
|
tr,
|
|
1452
1462
|
gn
|
|
1463
|
+
],
|
|
1464
|
+
[
|
|
1465
|
+
nr,
|
|
1466
|
+
En
|
|
1467
|
+
],
|
|
1468
|
+
[
|
|
1469
|
+
rr,
|
|
1470
|
+
yn
|
|
1453
1471
|
]
|
|
1454
1472
|
]);
|
|
1455
|
-
class
|
|
1473
|
+
class sr {
|
|
1456
1474
|
constructor(e, t) {
|
|
1457
|
-
this.registry = e, this.blue = t, this.handlerRegistration = new
|
|
1475
|
+
this.registry = e, this.blue = t, this.handlerRegistration = new Wn(
|
|
1458
1476
|
this.blue,
|
|
1459
1477
|
this.registry,
|
|
1460
1478
|
ke
|
|
@@ -1463,7 +1481,7 @@ class rr {
|
|
|
1463
1481
|
handlerRegistration;
|
|
1464
1482
|
load(e, t) {
|
|
1465
1483
|
try {
|
|
1466
|
-
const n =
|
|
1484
|
+
const n = A.builder(), r = e.getContracts();
|
|
1467
1485
|
if (!r)
|
|
1468
1486
|
return n.build();
|
|
1469
1487
|
const s = this.buildScopeContractsIndex(r);
|
|
@@ -1487,11 +1505,11 @@ class rr {
|
|
|
1487
1505
|
const s = n.getType()?.getBlueId();
|
|
1488
1506
|
if (!s)
|
|
1489
1507
|
return;
|
|
1490
|
-
if (s ===
|
|
1508
|
+
if (s === ve) {
|
|
1491
1509
|
this.handleProcessEmbedded(e, t, n);
|
|
1492
1510
|
return;
|
|
1493
1511
|
}
|
|
1494
|
-
const o =
|
|
1512
|
+
const o = ir.get(s);
|
|
1495
1513
|
if (o) {
|
|
1496
1514
|
this.handleMarker(e, t, n, o, s);
|
|
1497
1515
|
return;
|
|
@@ -1548,14 +1566,14 @@ class rr {
|
|
|
1548
1566
|
try {
|
|
1549
1567
|
const r = this.convert(
|
|
1550
1568
|
n,
|
|
1551
|
-
|
|
1569
|
+
dn
|
|
1552
1570
|
);
|
|
1553
1571
|
e.setEmbedded(r);
|
|
1554
1572
|
} catch (r) {
|
|
1555
1573
|
throw ee(r) ? new g(
|
|
1556
1574
|
"Failed to parse ProcessEmbedded marker",
|
|
1557
1575
|
E.invalidContract(
|
|
1558
|
-
|
|
1576
|
+
ve,
|
|
1559
1577
|
"Failed to parse ProcessEmbedded marker",
|
|
1560
1578
|
t,
|
|
1561
1579
|
r
|
|
@@ -1627,26 +1645,26 @@ class rr {
|
|
|
1627
1645
|
}
|
|
1628
1646
|
}
|
|
1629
1647
|
function ee(i) {
|
|
1630
|
-
return i instanceof
|
|
1648
|
+
return i instanceof Me;
|
|
1631
1649
|
}
|
|
1632
|
-
const
|
|
1633
|
-
function
|
|
1650
|
+
const or = m["Channel Event Checkpoint"];
|
|
1651
|
+
function ar(i) {
|
|
1634
1652
|
return i.jsonValueToNode({
|
|
1635
|
-
type: { blueId:
|
|
1653
|
+
type: { blueId: or },
|
|
1636
1654
|
lastEvents: {},
|
|
1637
1655
|
lastSignatures: {}
|
|
1638
1656
|
});
|
|
1639
1657
|
}
|
|
1640
|
-
function
|
|
1658
|
+
function cr() {
|
|
1641
1659
|
return {
|
|
1642
1660
|
lastEvents: {},
|
|
1643
1661
|
lastSignatures: {}
|
|
1644
1662
|
};
|
|
1645
1663
|
}
|
|
1646
|
-
function
|
|
1664
|
+
function Te(i) {
|
|
1647
1665
|
return i != null && Object.prototype.hasOwnProperty.call(i, "lastEvents") && Object.prototype.hasOwnProperty.call(i, "lastSignatures");
|
|
1648
1666
|
}
|
|
1649
|
-
class
|
|
1667
|
+
class lr {
|
|
1650
1668
|
constructor(e, t, n, r, s) {
|
|
1651
1669
|
this.markerKey = e, this.checkpoint = t, this.channelKey = n, this.lastEventNode = r, this.lastEventSignature = s;
|
|
1652
1670
|
}
|
|
@@ -1656,28 +1674,28 @@ class ar {
|
|
|
1656
1674
|
return e != null && e === this.lastEventSignature;
|
|
1657
1675
|
}
|
|
1658
1676
|
}
|
|
1659
|
-
class
|
|
1677
|
+
class ur {
|
|
1660
1678
|
constructor(e, t) {
|
|
1661
1679
|
this.runtime = e, this.signatureFn = t;
|
|
1662
1680
|
}
|
|
1663
1681
|
ensureCheckpointMarker(e, t) {
|
|
1664
|
-
const n = t.marker(T), r = w(e,
|
|
1682
|
+
const n = t.marker(T), r = w(e, $e);
|
|
1665
1683
|
if (!n) {
|
|
1666
|
-
const s =
|
|
1667
|
-
this.runtime.directWrite(r, s), t.registerCheckpointMarker(
|
|
1684
|
+
const s = ar(this.runtime.blue());
|
|
1685
|
+
this.runtime.directWrite(r, s), t.registerCheckpointMarker(cr());
|
|
1668
1686
|
return;
|
|
1669
1687
|
}
|
|
1670
|
-
if (!
|
|
1688
|
+
if (!Te(n))
|
|
1671
1689
|
throw new Error(
|
|
1672
1690
|
`Reserved key 'checkpoint' must contain a Channel Event Checkpoint at ${r}`
|
|
1673
1691
|
);
|
|
1674
1692
|
}
|
|
1675
1693
|
findCheckpoint(e, t) {
|
|
1676
1694
|
for (const [n, r] of e.markerEntries()) {
|
|
1677
|
-
if (!
|
|
1695
|
+
if (!Te(r))
|
|
1678
1696
|
continue;
|
|
1679
1697
|
const o = (r.lastEvents?.[t] ?? null)?.clone() ?? null, c = r.lastSignatures?.[t] ?? null ?? this.signatureFn(o);
|
|
1680
|
-
return new
|
|
1698
|
+
return new lr(
|
|
1681
1699
|
n,
|
|
1682
1700
|
r,
|
|
1683
1701
|
t,
|
|
@@ -1695,17 +1713,17 @@ class cr {
|
|
|
1695
1713
|
return;
|
|
1696
1714
|
const o = w(
|
|
1697
1715
|
e,
|
|
1698
|
-
|
|
1716
|
+
ze(n.markerKey, n.channelKey)
|
|
1699
1717
|
), a = s?.clone() ?? null;
|
|
1700
1718
|
this.runtime.gasMeter().chargeCheckpointUpdate(), this.runtime.directWrite(o, a), n.checkpoint.lastEvents || (n.checkpoint.lastEvents = {}), a ? n.checkpoint.lastEvents[n.channelKey] = a.clone() ?? null : delete n.checkpoint.lastEvents[n.channelKey], n.lastEventNode = a?.clone() ?? null;
|
|
1701
1719
|
const c = w(
|
|
1702
1720
|
e,
|
|
1703
|
-
|
|
1721
|
+
Ue(n.markerKey, n.channelKey)
|
|
1704
1722
|
), l = r == null ? null : new d().setValue(r);
|
|
1705
1723
|
this.runtime.directWrite(c, l), n.checkpoint.lastSignatures || (n.checkpoint.lastSignatures = {}), r == null ? delete n.checkpoint.lastSignatures[n.channelKey] : n.checkpoint.lastSignatures[n.channelKey] = r, n.lastEventSignature = r ?? null;
|
|
1706
1724
|
}
|
|
1707
1725
|
}
|
|
1708
|
-
class
|
|
1726
|
+
class dr {
|
|
1709
1727
|
constructor(e, t, n) {
|
|
1710
1728
|
this.runtime = e, this.checkpointManager = t, this.deps = n;
|
|
1711
1729
|
}
|
|
@@ -1727,7 +1745,13 @@ class lr {
|
|
|
1727
1745
|
t,
|
|
1728
1746
|
n.key()
|
|
1729
1747
|
), l = o.eventId ?? this.deps.canonicalSignature(s);
|
|
1730
|
-
this.checkpointManager.isDuplicate(c, l) ||
|
|
1748
|
+
this.checkpointManager.isDuplicate(c, l) || !await this.shouldProcessRelativeToCheckpoint(
|
|
1749
|
+
e,
|
|
1750
|
+
t,
|
|
1751
|
+
n,
|
|
1752
|
+
s,
|
|
1753
|
+
c
|
|
1754
|
+
) || (await this.runHandlers(
|
|
1731
1755
|
e,
|
|
1732
1756
|
t,
|
|
1733
1757
|
n.key(),
|
|
@@ -1764,11 +1788,30 @@ class lr {
|
|
|
1764
1788
|
}
|
|
1765
1789
|
}
|
|
1766
1790
|
}
|
|
1791
|
+
async shouldProcessRelativeToCheckpoint(e, t, n, r, s) {
|
|
1792
|
+
if (!s?.lastEventNode)
|
|
1793
|
+
return !0;
|
|
1794
|
+
const o = this.deps.channelProcessorFor(n.blueId());
|
|
1795
|
+
if (!o || typeof o.isNewerEvent != "function")
|
|
1796
|
+
return !0;
|
|
1797
|
+
const a = {
|
|
1798
|
+
scopePath: e,
|
|
1799
|
+
blue: this.runtime.blue(),
|
|
1800
|
+
event: r.clone(),
|
|
1801
|
+
markers: t.markers(),
|
|
1802
|
+
bindingKey: n.key()
|
|
1803
|
+
};
|
|
1804
|
+
return await o.isNewerEvent(
|
|
1805
|
+
n.contract(),
|
|
1806
|
+
a,
|
|
1807
|
+
s.lastEventNode.clone()
|
|
1808
|
+
);
|
|
1809
|
+
}
|
|
1767
1810
|
}
|
|
1768
|
-
function
|
|
1811
|
+
function hr(i, e) {
|
|
1769
1812
|
return e.isResolved() ? i.createResolvedNode(e) : i.resolve(e);
|
|
1770
1813
|
}
|
|
1771
|
-
class
|
|
1814
|
+
class O extends g {
|
|
1772
1815
|
constructor(e) {
|
|
1773
1816
|
super(e, E.illegalState(e)), this.name = "IllegalStateException";
|
|
1774
1817
|
}
|
|
@@ -1778,8 +1821,8 @@ class N extends Error {
|
|
|
1778
1821
|
super(e), this.name = "BoundaryViolationException";
|
|
1779
1822
|
}
|
|
1780
1823
|
}
|
|
1781
|
-
const
|
|
1782
|
-
class
|
|
1824
|
+
const fr = m["Document Update Channel"], pr = m["Embedded Node Channel"], mr = m["Triggered Event Channel"], gr = m["Lifecycle Event Channel"], Re = m["Processing Initialized Marker"], Er = m["Document Processing Initiated"];
|
|
1825
|
+
class yr {
|
|
1783
1826
|
runtime;
|
|
1784
1827
|
contractLoader;
|
|
1785
1828
|
channelRunner;
|
|
@@ -1811,7 +1854,7 @@ class gr {
|
|
|
1811
1854
|
return;
|
|
1812
1855
|
const a = this.hasInitializationMarker(n);
|
|
1813
1856
|
if (!a && s.hasCheckpoint())
|
|
1814
|
-
throw new
|
|
1857
|
+
throw new O(
|
|
1815
1858
|
`Reserved key 'checkpoint' must not appear before initialization at scope ${n}`
|
|
1816
1859
|
);
|
|
1817
1860
|
if (a)
|
|
@@ -1830,7 +1873,7 @@ class gr {
|
|
|
1830
1873
|
const t = y(e);
|
|
1831
1874
|
if (this.bundles.has(t))
|
|
1832
1875
|
return;
|
|
1833
|
-
const n = this.nodeAt(t), r = n ? this.loadBundle(n, t) :
|
|
1876
|
+
const n = this.nodeAt(t), r = n ? this.loadBundle(n, t) : A.empty();
|
|
1834
1877
|
this.bundles.set(t, r);
|
|
1835
1878
|
for (const s of r.embeddedPaths()) {
|
|
1836
1879
|
const o = w(t, s);
|
|
@@ -1838,7 +1881,7 @@ class gr {
|
|
|
1838
1881
|
}
|
|
1839
1882
|
}
|
|
1840
1883
|
async processExternalEvent(e, t) {
|
|
1841
|
-
const n =
|
|
1884
|
+
const n = hr(this.runtime.blue(), t);
|
|
1842
1885
|
await this.processPreparedExternalEvent(e, n);
|
|
1843
1886
|
}
|
|
1844
1887
|
async processPreparedExternalEvent(e, t) {
|
|
@@ -1904,7 +1947,7 @@ class gr {
|
|
|
1904
1947
|
if (!a || this.hooks.isScopeInactive(o))
|
|
1905
1948
|
continue;
|
|
1906
1949
|
const c = this.createDocumentUpdateEvent(s, o), l = a.channelsOfType(
|
|
1907
|
-
|
|
1950
|
+
fr
|
|
1908
1951
|
);
|
|
1909
1952
|
for (const u of l) {
|
|
1910
1953
|
const f = u.contract();
|
|
@@ -1928,7 +1971,7 @@ class gr {
|
|
|
1928
1971
|
await this.hooks.enterFatalTermination(e, t, o);
|
|
1929
1972
|
return;
|
|
1930
1973
|
}
|
|
1931
|
-
if (s instanceof
|
|
1974
|
+
if (s instanceof O || s instanceof Error && !(s instanceof g)) {
|
|
1932
1975
|
const o = this.hooks.fatalReason(s, "Runtime fatal");
|
|
1933
1976
|
await this.hooks.enterFatalTermination(e, t, o);
|
|
1934
1977
|
return;
|
|
@@ -1941,7 +1984,7 @@ class gr {
|
|
|
1941
1984
|
if (this.runtime.gasMeter().chargeLifecycleDelivery(), await this.hooks.recordLifecycleForBridging(e, n), !t)
|
|
1942
1985
|
return;
|
|
1943
1986
|
const s = t.channelsOfType(
|
|
1944
|
-
|
|
1987
|
+
gr
|
|
1945
1988
|
);
|
|
1946
1989
|
for (const o of s)
|
|
1947
1990
|
if (await this.channelRunner.runHandlers(
|
|
@@ -2003,7 +2046,7 @@ class gr {
|
|
|
2003
2046
|
}
|
|
2004
2047
|
}
|
|
2005
2048
|
async addInitializationMarker(e, t) {
|
|
2006
|
-
const n = new d().setType(new d().setBlueId(
|
|
2049
|
+
const n = new d().setType(new d().setBlueId(Re)).addProperty("documentId", new d().setValue(t)), r = e.resolvePointer(ie);
|
|
2007
2050
|
await e.applyPatch({
|
|
2008
2051
|
op: "ADD",
|
|
2009
2052
|
path: r,
|
|
@@ -2017,7 +2060,7 @@ class gr {
|
|
|
2017
2060
|
if (this.hooks.isScopeInactive(e) || t.embeddedPaths().length === 0)
|
|
2018
2061
|
return;
|
|
2019
2062
|
const n = t.channelsOfType(
|
|
2020
|
-
|
|
2063
|
+
pr
|
|
2021
2064
|
);
|
|
2022
2065
|
if (n.length !== 0)
|
|
2023
2066
|
for (const r of t.embeddedPaths()) {
|
|
@@ -2042,7 +2085,7 @@ class gr {
|
|
|
2042
2085
|
if (this.hooks.isScopeInactive(e))
|
|
2043
2086
|
return;
|
|
2044
2087
|
const n = this.runtime.scope(e), r = t.channelsOfType(
|
|
2045
|
-
|
|
2088
|
+
mr
|
|
2046
2089
|
);
|
|
2047
2090
|
if (r.length === 0) {
|
|
2048
2091
|
n.clearTriggered();
|
|
@@ -2119,16 +2162,16 @@ class gr {
|
|
|
2119
2162
|
return !1;
|
|
2120
2163
|
if (!(n instanceof d)) {
|
|
2121
2164
|
const s = `Reserved key 'initialized' must contain a Processing Initialized Marker at ${t}`;
|
|
2122
|
-
throw new
|
|
2165
|
+
throw new O(s);
|
|
2123
2166
|
}
|
|
2124
|
-
if (n.getType()?.getBlueId() !==
|
|
2167
|
+
if (n.getType()?.getBlueId() !== Re) {
|
|
2125
2168
|
const s = `Reserved key 'initialized' must contain a Processing Initialized Marker at ${t}`;
|
|
2126
|
-
throw new
|
|
2169
|
+
throw new O(s);
|
|
2127
2170
|
}
|
|
2128
2171
|
return !0;
|
|
2129
2172
|
}
|
|
2130
2173
|
createLifecycleEvent(e) {
|
|
2131
|
-
return new d().setType(new d().setBlueId(
|
|
2174
|
+
return new d().setType(new d().setBlueId(Er)).setProperties({
|
|
2132
2175
|
type: new d().setValue("Document Processing Initiated"),
|
|
2133
2176
|
documentId: new d().setValue(e)
|
|
2134
2177
|
});
|
|
@@ -2141,19 +2184,19 @@ class J extends Error {
|
|
|
2141
2184
|
), this.fatal = e, this.name = "RunTerminationError";
|
|
2142
2185
|
}
|
|
2143
2186
|
}
|
|
2144
|
-
const
|
|
2145
|
-
class
|
|
2187
|
+
const wr = m["Processing Terminated Marker"], Sr = m["Document Processing Terminated"];
|
|
2188
|
+
class br {
|
|
2146
2189
|
constructor(e) {
|
|
2147
2190
|
this.runtime = e;
|
|
2148
2191
|
}
|
|
2149
2192
|
async terminateScope(e, t, n, r, s) {
|
|
2150
2193
|
e.recordPendingTermination(t, r, s ?? null);
|
|
2151
|
-
const o = e.normalizeScope(t), a = w(o,
|
|
2194
|
+
const o = e.normalizeScope(t), a = w(o, Le);
|
|
2152
2195
|
this.runtime.directWrite(
|
|
2153
2196
|
a,
|
|
2154
|
-
|
|
2197
|
+
Cr(this.runtime.blue(), r, s)
|
|
2155
2198
|
), this.runtime.gasMeter().chargeTerminationMarker();
|
|
2156
|
-
const c = n ?? e.bundleForScope(o) ?? null, l =
|
|
2199
|
+
const c = n ?? e.bundleForScope(o) ?? null, l = Ir(r, s);
|
|
2157
2200
|
if (await e.deliverLifecycle(
|
|
2158
2201
|
o,
|
|
2159
2202
|
c,
|
|
@@ -2165,32 +2208,32 @@ class wr {
|
|
|
2165
2208
|
throw this.runtime.markRunTerminated(), new J(!1);
|
|
2166
2209
|
}
|
|
2167
2210
|
}
|
|
2168
|
-
function
|
|
2169
|
-
return
|
|
2170
|
-
type: { blueId:
|
|
2211
|
+
function Cr(i, e, t) {
|
|
2212
|
+
return vr(i, {
|
|
2213
|
+
type: { blueId: wr },
|
|
2171
2214
|
cause: e === "GRACEFUL" ? "graceful" : "fatal",
|
|
2172
2215
|
...t ? { reason: t } : {}
|
|
2173
2216
|
});
|
|
2174
2217
|
}
|
|
2175
|
-
function
|
|
2218
|
+
function Ir(i, e) {
|
|
2176
2219
|
const t = new d().setType(
|
|
2177
|
-
new d().setBlueId(
|
|
2220
|
+
new d().setBlueId(Sr)
|
|
2178
2221
|
);
|
|
2179
2222
|
return t.addProperty(
|
|
2180
2223
|
"cause",
|
|
2181
2224
|
new d().setValue(i === "GRACEFUL" ? "graceful" : "fatal")
|
|
2182
2225
|
), e && t.addProperty("reason", new d().setValue(e)), t;
|
|
2183
2226
|
}
|
|
2184
|
-
function
|
|
2227
|
+
function vr(i, e) {
|
|
2185
2228
|
return i.jsonValueToNode(e);
|
|
2186
2229
|
}
|
|
2187
2230
|
const F = "-";
|
|
2188
|
-
class
|
|
2231
|
+
class kr {
|
|
2189
2232
|
constructor(e) {
|
|
2190
2233
|
this.document = e;
|
|
2191
2234
|
}
|
|
2192
2235
|
applyPatch(e, t) {
|
|
2193
|
-
const n = y(e), r = S(t.path), s =
|
|
2236
|
+
const n = y(e), r = S(t.path), s = Ne(r), o = Pe(this.document, s, "before", r);
|
|
2194
2237
|
switch (t.op) {
|
|
2195
2238
|
case "ADD":
|
|
2196
2239
|
this.applyAdd(s, r, t.val ?? null);
|
|
@@ -2202,21 +2245,21 @@ class Ir {
|
|
|
2202
2245
|
this.applyRemove(s, r);
|
|
2203
2246
|
break;
|
|
2204
2247
|
}
|
|
2205
|
-
const a = t.op === "REMOVE" ? null :
|
|
2248
|
+
const a = t.op === "REMOVE" ? null : Pe(this.document, s, "after", r);
|
|
2206
2249
|
return {
|
|
2207
2250
|
path: r,
|
|
2208
2251
|
before: o,
|
|
2209
2252
|
after: a,
|
|
2210
2253
|
op: t.op.toLowerCase(),
|
|
2211
2254
|
originScope: n,
|
|
2212
|
-
cascadeScopes:
|
|
2255
|
+
cascadeScopes: Tr(n)
|
|
2213
2256
|
};
|
|
2214
2257
|
}
|
|
2215
2258
|
directWrite(e, t) {
|
|
2216
2259
|
const n = S(e);
|
|
2217
2260
|
if (n === "/")
|
|
2218
2261
|
throw new Error("Direct write cannot target root document");
|
|
2219
|
-
const r =
|
|
2262
|
+
const r = Ne(n), { parent: s, leaf: o } = this.resolveParent(r);
|
|
2220
2263
|
if (o === F)
|
|
2221
2264
|
throw new Error(
|
|
2222
2265
|
`Direct write does not support append token '-' for path ${n}`
|
|
@@ -2410,7 +2453,7 @@ class Ir {
|
|
|
2410
2453
|
}
|
|
2411
2454
|
}
|
|
2412
2455
|
}
|
|
2413
|
-
function
|
|
2456
|
+
function Tr(i) {
|
|
2414
2457
|
const e = [];
|
|
2415
2458
|
let t = i;
|
|
2416
2459
|
for (; e.push(t), t !== "/"; ) {
|
|
@@ -2419,26 +2462,26 @@ function kr(i) {
|
|
|
2419
2462
|
}
|
|
2420
2463
|
return e;
|
|
2421
2464
|
}
|
|
2422
|
-
function
|
|
2465
|
+
function Pe(i, e, t, n) {
|
|
2423
2466
|
try {
|
|
2424
2467
|
if (e.length === 0)
|
|
2425
2468
|
return i.clone();
|
|
2426
|
-
const r =
|
|
2469
|
+
const r = Rr(i, e, t, n);
|
|
2427
2470
|
return r ? r.clone() : null;
|
|
2428
2471
|
} catch {
|
|
2429
2472
|
return null;
|
|
2430
2473
|
}
|
|
2431
2474
|
}
|
|
2432
|
-
function
|
|
2475
|
+
function Rr(i, e, t, n) {
|
|
2433
2476
|
let r = i;
|
|
2434
2477
|
for (let s = 0; s < e.length; s += 1) {
|
|
2435
2478
|
const o = e[s] ?? "", a = s === e.length - 1;
|
|
2436
|
-
if (r =
|
|
2479
|
+
if (r = Pr(r, o, a, t, n), !r)
|
|
2437
2480
|
return null;
|
|
2438
2481
|
}
|
|
2439
2482
|
return r;
|
|
2440
2483
|
}
|
|
2441
|
-
function
|
|
2484
|
+
function Pr(i, e, t, n, r) {
|
|
2442
2485
|
if (!i)
|
|
2443
2486
|
return null;
|
|
2444
2487
|
const s = i.getItems();
|
|
@@ -2457,7 +2500,7 @@ function Tr(i, e, t, n, r) {
|
|
|
2457
2500
|
const a = o[e];
|
|
2458
2501
|
return a instanceof d ? a : null;
|
|
2459
2502
|
}
|
|
2460
|
-
function
|
|
2503
|
+
function Ne(i) {
|
|
2461
2504
|
if (i === "/" || i === "")
|
|
2462
2505
|
return [];
|
|
2463
2506
|
const e = i.startsWith("/") ? i.slice(1) : i;
|
|
@@ -2499,7 +2542,7 @@ function M(i) {
|
|
|
2499
2542
|
function $(i) {
|
|
2500
2543
|
return i == null ? new d().setValue(null) : i.clone();
|
|
2501
2544
|
}
|
|
2502
|
-
class
|
|
2545
|
+
class Nr {
|
|
2503
2546
|
constructor(e) {
|
|
2504
2547
|
this.path = e;
|
|
2505
2548
|
}
|
|
@@ -2561,7 +2604,7 @@ class Rr {
|
|
|
2561
2604
|
return this.cutOff;
|
|
2562
2605
|
}
|
|
2563
2606
|
}
|
|
2564
|
-
class
|
|
2607
|
+
class Mr {
|
|
2565
2608
|
scopesMap = /* @__PURE__ */ new Map();
|
|
2566
2609
|
rootEmissionList = [];
|
|
2567
2610
|
scopes() {
|
|
@@ -2569,7 +2612,7 @@ class Pr {
|
|
|
2569
2612
|
}
|
|
2570
2613
|
scope(e) {
|
|
2571
2614
|
let t = this.scopesMap.get(e);
|
|
2572
|
-
return t || (t = new
|
|
2615
|
+
return t || (t = new Nr(e), this.scopesMap.set(e, t)), t;
|
|
2573
2616
|
}
|
|
2574
2617
|
existingScope(e) {
|
|
2575
2618
|
return this.scopesMap.get(e);
|
|
@@ -2593,39 +2636,39 @@ function H(i) {
|
|
|
2593
2636
|
function he(i) {
|
|
2594
2637
|
return new TextEncoder().encode(i).length;
|
|
2595
2638
|
}
|
|
2596
|
-
function
|
|
2639
|
+
function Or(i) {
|
|
2597
2640
|
const e = S(i);
|
|
2598
2641
|
return e === "/" ? 0 : e.split("/").length - 1;
|
|
2599
2642
|
}
|
|
2600
|
-
function
|
|
2643
|
+
function Ar(i) {
|
|
2601
2644
|
return 100 + H(he(i));
|
|
2602
2645
|
}
|
|
2603
|
-
function
|
|
2646
|
+
function Dr(i) {
|
|
2604
2647
|
return 40 + 5 * Math.max(0, i);
|
|
2605
2648
|
}
|
|
2606
|
-
function
|
|
2649
|
+
function Br(i) {
|
|
2607
2650
|
return 5 + H(he(i));
|
|
2608
2651
|
}
|
|
2609
|
-
function
|
|
2652
|
+
function _r(i, e) {
|
|
2610
2653
|
return 3 * Math.max(0, i) + H(he(e));
|
|
2611
2654
|
}
|
|
2612
|
-
function
|
|
2613
|
-
return 8 +
|
|
2655
|
+
function Lr(i, e) {
|
|
2656
|
+
return 8 + Or(i) + H(e);
|
|
2614
2657
|
}
|
|
2615
|
-
const
|
|
2616
|
-
function
|
|
2658
|
+
const $r = 1e3, xr = 5, Fr = 50, zr = 2, Ur = 10, Vr = 10, Hr = 10, Kr = 20, Wr = 20, Gr = 30, qr = 30, Jr = 100;
|
|
2659
|
+
function jr(i) {
|
|
2617
2660
|
return 50 + 10 * i;
|
|
2618
2661
|
}
|
|
2619
|
-
function
|
|
2662
|
+
function Qr(i) {
|
|
2620
2663
|
return 20 + i;
|
|
2621
2664
|
}
|
|
2622
|
-
function
|
|
2665
|
+
function Yr(i) {
|
|
2623
2666
|
return 10 * i;
|
|
2624
2667
|
}
|
|
2625
|
-
function
|
|
2668
|
+
function Zr(i) {
|
|
2626
2669
|
return 20 + i;
|
|
2627
2670
|
}
|
|
2628
|
-
class
|
|
2671
|
+
class Xr {
|
|
2629
2672
|
constructor(e) {
|
|
2630
2673
|
this.blue = e;
|
|
2631
2674
|
}
|
|
@@ -2637,68 +2680,68 @@ class Yr {
|
|
|
2637
2680
|
this.total += e;
|
|
2638
2681
|
}
|
|
2639
2682
|
chargeScopeEntry(e) {
|
|
2640
|
-
this.add(
|
|
2683
|
+
this.add(jr(this.scopeDepth(e)));
|
|
2641
2684
|
}
|
|
2642
2685
|
chargeInitialization() {
|
|
2643
|
-
this.add(
|
|
2686
|
+
this.add($r);
|
|
2644
2687
|
}
|
|
2645
2688
|
chargeChannelMatchAttempt() {
|
|
2646
|
-
this.add(
|
|
2689
|
+
this.add(xr);
|
|
2647
2690
|
}
|
|
2648
2691
|
chargeHandlerOverhead() {
|
|
2649
|
-
this.add(
|
|
2692
|
+
this.add(Fr);
|
|
2650
2693
|
}
|
|
2651
2694
|
chargeBoundaryCheck() {
|
|
2652
|
-
this.add(
|
|
2695
|
+
this.add(zr);
|
|
2653
2696
|
}
|
|
2654
2697
|
chargePatchAddOrReplace(e) {
|
|
2655
|
-
this.add(
|
|
2698
|
+
this.add(Qr(this.payloadSizeCharge(e)));
|
|
2656
2699
|
}
|
|
2657
2700
|
chargePatchRemove() {
|
|
2658
|
-
this.add(
|
|
2701
|
+
this.add(Ur);
|
|
2659
2702
|
}
|
|
2660
2703
|
chargeCascadeRouting(e) {
|
|
2661
|
-
e > 0 && this.add(
|
|
2704
|
+
e > 0 && this.add(Yr(e));
|
|
2662
2705
|
}
|
|
2663
2706
|
chargeEmitEvent(e) {
|
|
2664
|
-
this.add(
|
|
2707
|
+
this.add(Zr(this.payloadSizeCharge(e)));
|
|
2665
2708
|
}
|
|
2666
2709
|
chargeBridge() {
|
|
2667
|
-
this.add(
|
|
2710
|
+
this.add(Vr);
|
|
2668
2711
|
}
|
|
2669
2712
|
chargeDrainEvent() {
|
|
2670
|
-
this.add(
|
|
2713
|
+
this.add(Hr);
|
|
2671
2714
|
}
|
|
2672
2715
|
chargeCheckpointUpdate() {
|
|
2673
|
-
this.add(
|
|
2716
|
+
this.add(Kr);
|
|
2674
2717
|
}
|
|
2675
2718
|
chargeTerminationMarker() {
|
|
2676
|
-
this.add(
|
|
2719
|
+
this.add(Wr);
|
|
2677
2720
|
}
|
|
2678
2721
|
chargeLifecycleDelivery() {
|
|
2679
|
-
this.add(
|
|
2722
|
+
this.add(Gr);
|
|
2680
2723
|
}
|
|
2681
2724
|
chargeFatalTerminationOverhead() {
|
|
2682
|
-
this.add(
|
|
2725
|
+
this.add(Jr);
|
|
2683
2726
|
}
|
|
2684
2727
|
chargeJavaScriptCodeBase(e) {
|
|
2685
|
-
this.add(
|
|
2728
|
+
this.add(Ar(e));
|
|
2686
2729
|
}
|
|
2687
2730
|
chargeTriggerEventBase() {
|
|
2688
|
-
this.add(
|
|
2731
|
+
this.add(qr);
|
|
2689
2732
|
}
|
|
2690
2733
|
chargeUpdateDocumentBase(e) {
|
|
2691
|
-
this.add(
|
|
2734
|
+
this.add(Dr(e));
|
|
2692
2735
|
}
|
|
2693
2736
|
chargeExpression(e) {
|
|
2694
|
-
this.add(
|
|
2737
|
+
this.add(Br(e));
|
|
2695
2738
|
}
|
|
2696
2739
|
chargeTemplate(e, t) {
|
|
2697
|
-
this.add(
|
|
2740
|
+
this.add(_r(e, t));
|
|
2698
2741
|
}
|
|
2699
2742
|
chargeDocumentSnapshot(e, t) {
|
|
2700
2743
|
const n = t ? Se(this.blue, t) : 0;
|
|
2701
|
-
this.add(
|
|
2744
|
+
this.add(Lr(e, n));
|
|
2702
2745
|
}
|
|
2703
2746
|
payloadSizeCharge(e) {
|
|
2704
2747
|
if (!e)
|
|
@@ -2716,12 +2759,12 @@ class Yr {
|
|
|
2716
2759
|
return n;
|
|
2717
2760
|
}
|
|
2718
2761
|
}
|
|
2719
|
-
class
|
|
2762
|
+
class ei {
|
|
2720
2763
|
constructor(e, t) {
|
|
2721
|
-
this.documentRef = e, this.blueRef = t, this.patchEngine = new
|
|
2764
|
+
this.documentRef = e, this.blueRef = t, this.patchEngine = new kr(this.documentRef), this.meter = new Xr(this.blueRef);
|
|
2722
2765
|
}
|
|
2723
2766
|
patchEngine;
|
|
2724
|
-
emissionRegistry = new
|
|
2767
|
+
emissionRegistry = new Mr();
|
|
2725
2768
|
meter;
|
|
2726
2769
|
runTerminated = !1;
|
|
2727
2770
|
document() {
|
|
@@ -2770,15 +2813,15 @@ class Zr {
|
|
|
2770
2813
|
return this.patchEngine.applyPatch(e, t);
|
|
2771
2814
|
}
|
|
2772
2815
|
}
|
|
2773
|
-
const
|
|
2774
|
-
class
|
|
2816
|
+
const ti = m["Processing Initialized Marker"], ni = m["Document Update"];
|
|
2817
|
+
class ri {
|
|
2775
2818
|
constructor(e, t, n, r) {
|
|
2776
|
-
this.contractLoader = e, this.registry = t, this.runtimeRef = new
|
|
2777
|
-
const s = (o) =>
|
|
2778
|
-
this.checkpointManager = new
|
|
2819
|
+
this.contractLoader = e, this.registry = t, this.runtimeRef = new ei(r, n);
|
|
2820
|
+
const s = (o) => He(this.runtimeRef.blue(), o);
|
|
2821
|
+
this.checkpointManager = new ur(
|
|
2779
2822
|
this.runtimeRef,
|
|
2780
2823
|
s
|
|
2781
|
-
), this.terminationService = new
|
|
2824
|
+
), this.terminationService = new br(this.runtimeRef), this.channelRunner = new dr(
|
|
2782
2825
|
this.runtimeRef,
|
|
2783
2826
|
this.checkpointManager,
|
|
2784
2827
|
{
|
|
@@ -2805,9 +2848,10 @@ class ti {
|
|
|
2805
2848
|
},
|
|
2806
2849
|
executeHandler: async (o, a) => this.executeHandler(o, a),
|
|
2807
2850
|
handleHandlerError: async (o, a, c) => this.handleHandlerError(o, a, c),
|
|
2808
|
-
canonicalSignature: s
|
|
2851
|
+
canonicalSignature: s,
|
|
2852
|
+
channelProcessorFor: (o) => this.registry.lookupChannel(o) ?? null
|
|
2809
2853
|
}
|
|
2810
|
-
), this.scopeExecutor = new
|
|
2854
|
+
), this.scopeExecutor = new yr({
|
|
2811
2855
|
runtime: this.runtimeRef,
|
|
2812
2856
|
contractLoader: this.contractLoader,
|
|
2813
2857
|
channelRunner: this.channelRunner,
|
|
@@ -2858,7 +2902,7 @@ class ti {
|
|
|
2858
2902
|
);
|
|
2859
2903
|
}
|
|
2860
2904
|
createContext(e, t, n, r = !1, s = !1) {
|
|
2861
|
-
return new
|
|
2905
|
+
return new ii(
|
|
2862
2906
|
this,
|
|
2863
2907
|
t,
|
|
2864
2908
|
e,
|
|
@@ -2869,7 +2913,7 @@ class ti {
|
|
|
2869
2913
|
}
|
|
2870
2914
|
result() {
|
|
2871
2915
|
const e = this.runtimeRef.document().clone(), t = this.runtimeRef.rootEmissions().map((n) => n.clone());
|
|
2872
|
-
return
|
|
2916
|
+
return Oe.of(
|
|
2873
2917
|
e,
|
|
2874
2918
|
t,
|
|
2875
2919
|
this.runtimeRef.totalGas()
|
|
@@ -2983,8 +3027,8 @@ class ti {
|
|
|
2983
3027
|
return e instanceof Error && typeof e.message == "string" ? e.message : t;
|
|
2984
3028
|
}
|
|
2985
3029
|
createDocumentUpdateEvent(e, t) {
|
|
2986
|
-
const n =
|
|
2987
|
-
new d().setBlueId(
|
|
3030
|
+
const n = xt(t, e.path), r = e.before != null ? e.before.clone() : new d().setValue(null), s = e.after != null ? e.after.clone() : new d().setValue(null), o = new d().setType(
|
|
3031
|
+
new d().setBlueId(ni)
|
|
2988
3032
|
);
|
|
2989
3033
|
return o.setProperties({
|
|
2990
3034
|
op: new d().setValue(e.op),
|
|
@@ -3006,7 +3050,7 @@ class j {
|
|
|
3006
3050
|
}
|
|
3007
3051
|
async initializeDocument(e) {
|
|
3008
3052
|
if (this.isInitialized(e))
|
|
3009
|
-
throw new
|
|
3053
|
+
throw new O("Document already initialized");
|
|
3010
3054
|
const t = this.createExecution(e.clone());
|
|
3011
3055
|
return this.run(e, t, async () => {
|
|
3012
3056
|
await t.initializeScope("/", !0);
|
|
@@ -3014,7 +3058,7 @@ class j {
|
|
|
3014
3058
|
}
|
|
3015
3059
|
async processDocument(e, t) {
|
|
3016
3060
|
if (!this.isInitialized(e))
|
|
3017
|
-
throw new
|
|
3061
|
+
throw new O("Document not initialized");
|
|
3018
3062
|
const n = this.createExecution(e.clone()), r = t.clone();
|
|
3019
3063
|
return this.run(e, n, async () => {
|
|
3020
3064
|
n.loadBundles("/"), await n.processExternalEvent("/", r);
|
|
@@ -3024,7 +3068,7 @@ class j {
|
|
|
3024
3068
|
return this.initializationMarker(e) != null;
|
|
3025
3069
|
}
|
|
3026
3070
|
createExecution(e) {
|
|
3027
|
-
return new
|
|
3071
|
+
return new ri(
|
|
3028
3072
|
this.contractLoader,
|
|
3029
3073
|
this.registry,
|
|
3030
3074
|
this.blue,
|
|
@@ -3039,7 +3083,7 @@ class j {
|
|
|
3039
3083
|
return t.result();
|
|
3040
3084
|
if (r instanceof U) {
|
|
3041
3085
|
const s = e.clone();
|
|
3042
|
-
return
|
|
3086
|
+
return Oe.capabilityFailure(
|
|
3043
3087
|
s,
|
|
3044
3088
|
r.message ?? null
|
|
3045
3089
|
);
|
|
@@ -3059,7 +3103,7 @@ class j {
|
|
|
3059
3103
|
"Initialization Marker must be a BlueNode"
|
|
3060
3104
|
)
|
|
3061
3105
|
);
|
|
3062
|
-
if (n.getType()?.getBlueId() !==
|
|
3106
|
+
if (n.getType()?.getBlueId() !== ti)
|
|
3063
3107
|
throw new g(
|
|
3064
3108
|
"Initialization Marker must declare type 'Processing Initialized Marker'",
|
|
3065
3109
|
E.illegalState(
|
|
@@ -3125,7 +3169,7 @@ class j {
|
|
|
3125
3169
|
case "contracts":
|
|
3126
3170
|
return new d().setContracts(e.getContracts());
|
|
3127
3171
|
case "blueId": {
|
|
3128
|
-
const r = e.getBlueId() ?? n?.calculateBlueId?.(e) ??
|
|
3172
|
+
const r = e.getBlueId() ?? n?.calculateBlueId?.(e) ?? Et.calculateBlueIdSync(e);
|
|
3129
3173
|
return new d().setValue(r ?? null);
|
|
3130
3174
|
}
|
|
3131
3175
|
default:
|
|
@@ -3133,7 +3177,7 @@ class j {
|
|
|
3133
3177
|
}
|
|
3134
3178
|
}
|
|
3135
3179
|
}
|
|
3136
|
-
class
|
|
3180
|
+
class ii {
|
|
3137
3181
|
constructor(e, t, n, r, s, o) {
|
|
3138
3182
|
this.execution = e, this.bundle = t, this.scopePathValue = n, this.eventNode = r, this.allowTerminatedWork = s, this.allowReservedMutation = o;
|
|
3139
3183
|
}
|
|
@@ -3227,16 +3271,16 @@ class ni {
|
|
|
3227
3271
|
return !this.allowTerminatedWork && this.execution.isScopeInactive(this.scopePathValue);
|
|
3228
3272
|
}
|
|
3229
3273
|
}
|
|
3230
|
-
const
|
|
3231
|
-
repositories: [
|
|
3274
|
+
const si = new yt({
|
|
3275
|
+
repositories: [pt, Ct, Nt]
|
|
3232
3276
|
});
|
|
3233
|
-
class
|
|
3277
|
+
class oi {
|
|
3234
3278
|
blue;
|
|
3235
3279
|
registryRef;
|
|
3236
3280
|
contractLoaderRef;
|
|
3237
3281
|
engine;
|
|
3238
3282
|
constructor(e) {
|
|
3239
|
-
this.registryRef = e?.registry ?? Y.create().registerDefaults().build(), this.blue = e?.blue ??
|
|
3283
|
+
this.registryRef = e?.registry ?? Y.create().registerDefaults().build(), this.blue = e?.blue ?? si, this.contractLoaderRef = new sr(this.registryRef, this.blue), this.engine = new j(
|
|
3240
3284
|
this.contractLoaderRef,
|
|
3241
3285
|
this.registryRef,
|
|
3242
3286
|
this.blue
|
|
@@ -3269,10 +3313,10 @@ class ii {
|
|
|
3269
3313
|
return this.contractLoaderRef;
|
|
3270
3314
|
}
|
|
3271
3315
|
static builder() {
|
|
3272
|
-
return new
|
|
3316
|
+
return new ai();
|
|
3273
3317
|
}
|
|
3274
3318
|
}
|
|
3275
|
-
class
|
|
3319
|
+
class ai {
|
|
3276
3320
|
contractRegistry;
|
|
3277
3321
|
blueInstance;
|
|
3278
3322
|
constructor() {
|
|
@@ -3288,13 +3332,13 @@ class si {
|
|
|
3288
3332
|
return this.blueInstance = e, this;
|
|
3289
3333
|
}
|
|
3290
3334
|
build() {
|
|
3291
|
-
return new
|
|
3335
|
+
return new oi({
|
|
3292
3336
|
registry: this.contractRegistry,
|
|
3293
3337
|
blue: this.blueInstance
|
|
3294
3338
|
});
|
|
3295
3339
|
}
|
|
3296
3340
|
}
|
|
3297
|
-
class
|
|
3341
|
+
class tt {
|
|
3298
3342
|
process(e, t) {
|
|
3299
3343
|
const n = t.getValue();
|
|
3300
3344
|
if (G(n)) {
|
|
@@ -3315,14 +3359,14 @@ class Xe {
|
|
|
3315
3359
|
return e;
|
|
3316
3360
|
}
|
|
3317
3361
|
}
|
|
3318
|
-
const
|
|
3362
|
+
const Ni = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
3319
3363
|
__proto__: null,
|
|
3320
|
-
ExpressionPreserver:
|
|
3364
|
+
ExpressionPreserver: tt
|
|
3321
3365
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
3322
|
-
function
|
|
3366
|
+
function Mi() {
|
|
3323
3367
|
return new P.SequentialMergingProcessor([
|
|
3324
3368
|
new P.ValuePropagator(),
|
|
3325
|
-
new
|
|
3369
|
+
new tt(),
|
|
3326
3370
|
new P.TypeAssigner(),
|
|
3327
3371
|
new P.ListProcessor(),
|
|
3328
3372
|
new P.DictionaryProcessor(),
|
|
@@ -3330,101 +3374,101 @@ function Pi() {
|
|
|
3330
3374
|
]);
|
|
3331
3375
|
}
|
|
3332
3376
|
export {
|
|
3333
|
-
|
|
3334
|
-
|
|
3335
|
-
|
|
3336
|
-
|
|
3337
|
-
|
|
3338
|
-
|
|
3339
|
-
|
|
3340
|
-
|
|
3341
|
-
|
|
3377
|
+
Vn as ChannelBinding,
|
|
3378
|
+
dr as ChannelRunner,
|
|
3379
|
+
ur as CheckpointManager,
|
|
3380
|
+
lr as CheckpointRecord,
|
|
3381
|
+
We as CodeBlockEvaluationError,
|
|
3382
|
+
A as ContractBundle,
|
|
3383
|
+
Kn as ContractBundleBuilder,
|
|
3384
|
+
sr as ContractLoader,
|
|
3385
|
+
Cn as ContractProcessorRegistry,
|
|
3342
3386
|
Y as ContractProcessorRegistryBuilder,
|
|
3343
|
-
|
|
3344
|
-
|
|
3345
|
-
|
|
3346
|
-
|
|
3347
|
-
|
|
3348
|
-
|
|
3349
|
-
|
|
3387
|
+
Oe as DocumentProcessingResult,
|
|
3388
|
+
ei as DocumentProcessingRuntime,
|
|
3389
|
+
oi as DocumentProcessor,
|
|
3390
|
+
ai as DocumentProcessorBuilder,
|
|
3391
|
+
Mr as EmissionRegistry,
|
|
3392
|
+
Xr as GasMeter,
|
|
3393
|
+
Hn as HandlerBinding,
|
|
3350
3394
|
T as KEY_CHECKPOINT,
|
|
3351
3395
|
Ae as KEY_EMBEDDED,
|
|
3352
|
-
|
|
3353
|
-
|
|
3354
|
-
|
|
3355
|
-
|
|
3356
|
-
|
|
3357
|
-
|
|
3396
|
+
De as KEY_INITIALIZED,
|
|
3397
|
+
Be as KEY_TERMINATED,
|
|
3398
|
+
Ni as MergingProcessors,
|
|
3399
|
+
_e as PROCESSOR_MANAGED_CHANNEL_BLUE_IDS,
|
|
3400
|
+
kr as PatchEngine,
|
|
3401
|
+
vi as ProcessorContractConstants,
|
|
3358
3402
|
j as ProcessorEngine,
|
|
3359
3403
|
E as ProcessorErrors,
|
|
3360
|
-
|
|
3361
|
-
|
|
3404
|
+
ri as ProcessorExecution,
|
|
3405
|
+
ii as ProcessorExecutionContext,
|
|
3362
3406
|
g as ProcessorFatalError,
|
|
3363
|
-
|
|
3407
|
+
ki as ProcessorPointerConstants,
|
|
3364
3408
|
ce as QuickJSEvaluator,
|
|
3365
|
-
|
|
3409
|
+
$e as RELATIVE_CHECKPOINT,
|
|
3366
3410
|
B as RELATIVE_CONTRACTS,
|
|
3367
|
-
|
|
3411
|
+
$t as RELATIVE_EMBEDDED,
|
|
3368
3412
|
ie as RELATIVE_INITIALIZED,
|
|
3369
|
-
|
|
3413
|
+
Le as RELATIVE_TERMINATED,
|
|
3370
3414
|
oe as RESERVED_CONTRACT_KEYS,
|
|
3371
3415
|
J as RunTerminationError,
|
|
3372
|
-
|
|
3373
|
-
|
|
3374
|
-
|
|
3375
|
-
|
|
3376
|
-
|
|
3416
|
+
yr as ScopeExecutor,
|
|
3417
|
+
Nr as ScopeRuntimeContext,
|
|
3418
|
+
br as TerminationService,
|
|
3419
|
+
Si as andThen,
|
|
3420
|
+
He as canonicalSignature,
|
|
3377
3421
|
Se as canonicalSize,
|
|
3378
3422
|
_ as channelContractBaseSchema,
|
|
3379
|
-
|
|
3380
|
-
|
|
3423
|
+
ln as channelEventCheckpointSchema,
|
|
3424
|
+
Zt as containsExpression,
|
|
3381
3425
|
le as contractBaseSchema,
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
|
|
3385
|
-
|
|
3386
|
-
|
|
3387
|
-
|
|
3388
|
-
|
|
3389
|
-
|
|
3390
|
-
|
|
3391
|
-
|
|
3392
|
-
|
|
3393
|
-
|
|
3426
|
+
Mi as createDefaultMergingProcessor,
|
|
3427
|
+
je as createPicomatchShouldResolve,
|
|
3428
|
+
pn as documentAnchorsMarkerSchema,
|
|
3429
|
+
mn as documentLinksMarkerSchema,
|
|
3430
|
+
nn as documentUpdateChannelSchema,
|
|
3431
|
+
rn as embeddedNodeChannelSchema,
|
|
3432
|
+
Ot as err,
|
|
3433
|
+
Je as evaluateQuickJSExpression,
|
|
3434
|
+
Xt as extractExpressionContent,
|
|
3435
|
+
Qe as handlerContractBaseSchema,
|
|
3436
|
+
un as initializationMarkerSchema,
|
|
3437
|
+
Ei as isErr,
|
|
3394
3438
|
G as isExpression,
|
|
3395
|
-
|
|
3439
|
+
gi as isOk,
|
|
3396
3440
|
ae as isProcessorManagedChannelBlueId,
|
|
3397
|
-
|
|
3398
|
-
|
|
3399
|
-
|
|
3400
|
-
|
|
3401
|
-
|
|
3402
|
-
|
|
3441
|
+
Lt as isReservedContractKey,
|
|
3442
|
+
Ti as joinRelativePointers,
|
|
3443
|
+
Ri as jsonPatchSchema,
|
|
3444
|
+
sn as lifecycleChannelSchema,
|
|
3445
|
+
yi as map,
|
|
3446
|
+
wi as mapErr,
|
|
3403
3447
|
C as markerContractBaseSchema,
|
|
3404
|
-
|
|
3405
|
-
|
|
3406
|
-
|
|
3407
|
-
|
|
3408
|
-
|
|
3448
|
+
Ii as match,
|
|
3449
|
+
gn as myosParticipantsOrchestrationMarkerSchema,
|
|
3450
|
+
En as myosSessionInteractionMarkerSchema,
|
|
3451
|
+
cn as myosTimelineChannelSchema,
|
|
3452
|
+
yn as myosWorkerAgencyMarkerSchema,
|
|
3409
3453
|
S as normalizePointer,
|
|
3410
3454
|
y as normalizeScope,
|
|
3411
|
-
|
|
3412
|
-
|
|
3413
|
-
|
|
3414
|
-
|
|
3415
|
-
|
|
3416
|
-
|
|
3455
|
+
Mt as ok,
|
|
3456
|
+
fn as operationMarkerSchema,
|
|
3457
|
+
dn as processEmbeddedMarkerSchema,
|
|
3458
|
+
hn as processingTerminatedMarkerSchema,
|
|
3459
|
+
ze as relativeCheckpointLastEvent,
|
|
3460
|
+
Ue as relativeCheckpointLastSignature,
|
|
3417
3461
|
Q as relativeContractsEntry,
|
|
3418
|
-
|
|
3462
|
+
xt as relativizePointer,
|
|
3419
3463
|
q as resolveNodeExpressions,
|
|
3420
3464
|
w as resolvePointer,
|
|
3421
|
-
|
|
3422
|
-
|
|
3423
|
-
|
|
3424
|
-
|
|
3465
|
+
en as resolveTemplateString,
|
|
3466
|
+
Sn as sequentialWorkflowOperationSchema,
|
|
3467
|
+
wn as sequentialWorkflowSchema,
|
|
3468
|
+
Pi as sequentialWorkflowStepSchema,
|
|
3425
3469
|
ye as stripSlashes,
|
|
3426
|
-
|
|
3427
|
-
|
|
3428
|
-
|
|
3429
|
-
|
|
3470
|
+
an as timelineChannelSchema,
|
|
3471
|
+
on as triggeredEventChannelSchema,
|
|
3472
|
+
bi as unwrapOr,
|
|
3473
|
+
Ci as unwrapOrElse
|
|
3430
3474
|
};
|