@rotorsoft/act 2.1.11 → 2.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/.tsbuildinfo +1 -1
- package/dist/@types/act.d.ts +1 -0
- package/dist/@types/act.d.ts.map +1 -1
- package/dist/@types/internal/defer-config.d.ts +2 -3
- package/dist/@types/internal/defer-config.d.ts.map +1 -1
- package/dist/@types/ports.d.ts +0 -5
- package/dist/@types/ports.d.ts.map +1 -1
- package/dist/@types/types/ports.d.ts +1 -1
- package/dist/adapter.cjs +3 -3
- package/dist/adapter.js +2 -2
- package/dist/{chunk-BQUOIHOR.js → chunk-FYI7O7W6.js} +38 -6
- package/dist/{chunk-BQUOIHOR.js.map → chunk-FYI7O7W6.js.map} +1 -1
- package/dist/{chunk-RV34EYSN.js → chunk-MWLATJDX.js} +11 -3
- package/dist/{chunk-RV34EYSN.js.map → chunk-MWLATJDX.js.map} +1 -1
- package/dist/{chunk-N74AN6L5.cjs → chunk-OW67FBYO.cjs} +83 -55
- package/dist/chunk-OW67FBYO.cjs.map +1 -0
- package/dist/{chunk-SC6TY4P2.cjs → chunk-PDMLWC77.cjs} +12 -4
- package/dist/chunk-PDMLWC77.cjs.map +1 -0
- package/dist/{chunk-ZTHGF62O.cjs → chunk-QSXWCJ2U.cjs} +40 -8
- package/dist/chunk-QSXWCJ2U.cjs.map +1 -0
- package/dist/{chunk-Y2ISPWQL.js → chunk-R5PT4AYJ.js} +70 -42
- package/dist/{chunk-Y2ISPWQL.js.map → chunk-R5PT4AYJ.js.map} +1 -1
- package/dist/index.cjs +514 -367
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +333 -186
- package/dist/index.js.map +1 -1
- package/dist/test/index.cjs +13 -9
- package/dist/test/index.cjs.map +1 -1
- package/dist/test/index.js +11 -7
- package/dist/test/index.js.map +1 -1
- package/dist/types/index.cjs +2 -2
- package/dist/types/index.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-N74AN6L5.cjs.map +0 -1
- package/dist/chunk-SC6TY4P2.cjs.map +0 -1
- package/dist/chunk-ZTHGF62O.cjs.map +0 -1
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ConcurrencyError,
|
|
3
3
|
SNAP_EVENT,
|
|
4
|
-
TOMBSTONE_EVENT
|
|
5
|
-
|
|
4
|
+
TOMBSTONE_EVENT,
|
|
5
|
+
__name
|
|
6
|
+
} from "./chunk-FYI7O7W6.js";
|
|
6
7
|
|
|
7
8
|
// src/adapter.ts
|
|
8
9
|
function isStreamName(source, target) {
|
|
9
10
|
return source === target || !source.startsWith("^") && !source.endsWith("$");
|
|
10
11
|
}
|
|
12
|
+
__name(isStreamName, "isStreamName");
|
|
11
13
|
function checkAppends(appends) {
|
|
12
14
|
const seen = /* @__PURE__ */ new Set();
|
|
13
15
|
for (const { stream, msgs } of appends) {
|
|
@@ -18,6 +20,7 @@ function checkAppends(appends) {
|
|
|
18
20
|
seen.add(stream);
|
|
19
21
|
}
|
|
20
22
|
}
|
|
23
|
+
__name(checkAppends, "checkAppends");
|
|
21
24
|
function concurrencyError(append, head) {
|
|
22
25
|
return new ConcurrencyError(
|
|
23
26
|
append.stream,
|
|
@@ -26,10 +29,12 @@ function concurrencyError(append, head) {
|
|
|
26
29
|
append.expectedVersion ?? -1
|
|
27
30
|
);
|
|
28
31
|
}
|
|
32
|
+
__name(concurrencyError, "concurrencyError");
|
|
29
33
|
function checkVersion(append, head) {
|
|
30
34
|
if (typeof append.expectedVersion === "number" && head !== append.expectedVersion)
|
|
31
35
|
throw concurrencyError(append, head);
|
|
32
36
|
}
|
|
37
|
+
__name(checkVersion, "checkVersion");
|
|
33
38
|
function seedEvent(snapshot, meta) {
|
|
34
39
|
return {
|
|
35
40
|
name: snapshot !== void 0 ? SNAP_EVENT : TOMBSTONE_EVENT,
|
|
@@ -37,9 +42,11 @@ function seedEvent(snapshot, meta) {
|
|
|
37
42
|
meta: meta ?? { correlation: "", causation: {} }
|
|
38
43
|
};
|
|
39
44
|
}
|
|
45
|
+
__name(seedEvent, "seedEvent");
|
|
40
46
|
function fairSlots(lagging) {
|
|
41
47
|
return lagging >= 2 ? Math.max(1, Math.floor(lagging / 4)) : 0;
|
|
42
48
|
}
|
|
49
|
+
__name(fairSlots, "fairSlots");
|
|
43
50
|
function parseNotification(raw) {
|
|
44
51
|
if (!raw || typeof raw !== "object") return void 0;
|
|
45
52
|
const { stream, events } = raw;
|
|
@@ -49,6 +56,7 @@ function parseNotification(raw) {
|
|
|
49
56
|
);
|
|
50
57
|
return kept.length ? { stream, events: kept.map(({ id, name }) => ({ id, name })) } : void 0;
|
|
51
58
|
}
|
|
59
|
+
__name(parseNotification, "parseNotification");
|
|
52
60
|
|
|
53
61
|
export {
|
|
54
62
|
isStreamName,
|
|
@@ -59,4 +67,4 @@ export {
|
|
|
59
67
|
fairSlots,
|
|
60
68
|
parseNotification
|
|
61
69
|
};
|
|
62
|
-
//# sourceMappingURL=chunk-
|
|
70
|
+
//# sourceMappingURL=chunk-MWLATJDX.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/adapter.ts"],"sourcesContent":["/**\n * @packageDocumentation\n * @module act/adapter\n *\n * The rules a `Store` implementation calls, so each one lives once in core and\n * a third-party store can't drift from it. Each is a pure function of its\n * arguments. Import them by name, or as\n * `import * as adapter from \"@rotorsoft/act/adapter\"`. Writing a store:\n * https://rotorsoft.github.io/act-root/docs/guides/writing-a-store\n */\nimport {\n ConcurrencyError,\n type EventMeta,\n type Message,\n type Schema,\n type Schemas,\n SNAP_EVENT,\n type StoreNotification,\n TOMBSTONE_EVENT,\n} from \"./types/index.js\";\n\n/**\n * True when `source` is a stream's **name**, matched exactly. Only an anchored\n * source, one that starts with `^` or ends with `$`, is a **pattern** and gets\n * compiled as a RegExp. A name can hold any other character, so\n * `user+tag@example.com` and `order(1)` are names, and a pattern always says\n * that it is one.\n *\n * Pass the subscription's `target` too when it's known: a target reading itself\n * holds a stream's name, whatever characters that name has.\n *\n * The single source of truth for this across correlate (which decides what a\n * source marks), the drain fetch path, the close check, and the adapters, so\n * they all agree.\n *\n * @example\n * ```typescript\n * isStreamName(\"Board\"); // → true (exact lookup)\n * isStreamName(\"a+b\"); // → true (exact lookup)\n * isStreamName(\"^(A|B)$\"); // → false (compile as RegExp)\n * ```\n */\nexport function isStreamName(source: string, target?: string): boolean {\n return (\n source === target || (!source.startsWith(\"^\") && !source.endsWith(\"$\"))\n );\n}\n\n/**\n * What every store refuses in a `commit`: an append with no events, and a\n * stream named twice. In core so each adapter calls the one rule.\n */\nexport function checkAppends(\n appends: readonly {\n readonly stream: string;\n readonly msgs: readonly unknown[];\n }[]\n): void {\n const seen = new Set<string>();\n for (const { stream, msgs } of appends) {\n if (!msgs.length)\n throw new Error(`commit: the append to \"${stream}\" has no events`);\n if (seen.has(stream))\n throw new Error(`commit: stream \"${stream}\" is named twice`);\n seen.add(stream);\n }\n}\n\n/**\n * The error a stale append raises, given the head the store found. A writer\n * that named no `expectedVersion` reads as `-1`: only a race between the\n * version check and the insert gets one here.\n */\nexport function concurrencyError(\n append: {\n readonly stream: string;\n readonly msgs: readonly unknown[];\n readonly expectedVersion?: number;\n },\n head: number\n): ConcurrencyError {\n return new ConcurrencyError(\n append.stream,\n head,\n append.msgs as Message<Schemas, keyof Schemas>[],\n append.expectedVersion ?? -1\n );\n}\n\n/**\n * What every store refuses as a stale writer: an append whose\n * `expectedVersion` is not the stream's head. In core so each adapter calls\n * the one rule before it appends anything.\n */\nexport function checkVersion(\n append: {\n readonly stream: string;\n readonly msgs: readonly unknown[];\n readonly expectedVersion?: number;\n },\n head: number\n): void {\n if (\n typeof append.expectedVersion === \"number\" &&\n head !== append.expectedVersion\n )\n throw concurrencyError(append, head);\n}\n\n/**\n * The event a full `truncate` seeds a stream with at version 0: a snapshot\n * of the given state, or a tombstone when there is none.\n */\nexport function seedEvent(\n snapshot?: Schema,\n meta?: EventMeta\n): { name: string; data: Schema; meta: EventMeta } {\n return {\n name: snapshot !== undefined ? SNAP_EVENT : TOMBSTONE_EVENT,\n data: snapshot ?? {},\n meta: meta ?? { correlation: \"\", causation: {} },\n };\n}\n\n/**\n * How many of `lagging` claim slots ignore priority, so sustained high-priority\n * load can't starve a low-priority stream forever. Each store's `claim` calls\n * it, and the rule stays out of the `claim` signature.\n */\nexport function fairSlots(lagging: number): number {\n return lagging >= 2 ? Math.max(1, Math.floor(lagging / 4)) : 0;\n}\n\n/**\n * The commit notification in a payload a store or broker received, or\n * `undefined` when there is none: `stream` must be a string, and only\n * `{ id: number, name: string }` events are kept, stripped of anything else.\n * A payload with no such event is not a notification. In core so every\n * listener reads a foreign or version-skewed payload the same way.\n */\nexport function parseNotification(raw: unknown): StoreNotification | undefined {\n if (!raw || typeof raw !== \"object\") return undefined;\n const { stream, events } = raw as { stream?: unknown; events?: unknown };\n if (typeof stream !== \"string\" || !Array.isArray(events)) return undefined;\n const kept = events.filter(\n (e): e is { id: number; name: string } =>\n !!e &&\n typeof e === \"object\" &&\n typeof (e as { id?: unknown }).id === \"number\" &&\n typeof (e as { name?: unknown }).name === \"string\"\n );\n return kept.length\n ? { stream, events: kept.map(({ id, name }) => ({ id, name })) }\n : undefined;\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../src/adapter.ts"],"sourcesContent":["/**\n * @packageDocumentation\n * @module act/adapter\n *\n * The rules a `Store` implementation calls, so each one lives once in core and\n * a third-party store can't drift from it. Each is a pure function of its\n * arguments. Import them by name, or as\n * `import * as adapter from \"@rotorsoft/act/adapter\"`. Writing a store:\n * https://rotorsoft.github.io/act-root/docs/guides/writing-a-store\n */\nimport {\n ConcurrencyError,\n type EventMeta,\n type Message,\n type Schema,\n type Schemas,\n SNAP_EVENT,\n type StoreNotification,\n TOMBSTONE_EVENT,\n} from \"./types/index.js\";\n\n/**\n * True when `source` is a stream's **name**, matched exactly. Only an anchored\n * source, one that starts with `^` or ends with `$`, is a **pattern** and gets\n * compiled as a RegExp. A name can hold any other character, so\n * `user+tag@example.com` and `order(1)` are names, and a pattern always says\n * that it is one.\n *\n * Pass the subscription's `target` too when it's known: a target reading itself\n * holds a stream's name, whatever characters that name has.\n *\n * The single source of truth for this across correlate (which decides what a\n * source marks), the drain fetch path, the close check, and the adapters, so\n * they all agree.\n *\n * @example\n * ```typescript\n * isStreamName(\"Board\"); // → true (exact lookup)\n * isStreamName(\"a+b\"); // → true (exact lookup)\n * isStreamName(\"^(A|B)$\"); // → false (compile as RegExp)\n * ```\n */\nexport function isStreamName(source: string, target?: string): boolean {\n return (\n source === target || (!source.startsWith(\"^\") && !source.endsWith(\"$\"))\n );\n}\n\n/**\n * What every store refuses in a `commit`: an append with no events, and a\n * stream named twice. In core so each adapter calls the one rule.\n */\nexport function checkAppends(\n appends: readonly {\n readonly stream: string;\n readonly msgs: readonly unknown[];\n }[]\n): void {\n const seen = new Set<string>();\n for (const { stream, msgs } of appends) {\n if (!msgs.length)\n throw new Error(`commit: the append to \"${stream}\" has no events`);\n if (seen.has(stream))\n throw new Error(`commit: stream \"${stream}\" is named twice`);\n seen.add(stream);\n }\n}\n\n/**\n * The error a stale append raises, given the head the store found. A writer\n * that named no `expectedVersion` reads as `-1`: only a race between the\n * version check and the insert gets one here.\n */\nexport function concurrencyError(\n append: {\n readonly stream: string;\n readonly msgs: readonly unknown[];\n readonly expectedVersion?: number;\n },\n head: number\n): ConcurrencyError {\n return new ConcurrencyError(\n append.stream,\n head,\n append.msgs as Message<Schemas, keyof Schemas>[],\n append.expectedVersion ?? -1\n );\n}\n\n/**\n * What every store refuses as a stale writer: an append whose\n * `expectedVersion` is not the stream's head. In core so each adapter calls\n * the one rule before it appends anything.\n */\nexport function checkVersion(\n append: {\n readonly stream: string;\n readonly msgs: readonly unknown[];\n readonly expectedVersion?: number;\n },\n head: number\n): void {\n if (\n typeof append.expectedVersion === \"number\" &&\n head !== append.expectedVersion\n )\n throw concurrencyError(append, head);\n}\n\n/**\n * The event a full `truncate` seeds a stream with at version 0: a snapshot\n * of the given state, or a tombstone when there is none.\n */\nexport function seedEvent(\n snapshot?: Schema,\n meta?: EventMeta\n): { name: string; data: Schema; meta: EventMeta } {\n return {\n name: snapshot !== undefined ? SNAP_EVENT : TOMBSTONE_EVENT,\n data: snapshot ?? {},\n meta: meta ?? { correlation: \"\", causation: {} },\n };\n}\n\n/**\n * How many of `lagging` claim slots ignore priority, so sustained high-priority\n * load can't starve a low-priority stream forever. Each store's `claim` calls\n * it, and the rule stays out of the `claim` signature.\n */\nexport function fairSlots(lagging: number): number {\n return lagging >= 2 ? Math.max(1, Math.floor(lagging / 4)) : 0;\n}\n\n/**\n * The commit notification in a payload a store or broker received, or\n * `undefined` when there is none: `stream` must be a string, and only\n * `{ id: number, name: string }` events are kept, stripped of anything else.\n * A payload with no such event is not a notification. In core so every\n * listener reads a foreign or version-skewed payload the same way.\n */\nexport function parseNotification(raw: unknown): StoreNotification | undefined {\n if (!raw || typeof raw !== \"object\") return undefined;\n const { stream, events } = raw as { stream?: unknown; events?: unknown };\n if (typeof stream !== \"string\" || !Array.isArray(events)) return undefined;\n const kept = events.filter(\n (e): e is { id: number; name: string } =>\n !!e &&\n typeof e === \"object\" &&\n typeof (e as { id?: unknown }).id === \"number\" &&\n typeof (e as { name?: unknown }).name === \"string\"\n );\n return kept.length\n ? { stream, events: kept.map(({ id, name }) => ({ id, name })) }\n : undefined;\n}\n"],"mappings":";;;;;;;;AA0CO,SAAS,aAAa,QAAgB,QAA0B;AACrE,SACE,WAAW,UAAW,CAAC,OAAO,WAAW,GAAG,KAAK,CAAC,OAAO,SAAS,GAAG;AAEzE;AAJgB;AAUT,SAAS,aACd,SAIM;AACN,QAAM,OAAO,oBAAI,IAAY;AAC7B,aAAW,EAAE,QAAQ,KAAK,KAAK,SAAS;AACtC,QAAI,CAAC,KAAK;AACR,YAAM,IAAI,MAAM,0BAA0B,MAAM,iBAAiB;AACnE,QAAI,KAAK,IAAI,MAAM;AACjB,YAAM,IAAI,MAAM,mBAAmB,MAAM,kBAAkB;AAC7D,SAAK,IAAI,MAAM;AAAA,EACjB;AACF;AAdgB;AAqBT,SAAS,iBACd,QAKA,MACkB;AAClB,SAAO,IAAI;AAAA,IACT,OAAO;AAAA,IACP;AAAA,IACA,OAAO;AAAA,IACP,OAAO,mBAAmB;AAAA,EAC5B;AACF;AAdgB;AAqBT,SAAS,aACd,QAKA,MACM;AACN,MACE,OAAO,OAAO,oBAAoB,YAClC,SAAS,OAAO;AAEhB,UAAM,iBAAiB,QAAQ,IAAI;AACvC;AAbgB;AAmBT,SAAS,UACd,UACA,MACiD;AACjD,SAAO;AAAA,IACL,MAAM,aAAa,SAAY,aAAa;AAAA,IAC5C,MAAM,YAAY,CAAC;AAAA,IACnB,MAAM,QAAQ,EAAE,aAAa,IAAI,WAAW,CAAC,EAAE;AAAA,EACjD;AACF;AATgB;AAgBT,SAAS,UAAU,SAAyB;AACjD,SAAO,WAAW,IAAI,KAAK,IAAI,GAAG,KAAK,MAAM,UAAU,CAAC,CAAC,IAAI;AAC/D;AAFgB;AAWT,SAAS,kBAAkB,KAA6C;AAC7E,MAAI,CAAC,OAAO,OAAO,QAAQ,SAAU,QAAO;AAC5C,QAAM,EAAE,QAAQ,OAAO,IAAI;AAC3B,MAAI,OAAO,WAAW,YAAY,CAAC,MAAM,QAAQ,MAAM,EAAG,QAAO;AACjE,QAAM,OAAO,OAAO;AAAA,IAClB,CAAC,MACC,CAAC,CAAC,KACF,OAAO,MAAM,YACb,OAAQ,EAAuB,OAAO,YACtC,OAAQ,EAAyB,SAAS;AAAA,EAC9C;AACA,SAAO,KAAK,SACR,EAAE,QAAQ,QAAQ,KAAK,IAAI,CAAC,EAAE,IAAI,KAAK,OAAO,EAAE,IAAI,KAAK,EAAE,EAAE,IAC7D;AACN;AAdgB;","names":[]}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkPDMLWC77cjs = require('./chunk-PDMLWC77.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
@@ -11,7 +11,8 @@ var _chunkSC6TY4P2cjs = require('./chunk-SC6TY4P2.cjs');
|
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
|
|
15
|
+
var _chunkQSXWCJ2Ucjs = require('./chunk-QSXWCJ2U.cjs');
|
|
15
16
|
|
|
16
17
|
// src/adapters/console-logger.ts
|
|
17
18
|
var LEVEL_VALUES = {
|
|
@@ -37,9 +38,12 @@ var LEVEL_COLORS = {
|
|
|
37
38
|
// gray
|
|
38
39
|
};
|
|
39
40
|
var RESET = "\x1B[0m";
|
|
40
|
-
var noop = () => {
|
|
41
|
-
};
|
|
41
|
+
var noop = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, () => {
|
|
42
|
+
}, "noop");
|
|
42
43
|
var ConsoleLogger = class _ConsoleLogger {
|
|
44
|
+
static {
|
|
45
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, this, "ConsoleLogger");
|
|
46
|
+
}
|
|
43
47
|
|
|
44
48
|
|
|
45
49
|
|
|
@@ -139,6 +143,9 @@ var ConsoleLogger = class _ConsoleLogger {
|
|
|
139
143
|
|
|
140
144
|
// src/internal/lru-map.ts
|
|
141
145
|
var LruMap = (_class = class {
|
|
146
|
+
static {
|
|
147
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, this, "LruMap");
|
|
148
|
+
}
|
|
142
149
|
__init() {this._entries = /* @__PURE__ */ new Map()}
|
|
143
150
|
|
|
144
151
|
constructor(maxSize) {;_class.prototype.__init.call(this);
|
|
@@ -175,6 +182,9 @@ var LruMap = (_class = class {
|
|
|
175
182
|
|
|
176
183
|
// src/adapters/in-memory-cache.ts
|
|
177
184
|
var InMemoryCache = class {
|
|
185
|
+
static {
|
|
186
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, this, "InMemoryCache");
|
|
187
|
+
}
|
|
178
188
|
// CacheEntry<any> lets `get<TState>` and `set<TState>` flow without casts:
|
|
179
189
|
// any is bidirectionally compatible with the per-call TState binding, while
|
|
180
190
|
// the public Cache interface still presents a typed surface to callers.
|
|
@@ -214,22 +224,26 @@ var _zod = require('zod');
|
|
|
214
224
|
|
|
215
225
|
// src/utils.ts
|
|
216
226
|
|
|
217
|
-
var validate = (target, payload, schema) => {
|
|
227
|
+
var validate = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, (target, payload, schema) => {
|
|
218
228
|
try {
|
|
219
229
|
return schema ? schema.parse(payload) : payload;
|
|
220
230
|
} catch (error) {
|
|
221
231
|
if (error instanceof _zod.ZodError) {
|
|
222
|
-
throw new (0,
|
|
232
|
+
throw new (0, _chunkQSXWCJ2Ucjs.ValidationError)(target, payload, _zod.prettifyError.call(void 0, error));
|
|
223
233
|
}
|
|
224
|
-
throw new (0,
|
|
234
|
+
throw new (0, _chunkQSXWCJ2Ucjs.ValidationError)(target, payload, error);
|
|
225
235
|
}
|
|
226
|
-
};
|
|
236
|
+
}, "validate");
|
|
227
237
|
async function sleep(ms) {
|
|
228
238
|
return new Promise((resolve) => setTimeout(resolve, _nullishCoalesce(ms, () => ( config().sleepMs))));
|
|
229
239
|
}
|
|
240
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, sleep, "sleep");
|
|
230
241
|
|
|
231
242
|
// src/adapters/in-memory-store.ts
|
|
232
243
|
var InMemoryStream = (_class2 = class {
|
|
244
|
+
static {
|
|
245
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, this, "InMemoryStream");
|
|
246
|
+
}
|
|
233
247
|
|
|
234
248
|
|
|
235
249
|
__init2() {this._at = -1}
|
|
@@ -244,7 +258,7 @@ var InMemoryStream = (_class2 = class {
|
|
|
244
258
|
__init8() {this._deferred_at = void 0}
|
|
245
259
|
// Work mark; `undefined` = never correlated, so `claim` skips it.
|
|
246
260
|
__init9() {this._correlated_at = void 0}
|
|
247
|
-
constructor(stream, source, priority = 0, lane =
|
|
261
|
+
constructor(stream, source, priority = 0, lane = _chunkQSXWCJ2Ucjs.DEFAULT_LANE) {;_class2.prototype.__init2.call(this);_class2.prototype.__init3.call(this);_class2.prototype.__init4.call(this);_class2.prototype.__init5.call(this);_class2.prototype.__init6.call(this);_class2.prototype.__init7.call(this);_class2.prototype.__init8.call(this);_class2.prototype.__init9.call(this);
|
|
248
262
|
this.stream = stream;
|
|
249
263
|
this.source = source;
|
|
250
264
|
this._priority = priority;
|
|
@@ -371,12 +385,15 @@ var InMemoryStream = (_class2 = class {
|
|
|
371
385
|
return true;
|
|
372
386
|
}
|
|
373
387
|
}, _class2);
|
|
374
|
-
var name_test = (pattern, exact) => {
|
|
388
|
+
var name_test = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, (pattern, exact) => {
|
|
375
389
|
if (exact) return (name) => name === pattern;
|
|
376
390
|
const re = new RegExp(pattern);
|
|
377
391
|
return (name) => re.test(name);
|
|
378
|
-
};
|
|
392
|
+
}, "name_test");
|
|
379
393
|
var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10.call(this);_class3.prototype.__init11.call(this);_class3.prototype.__init12.call(this);_class3.prototype.__init13.call(this);_class3.prototype.__init14.call(this);_class3.prototype.__init15.call(this);_class3.prototype.__init16.call(this); }
|
|
394
|
+
static {
|
|
395
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, this, "InMemoryStore");
|
|
396
|
+
}
|
|
380
397
|
__init10() {this._events = []}
|
|
381
398
|
// Never reused. Deletions punch holes, so ids are not array indexes.
|
|
382
399
|
__init11() {this._next_id = 0}
|
|
@@ -441,7 +458,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
441
458
|
if (query.names && !query.names.includes(e.name)) return false;
|
|
442
459
|
if (query.correlation && _optionalChain([e, 'access', _7 => _7.meta, 'optionalAccess', _8 => _8.correlation]) !== query.correlation)
|
|
443
460
|
return false;
|
|
444
|
-
if (e.name ===
|
|
461
|
+
if (e.name === _chunkQSXWCJ2Ucjs.SNAP_EVENT && !query.with_snaps) return false;
|
|
445
462
|
if (query.created_after && e.created <= query.created_after) return false;
|
|
446
463
|
if (query.created_before && e.created >= query.created_before)
|
|
447
464
|
return false;
|
|
@@ -454,7 +471,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
454
471
|
return -1;
|
|
455
472
|
for (let j = this._events.length - 1; j >= 0; j--) {
|
|
456
473
|
const e = this._events[j];
|
|
457
|
-
if (e.stream === query.stream && e.name ===
|
|
474
|
+
if (e.stream === query.stream && e.name === _chunkQSXWCJ2Ucjs.SNAP_EVENT) return j;
|
|
458
475
|
}
|
|
459
476
|
return -1;
|
|
460
477
|
}
|
|
@@ -479,9 +496,9 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
479
496
|
}
|
|
480
497
|
async commit(appends, meta) {
|
|
481
498
|
await sleep();
|
|
482
|
-
|
|
499
|
+
_chunkPDMLWC77cjs.checkAppends.call(void 0, appends);
|
|
483
500
|
for (const append of appends)
|
|
484
|
-
|
|
501
|
+
_chunkPDMLWC77cjs.checkVersion.call(void 0, append, _nullishCoalesce(this._stream_versions.get(append.stream), () => ( -1)));
|
|
485
502
|
const created = /* @__PURE__ */ new Date();
|
|
486
503
|
return appends.flatMap(({ stream, msgs }) => {
|
|
487
504
|
let version = _nullishCoalesce(this._stream_versions.get(stream), () => ( -1));
|
|
@@ -505,11 +522,11 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
505
522
|
}
|
|
506
523
|
async claim(lagging, leading, by, millis, lane) {
|
|
507
524
|
await sleep();
|
|
508
|
-
const has_work = (s) => s.correlated_at !== void 0 && s.at < s.correlated_at;
|
|
525
|
+
const has_work = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, (s) => s.correlated_at !== void 0 && s.at < s.correlated_at, "has_work");
|
|
509
526
|
const available = [...this._streams.values()].filter(
|
|
510
527
|
(s) => s.is_available && has_work(s) && (lane === void 0 || s.lane === lane)
|
|
511
528
|
);
|
|
512
|
-
const fair =
|
|
529
|
+
const fair = _chunkPDMLWC77cjs.fairSlots.call(void 0, lagging);
|
|
513
530
|
const by_priority = [...available].sort(
|
|
514
531
|
(a, b) => b.priority - a.priority || a.at - b.at
|
|
515
532
|
);
|
|
@@ -568,7 +585,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
568
585
|
stream,
|
|
569
586
|
source,
|
|
570
587
|
priority = 0,
|
|
571
|
-
lane =
|
|
588
|
+
lane = _chunkQSXWCJ2Ucjs.DEFAULT_LANE,
|
|
572
589
|
correlated_at: correlated_at2
|
|
573
590
|
} of streams) {
|
|
574
591
|
const existing = this._streams.get(stream);
|
|
@@ -653,14 +670,14 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
653
670
|
}
|
|
654
671
|
async query_streams(callback, query) {
|
|
655
672
|
await sleep();
|
|
656
|
-
const limit = _nullishCoalesce(_optionalChain([query, 'optionalAccess', _35 => _35.limit]), () => (
|
|
673
|
+
const limit = _nullishCoalesce(_optionalChain([query, 'optionalAccess', _35 => _35.limit]), () => ( _chunkQSXWCJ2Ucjs.DEFAULT_QUERY_STREAMS_LIMIT));
|
|
657
674
|
const after = _optionalChain([query, 'optionalAccess', _36 => _36.after]);
|
|
658
675
|
const source_matches = _optionalChain([query, 'optionalAccess', _37 => _37.source_matches]);
|
|
659
676
|
const matches = this._filter_predicate(_nullishCoalesce(query, () => ( {})));
|
|
660
|
-
const reverse_match = (source) => {
|
|
677
|
+
const reverse_match = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, (source) => {
|
|
661
678
|
const re = new RegExp(source);
|
|
662
679
|
return source_matches.some((name) => re.test(name));
|
|
663
|
-
};
|
|
680
|
+
}, "reverse_match");
|
|
664
681
|
const sorted = [...this._streams.keys()].sort().map((stream) => this._streams.get(stream));
|
|
665
682
|
let count = 0;
|
|
666
683
|
for (const s of sorted) {
|
|
@@ -700,13 +717,13 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
700
717
|
const array_targets = Array.isArray(input) ? new Set(input) : null;
|
|
701
718
|
const stream_ok = !Array.isArray(input) && input.stream !== void 0 ? name_test(input.stream, input.stream_exact) : void 0;
|
|
702
719
|
const scope_cache = /* @__PURE__ */ new Map();
|
|
703
|
-
const in_scope = (stream) => {
|
|
720
|
+
const in_scope = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, (stream) => {
|
|
704
721
|
const cached = scope_cache.get(stream);
|
|
705
722
|
if (cached !== void 0) return cached;
|
|
706
723
|
const ok = array_targets ? array_targets.has(stream) : _nullishCoalesce(_optionalChain([stream_ok, 'optionalCall', _49 => _49(stream)]), () => ( true));
|
|
707
724
|
scope_cache.set(stream, ok);
|
|
708
725
|
return ok;
|
|
709
|
-
};
|
|
726
|
+
}, "in_scope");
|
|
710
727
|
const acc = /* @__PURE__ */ new Map();
|
|
711
728
|
for (const e of this._events) {
|
|
712
729
|
if (before !== void 0 && e.id >= before) continue;
|
|
@@ -747,7 +764,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
747
764
|
for (const { stream, before, max_id } of windowed) {
|
|
748
765
|
let boundary;
|
|
749
766
|
for (const e of this._events) {
|
|
750
|
-
if (e.stream === stream && e.name ===
|
|
767
|
+
if (e.stream === stream && e.name === _chunkQSXWCJ2Ucjs.SNAP_EVENT && e.created < before && (max_id === void 0 || e.id <= max_id) && (!boundary || e.id > boundary.id))
|
|
751
768
|
boundary = e;
|
|
752
769
|
}
|
|
753
770
|
if (!boundary) continue;
|
|
@@ -776,7 +793,7 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
776
793
|
stream,
|
|
777
794
|
version: 0,
|
|
778
795
|
created: /* @__PURE__ */ new Date(),
|
|
779
|
-
...
|
|
796
|
+
..._chunkPDMLWC77cjs.seedEvent.call(void 0, snapshot, meta)
|
|
780
797
|
};
|
|
781
798
|
this._events.push(event);
|
|
782
799
|
this._stream_versions.set(stream, 0);
|
|
@@ -828,24 +845,24 @@ var InMemoryStore = (_class3 = class {constructor() { _class3.prototype.__init10
|
|
|
828
845
|
|
|
829
846
|
// src/disposers.ts
|
|
830
847
|
var entries = [];
|
|
831
|
-
var prune = () => {
|
|
848
|
+
var prune = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, () => {
|
|
832
849
|
for (let i = entries.length - 1; i >= 0; i--) {
|
|
833
850
|
const { ref } = entries[i];
|
|
834
851
|
if (ref && !ref.deref()) entries.splice(i, 1);
|
|
835
852
|
}
|
|
836
|
-
};
|
|
837
|
-
var register_disposer = (run) => {
|
|
853
|
+
}, "prune");
|
|
854
|
+
var register_disposer = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, (run) => {
|
|
838
855
|
prune();
|
|
839
856
|
entries.push({ run });
|
|
840
|
-
};
|
|
841
|
-
var register_weak_disposer = (ref, run) => {
|
|
857
|
+
}, "register_disposer");
|
|
858
|
+
var register_weak_disposer = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, (ref, run) => {
|
|
842
859
|
prune();
|
|
843
860
|
entries.push({
|
|
844
861
|
run,
|
|
845
862
|
ref
|
|
846
863
|
});
|
|
847
|
-
};
|
|
848
|
-
var run_disposers = async () => {
|
|
864
|
+
}, "register_weak_disposer");
|
|
865
|
+
var run_disposers = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, async () => {
|
|
849
866
|
for (const { run, ref } of [...entries].reverse()) {
|
|
850
867
|
if (!ref) {
|
|
851
868
|
await run();
|
|
@@ -854,7 +871,7 @@ var run_disposers = async () => {
|
|
|
854
871
|
const target = ref.deref();
|
|
855
872
|
if (target) await run(target);
|
|
856
873
|
}
|
|
857
|
-
};
|
|
874
|
+
}, "run_disposers");
|
|
858
875
|
|
|
859
876
|
// src/internal/config.ts
|
|
860
877
|
|
|
@@ -930,9 +947,10 @@ function is_time_zone(tz) {
|
|
|
930
947
|
return false;
|
|
931
948
|
}
|
|
932
949
|
}
|
|
933
|
-
|
|
950
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, is_time_zone, "is_time_zone");
|
|
951
|
+
var hour = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, (field) => _zod.z.number().int().min(0).max(23, {
|
|
934
952
|
message: `autocloseWindow.${field} must be an hour in [0, 23]`
|
|
935
|
-
});
|
|
953
|
+
}), "hour");
|
|
936
954
|
var AutocloseOptionsSchema = _zod.z.object({
|
|
937
955
|
autocloseWindow: _zod.z.object({
|
|
938
956
|
start: hour("start"),
|
|
@@ -964,11 +982,11 @@ var DeferWhenSchema = _zod.z.object({
|
|
|
964
982
|
}).strict().refine((w) => w.after === void 0 !== (w.at === void 0), {
|
|
965
983
|
message: "defer: specify exactly one of `after` or `at`"
|
|
966
984
|
});
|
|
967
|
-
var window_schema = (field, min_days, floor) => _zod.z.object({
|
|
985
|
+
var window_schema = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, (field, min_days, floor) => _zod.z.object({
|
|
968
986
|
days: _zod.z.number({ message: `autocloses: ${field}.days must be a number` }).positive(`autocloses: ${field}.days must be > 0`)
|
|
969
987
|
}).refine((o) => o.days >= min_days, {
|
|
970
988
|
message: `autocloses: ${field} resolves to < ${floor}, which is too short to be a meaningful retention window`
|
|
971
|
-
});
|
|
989
|
+
}), "window_schema");
|
|
972
990
|
var AfterSchema = window_schema("after", 1 / 1440, "one minute");
|
|
973
991
|
var IsSchema = _zod.z.union([
|
|
974
992
|
_zod.z.string().min(1, "autocloses: is must be a non-empty event name"),
|
|
@@ -1028,6 +1046,7 @@ var SCHEMAS = {
|
|
|
1028
1046
|
function check(kind, options) {
|
|
1029
1047
|
return SCHEMAS[kind].parse(options);
|
|
1030
1048
|
}
|
|
1049
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, check, "check");
|
|
1031
1050
|
|
|
1032
1051
|
// src/scoped.ts
|
|
1033
1052
|
var _async_hooks = require('async_hooks');
|
|
@@ -1036,12 +1055,15 @@ var reacting = new (0, _async_hooks.AsyncLocalStorage)();
|
|
|
1036
1055
|
function make_run_scoped(bag) {
|
|
1037
1056
|
return (fn) => scoped.run(bag, fn);
|
|
1038
1057
|
}
|
|
1058
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, make_run_scoped, "make_run_scoped");
|
|
1039
1059
|
function current_autoclose_window() {
|
|
1040
1060
|
return _optionalChain([scoped, 'access', _55 => _55.getStore, 'call', _56 => _56(), 'optionalAccess', _57 => _57.autoclose_window]);
|
|
1041
1061
|
}
|
|
1062
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, current_autoclose_window, "current_autoclose_window");
|
|
1042
1063
|
function current_ports() {
|
|
1043
1064
|
return scoped.getStore();
|
|
1044
1065
|
}
|
|
1066
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, current_ports, "current_ports");
|
|
1045
1067
|
function run_reacting(event, fn) {
|
|
1046
1068
|
const box = { event };
|
|
1047
1069
|
return reacting.run(box, async () => {
|
|
@@ -1052,12 +1074,15 @@ function run_reacting(event, fn) {
|
|
|
1052
1074
|
}
|
|
1053
1075
|
});
|
|
1054
1076
|
}
|
|
1077
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, run_reacting, "run_reacting");
|
|
1055
1078
|
function current_reacting() {
|
|
1056
1079
|
return _optionalChain([reacting, 'access', _58 => _58.getStore, 'call', _59 => _59(), 'optionalAccess', _60 => _60.event]);
|
|
1057
1080
|
}
|
|
1081
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, current_reacting, "current_reacting");
|
|
1058
1082
|
function make_reaction_scope(app) {
|
|
1059
1083
|
return { app, run: run_reacting };
|
|
1060
1084
|
}
|
|
1085
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, make_reaction_scope, "make_reaction_scope");
|
|
1061
1086
|
|
|
1062
1087
|
// src/ports.ts
|
|
1063
1088
|
var adapters = /* @__PURE__ */ new Map();
|
|
@@ -1071,27 +1096,28 @@ function port(injector) {
|
|
|
1071
1096
|
return adapters.get(injector.name);
|
|
1072
1097
|
};
|
|
1073
1098
|
}
|
|
1074
|
-
|
|
1099
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, port, "port");
|
|
1100
|
+
var log = port(/* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, function log2(adapter) {
|
|
1075
1101
|
const cfg = config();
|
|
1076
1102
|
return adapter || new ConsoleLogger({
|
|
1077
1103
|
level: cfg.logLevel,
|
|
1078
1104
|
pretty: cfg.env !== "production"
|
|
1079
1105
|
});
|
|
1080
|
-
});
|
|
1081
|
-
var _store = port(function store(adapter) {
|
|
1106
|
+
}, "log"));
|
|
1107
|
+
var _store = port(/* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, function store(adapter) {
|
|
1082
1108
|
if (adapter) check("store", adapter);
|
|
1083
1109
|
return _nullishCoalesce(adapter, () => ( new InMemoryStore()));
|
|
1084
|
-
});
|
|
1085
|
-
var store2 = ((adapter) => {
|
|
1110
|
+
}, "store"));
|
|
1111
|
+
var store2 = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, ((adapter) => {
|
|
1086
1112
|
return _nullishCoalesce(_optionalChain([current_ports, 'call', _61 => _61(), 'optionalAccess', _62 => _62.store]), () => ( _store(adapter)));
|
|
1087
|
-
});
|
|
1088
|
-
var _cache = port(function cache(adapter) {
|
|
1113
|
+
}), "store");
|
|
1114
|
+
var _cache = port(/* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, function cache(adapter) {
|
|
1089
1115
|
return _nullishCoalesce(adapter, () => ( new InMemoryCache()));
|
|
1090
|
-
});
|
|
1091
|
-
var cache2 = ((adapter) => {
|
|
1116
|
+
}, "cache"));
|
|
1117
|
+
var cache2 = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, ((adapter) => {
|
|
1092
1118
|
return _nullishCoalesce(_optionalChain([current_ports, 'call', _63 => _63(), 'optionalAccess', _64 => _64.cache]), () => ( _cache(adapter)));
|
|
1093
|
-
});
|
|
1094
|
-
var unscoped_ports = () => DEFAULT_SCOPE;
|
|
1119
|
+
}), "cache");
|
|
1120
|
+
var unscoped_ports = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, () => DEFAULT_SCOPE, "unscoped_ports");
|
|
1095
1121
|
var DEFAULT_SCOPE = {
|
|
1096
1122
|
get store() {
|
|
1097
1123
|
return _store();
|
|
@@ -1115,10 +1141,12 @@ async function disposeAndExit(code = "EXIT") {
|
|
|
1115
1141
|
adapters.clear();
|
|
1116
1142
|
config().env !== "test" && process.exit(code === "ERROR" ? 1 : 0);
|
|
1117
1143
|
}
|
|
1144
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, disposeAndExit, "disposeAndExit");
|
|
1118
1145
|
function dispose(disposer) {
|
|
1119
1146
|
disposer && register_disposer(disposer);
|
|
1120
1147
|
return disposeAndExit;
|
|
1121
1148
|
}
|
|
1149
|
+
_chunkQSXWCJ2Ucjs.__name.call(void 0, dispose, "dispose");
|
|
1122
1150
|
|
|
1123
1151
|
// src/config.ts
|
|
1124
1152
|
var package_schema = _zod.z.object({
|
|
@@ -1134,7 +1162,7 @@ var FALLBACK_PACKAGE = {
|
|
|
1134
1162
|
version: "0.0.0-fallback",
|
|
1135
1163
|
description: "Synthetic fallback \u2014 package.json could not be loaded"
|
|
1136
1164
|
};
|
|
1137
|
-
var get_package = () => {
|
|
1165
|
+
var get_package = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, () => {
|
|
1138
1166
|
try {
|
|
1139
1167
|
const raw = JSON.parse(fs.readFileSync("package.json").toString());
|
|
1140
1168
|
const pkg2 = {
|
|
@@ -1150,11 +1178,11 @@ var get_package = () => {
|
|
|
1150
1178
|
pkg_load_error = err;
|
|
1151
1179
|
return FALLBACK_PACKAGE;
|
|
1152
1180
|
}
|
|
1153
|
-
};
|
|
1181
|
+
}, "get_package");
|
|
1154
1182
|
var pkg_load_error;
|
|
1155
1183
|
var BaseSchema = package_schema.extend({
|
|
1156
|
-
env: _zod.z.enum(
|
|
1157
|
-
logLevel: _zod.z.enum(
|
|
1184
|
+
env: _zod.z.enum(_chunkQSXWCJ2Ucjs.Environments),
|
|
1185
|
+
logLevel: _zod.z.enum(_chunkQSXWCJ2Ucjs.LogLevels),
|
|
1158
1186
|
logSingleLine: _zod.z.boolean(),
|
|
1159
1187
|
sleepMs: _zod.z.number().int().min(0).max(5e3)
|
|
1160
1188
|
});
|
|
@@ -1165,7 +1193,7 @@ var logSingleLine = (LOG_SINGLE_LINE || "true") === "true";
|
|
|
1165
1193
|
var sleepMs = parseInt(NODE_ENV === "test" ? "0" : _nullishCoalesce(SLEEP_MS, () => ( "100")), 10);
|
|
1166
1194
|
var pkg = get_package();
|
|
1167
1195
|
var _validated;
|
|
1168
|
-
var config = () => {
|
|
1196
|
+
var config = /* @__PURE__ */ _chunkQSXWCJ2Ucjs.__name.call(void 0, () => {
|
|
1169
1197
|
if (!_validated) {
|
|
1170
1198
|
_validated = validate(
|
|
1171
1199
|
"config",
|
|
@@ -1181,7 +1209,7 @@ var config = () => {
|
|
|
1181
1209
|
}
|
|
1182
1210
|
}
|
|
1183
1211
|
return _validated;
|
|
1184
|
-
};
|
|
1212
|
+
}, "config");
|
|
1185
1213
|
|
|
1186
1214
|
|
|
1187
1215
|
|
|
@@ -1213,4 +1241,4 @@ var config = () => {
|
|
|
1213
1241
|
|
|
1214
1242
|
|
|
1215
1243
|
exports.ConsoleLogger = ConsoleLogger; exports.LruMap = LruMap; exports.InMemoryCache = InMemoryCache; exports.package_schema = package_schema; exports.config = config; exports.validate = validate; exports.sleep = sleep; exports.InMemoryStore = InMemoryStore; exports.register_weak_disposer = register_weak_disposer; exports.DEFAULT_BACKOFF = DEFAULT_BACKOFF; exports.DEFAULT_MAX_RETRIES = DEFAULT_MAX_RETRIES; exports.DEFAULT_BLOCK_ON_ERROR = DEFAULT_BLOCK_ON_ERROR; exports.DEFAULT_STREAM_LIMIT = DEFAULT_STREAM_LIMIT; exports.DEFAULT_EVENT_LIMIT = DEFAULT_EVENT_LIMIT; exports.DEFAULT_LEASE_MILLIS = DEFAULT_LEASE_MILLIS; exports.MAX_SHUTDOWN_GRACE_MS = MAX_SHUTDOWN_GRACE_MS; exports.check = check; exports.make_run_scoped = make_run_scoped; exports.current_autoclose_window = current_autoclose_window; exports.current_reacting = current_reacting; exports.make_reaction_scope = make_reaction_scope; exports.port = port; exports.log = log; exports.store = store2; exports.cache = cache2; exports.unscoped_ports = unscoped_ports; exports.disposeAndExit = disposeAndExit; exports.dispose = dispose;
|
|
1216
|
-
//# sourceMappingURL=chunk-
|
|
1244
|
+
//# sourceMappingURL=chunk-OW67FBYO.cjs.map
|