@contello/client 2.2.3 → 3.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/index.cjs +36 -344
- package/dist/index.d.cts +1 -65
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.ts +1 -65
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +36 -313
- package/dist/index.js.map +1 -1
- package/package.json +4 -2
package/dist/index.cjs
CHANGED
|
@@ -1,190 +1,8 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
var __defProp = Object.defineProperty;
|
|
5
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
-
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
8
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
|
-
var __copyProps = (to, from, except, desc) => {
|
|
10
|
-
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
11
|
-
key = keys[i];
|
|
12
|
-
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
13
|
-
get: ((k) => from[k]).bind(null, key),
|
|
14
|
-
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
|
-
});
|
|
16
|
-
}
|
|
17
|
-
return to;
|
|
18
|
-
};
|
|
19
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
|
|
20
|
-
value: mod,
|
|
21
|
-
enumerable: true
|
|
22
|
-
}) : target, mod));
|
|
23
|
-
//#endregion
|
|
2
|
+
let _contello_opentelemetry = require("@contello/opentelemetry");
|
|
3
|
+
let _entwico_dash_async = require("@entwico/dash/async");
|
|
24
4
|
let graphql_ws = require("graphql-ws");
|
|
25
|
-
let node_diagnostics_channel = require("node:diagnostics_channel");
|
|
26
|
-
node_diagnostics_channel = __toESM(node_diagnostics_channel, 1);
|
|
27
5
|
let undici = require("undici");
|
|
28
|
-
//#region src/async-iterable-utils.ts
|
|
29
|
-
const MAX_BACKOFF_MS = 3e4;
|
|
30
|
-
const JITTER_MIN_MS$1 = 300;
|
|
31
|
-
const JITTER_MAX_MS$1 = 3e3;
|
|
32
|
-
/**
|
|
33
|
-
* Returns the first value yielded by `iter`, then disposes the iterator. Throws if the iterable
|
|
34
|
-
* completes without yielding. Equivalent of rxjs's `firstValueFrom` for AsyncIterables.
|
|
35
|
-
*/
|
|
36
|
-
async function firstAsync(iter) {
|
|
37
|
-
const it = iter[Symbol.asyncIterator]();
|
|
38
|
-
try {
|
|
39
|
-
const result = await it.next();
|
|
40
|
-
if (result.done) throw new Error("firstAsync: async iterable completed without yielding a value");
|
|
41
|
-
return result.value;
|
|
42
|
-
} finally {
|
|
43
|
-
await it.return?.();
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
/** Lazy map over an async iterable. Cleanup propagates: breaking the outer iter disposes the inner. */
|
|
47
|
-
async function* mapAsync(iter, fn) {
|
|
48
|
-
for await (const value of iter) yield fn(value);
|
|
49
|
-
}
|
|
50
|
-
/** Lazy filter over an async iterable. */
|
|
51
|
-
async function* filterAsync(iter, predicate) {
|
|
52
|
-
for await (const value of iter) if (predicate(value)) yield value;
|
|
53
|
-
}
|
|
54
|
-
/**
|
|
55
|
-
* Concatenates all elements of all arrays yielded by `iter` into a single array. Used to support
|
|
56
|
-
* subscriptions that emit chunks of items before completing.
|
|
57
|
-
*/
|
|
58
|
-
async function collectAsync(iter) {
|
|
59
|
-
const out = [];
|
|
60
|
-
for await (const chunk of iter) out.push(...chunk);
|
|
61
|
-
return out;
|
|
62
|
-
}
|
|
63
|
-
/**
|
|
64
|
-
* Exponential backoff with jitter. `attempt` starts at 0 → ~1s+jitter, 1 → ~2s+jitter, etc.,
|
|
65
|
-
* capped at 30s. Returns a Promise that resolves after the delay.
|
|
66
|
-
*/
|
|
67
|
-
function exponentialBackoff(attempt) {
|
|
68
|
-
return delay(Math.min(Math.pow(2, attempt) * 1e3, MAX_BACKOFF_MS) + Math.floor(Math.random() * (JITTER_MAX_MS$1 - JITTER_MIN_MS$1) + JITTER_MIN_MS$1));
|
|
69
|
-
}
|
|
70
|
-
function delay(ms, signal) {
|
|
71
|
-
if (signal?.aborted) return Promise.reject(signal.reason);
|
|
72
|
-
return new Promise((resolve, reject) => {
|
|
73
|
-
const timer = setTimeout(() => {
|
|
74
|
-
signal?.removeEventListener("abort", onAbort);
|
|
75
|
-
resolve();
|
|
76
|
-
}, ms);
|
|
77
|
-
const onAbort = () => {
|
|
78
|
-
clearTimeout(timer);
|
|
79
|
-
reject(signal.reason);
|
|
80
|
-
};
|
|
81
|
-
signal?.addEventListener("abort", onAbort, { once: true });
|
|
82
|
-
});
|
|
83
|
-
}
|
|
84
|
-
/**
|
|
85
|
-
* Runs `fn` with exponential-backoff retry on rejection. Returns once `fn` resolves successfully.
|
|
86
|
-
* `signal` aborts both the in-flight `fn` (if it observes the signal) and the backoff wait.
|
|
87
|
-
*/
|
|
88
|
-
async function runWithBackoff(fn, signal) {
|
|
89
|
-
let attempt = 0;
|
|
90
|
-
for (;;) {
|
|
91
|
-
if (signal?.aborted) throw signal.reason;
|
|
92
|
-
try {
|
|
93
|
-
await fn();
|
|
94
|
-
return;
|
|
95
|
-
} catch {
|
|
96
|
-
await exponentialBackoffWithSignal(attempt, signal);
|
|
97
|
-
attempt++;
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
function exponentialBackoffWithSignal(attempt, signal) {
|
|
102
|
-
return delay(Math.min(Math.pow(2, attempt) * 1e3, MAX_BACKOFF_MS) + Math.floor(Math.random() * (JITTER_MAX_MS$1 - JITTER_MIN_MS$1) + JITTER_MIN_MS$1), signal);
|
|
103
|
-
}
|
|
104
|
-
/**
|
|
105
|
-
* Long-running stream wrapper: subscribes via `factory()`, yields every value, and on error or
|
|
106
|
-
* unexpected completion re-subscribes with exponential backoff. Stops only when `signal` aborts.
|
|
107
|
-
* Designed for subscriptions that should stay open across reconnects (e.g. the watcher).
|
|
108
|
-
*/
|
|
109
|
-
async function* asyncKeepalive(factory, signal) {
|
|
110
|
-
let attempt = 0;
|
|
111
|
-
while (!signal?.aborted) try {
|
|
112
|
-
for await (const value of factory()) {
|
|
113
|
-
if (signal?.aborted) return;
|
|
114
|
-
yield value;
|
|
115
|
-
attempt = 0;
|
|
116
|
-
}
|
|
117
|
-
attempt = 0;
|
|
118
|
-
} catch (error) {
|
|
119
|
-
if (signal?.aborted) return;
|
|
120
|
-
await exponentialBackoffWithSignal(attempt, signal);
|
|
121
|
-
attempt++;
|
|
122
|
-
}
|
|
123
|
-
}
|
|
124
|
-
//#endregion
|
|
125
|
-
//#region src/diagnostics.ts
|
|
126
|
-
const channels = {
|
|
127
|
-
start: "@contello/client:start",
|
|
128
|
-
end: "@contello/client:end",
|
|
129
|
-
error: "@contello/client:error",
|
|
130
|
-
/** subscribe to decorate outgoing GraphQL WebSocket messages (e.g. inject traceparent) */
|
|
131
|
-
message: "@contello/client:message"
|
|
132
|
-
};
|
|
133
|
-
const onStart = node_diagnostics_channel.default.channel(channels.start);
|
|
134
|
-
const onEnd = node_diagnostics_channel.default.channel(channels.end);
|
|
135
|
-
const onError = node_diagnostics_channel.default.channel(channels.error);
|
|
136
|
-
const onMessage = node_diagnostics_channel.default.channel(channels.message);
|
|
137
|
-
function hasOperationSubscribers() {
|
|
138
|
-
return onStart.hasSubscribers || onEnd.hasSubscribers || onError.hasSubscribers;
|
|
139
|
-
}
|
|
140
|
-
function wrap(name, fn) {
|
|
141
|
-
if (!hasOperationSubscribers()) return fn();
|
|
142
|
-
const start = performance.now();
|
|
143
|
-
onStart.publish({ name });
|
|
144
|
-
let result;
|
|
145
|
-
try {
|
|
146
|
-
result = fn();
|
|
147
|
-
} catch (error) {
|
|
148
|
-
onError.publish({
|
|
149
|
-
name,
|
|
150
|
-
error,
|
|
151
|
-
durationMs: performance.now() - start
|
|
152
|
-
});
|
|
153
|
-
throw error;
|
|
154
|
-
}
|
|
155
|
-
if (result instanceof Promise) {
|
|
156
|
-
const promise = result;
|
|
157
|
-
return (async () => {
|
|
158
|
-
try {
|
|
159
|
-
const r = await promise;
|
|
160
|
-
onEnd.publish({
|
|
161
|
-
name,
|
|
162
|
-
durationMs: performance.now() - start
|
|
163
|
-
});
|
|
164
|
-
return r;
|
|
165
|
-
} catch (error) {
|
|
166
|
-
onError.publish({
|
|
167
|
-
name,
|
|
168
|
-
error,
|
|
169
|
-
durationMs: performance.now() - start
|
|
170
|
-
});
|
|
171
|
-
throw error;
|
|
172
|
-
}
|
|
173
|
-
})();
|
|
174
|
-
}
|
|
175
|
-
onEnd.publish({
|
|
176
|
-
name,
|
|
177
|
-
durationMs: performance.now() - start
|
|
178
|
-
});
|
|
179
|
-
return result;
|
|
180
|
-
}
|
|
181
|
-
function decorateMessage(message) {
|
|
182
|
-
if (!onMessage.hasSubscribers) return message;
|
|
183
|
-
const msg = { message };
|
|
184
|
-
onMessage.publish(msg);
|
|
185
|
-
return msg.message;
|
|
186
|
-
}
|
|
187
|
-
//#endregion
|
|
188
6
|
//#region src/http.ts
|
|
189
7
|
const SAFE_SEGMENT = /^[A-Za-z0-9._-]+$/;
|
|
190
8
|
const FORWARDED_PROXY_HEADERS = /* @__PURE__ */ new Set([
|
|
@@ -388,6 +206,9 @@ var ConnectionPool = class {
|
|
|
388
206
|
}
|
|
389
207
|
};
|
|
390
208
|
//#endregion
|
|
209
|
+
//#region src/telemetry.ts
|
|
210
|
+
const { wrap } = (0, _contello_opentelemetry.createOperationTelemetry)("@contello/client");
|
|
211
|
+
//#endregion
|
|
391
212
|
//#region src/scalars.ts
|
|
392
213
|
const LOCAL_DATE_TIME_KEYS = [
|
|
393
214
|
"year",
|
|
@@ -475,7 +296,10 @@ function transformVariables(value) {
|
|
|
475
296
|
//#region src/rpc.ts
|
|
476
297
|
function buildRpc(operations, subscribe) {
|
|
477
298
|
const rpc = {};
|
|
478
|
-
for (const [name, def] of Object.entries(operations)) rpc[name] = def.kind === "subscription" ? (variables) => subscribe(def.document, transformVariables(variables)) : (variables) =>
|
|
299
|
+
for (const [name, def] of Object.entries(operations)) rpc[name] = def.kind === "subscription" ? (variables) => subscribe(def.document, transformVariables(variables)) : (variables) => {
|
|
300
|
+
const vars = transformVariables(variables);
|
|
301
|
+
return wrap(`rpc:${name}`, () => (0, _entwico_dash_async.firstAsync)(subscribe(def.document, vars)), (0, _contello_opentelemetry.graphqlOperationAttributes)(def.document, vars));
|
|
302
|
+
};
|
|
479
303
|
return rpc;
|
|
480
304
|
}
|
|
481
305
|
//#endregion
|
|
@@ -511,17 +335,29 @@ function createSources(sources, subscribe) {
|
|
|
511
335
|
}
|
|
512
336
|
function createSourceAccessor(name, def, doc, subscribe) {
|
|
513
337
|
switch (def.__cardinality) {
|
|
514
|
-
case "singleton": return { fetch: () => wrap(`source:${name}`, () => firstAsync(mapAsync(subscribe(doc), (r) => r.source))) };
|
|
515
|
-
case "entity": return { fetch: (vars) =>
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
338
|
+
case "singleton": return { fetch: () => wrap(`source:${name}`, () => (0, _entwico_dash_async.firstAsync)((0, _entwico_dash_async.mapAsync)(subscribe(doc), (r) => r.source)), (0, _contello_opentelemetry.graphqlOperationAttributes)(doc)) };
|
|
339
|
+
case "entity": return { fetch: (vars) => {
|
|
340
|
+
const variables = transformVariables({ ids: vars?.ids });
|
|
341
|
+
return wrap(`source:${name}`, () => (0, _entwico_dash_async.concatAsync)((0, _entwico_dash_async.mapAsync)(subscribe(doc, variables), (r) => r.source)), (0, _contello_opentelemetry.graphqlOperationAttributes)(doc, variables));
|
|
342
|
+
} };
|
|
343
|
+
case "route": return { fetch: (vars) => {
|
|
344
|
+
const variables = transformVariables({
|
|
345
|
+
ids: vars?.ids,
|
|
346
|
+
paths: vars?.paths
|
|
347
|
+
});
|
|
348
|
+
return wrap(`source:${name}`, () => (0, _entwico_dash_async.concatAsync)((0, _entwico_dash_async.mapAsync)(subscribe(doc, variables), (r) => r.source)), (0, _contello_opentelemetry.graphqlOperationAttributes)(doc, variables));
|
|
349
|
+
} };
|
|
350
|
+
case "asset": return { fetch: (vars) => {
|
|
351
|
+
const variables = transformVariables({ ids: vars?.ids });
|
|
352
|
+
return wrap(`source:${name}`, () => (0, _entwico_dash_async.concatAsync)((0, _entwico_dash_async.mapAsync)(subscribe(doc, variables), (r) => r.source)), (0, _contello_opentelemetry.graphqlOperationAttributes)(doc, variables));
|
|
353
|
+
} };
|
|
354
|
+
case "i18nMessage": return { fetch: (vars) => {
|
|
355
|
+
const variables = transformVariables({
|
|
356
|
+
collection: vars.collection,
|
|
357
|
+
ids: vars.ids
|
|
358
|
+
});
|
|
359
|
+
return wrap(`source:${name}`, () => (0, _entwico_dash_async.concatAsync)((0, _entwico_dash_async.mapAsync)(subscribe(doc, variables), (r) => r.source)), (0, _contello_opentelemetry.graphqlOperationAttributes)(doc, variables));
|
|
360
|
+
} };
|
|
525
361
|
}
|
|
526
362
|
}
|
|
527
363
|
//#endregion
|
|
@@ -706,15 +542,6 @@ function upload(url, project, token, data, meta, options) {
|
|
|
706
542
|
});
|
|
707
543
|
}
|
|
708
544
|
//#endregion
|
|
709
|
-
//#region src/utils.ts
|
|
710
|
-
const MAX_DELAY_MS = 3e4;
|
|
711
|
-
const JITTER_MIN_MS = 300;
|
|
712
|
-
const JITTER_MAX_MS = 3e3;
|
|
713
|
-
function wsRetryWait(retries) {
|
|
714
|
-
const delay = Math.min(Math.pow(2, retries) * 1e3, MAX_DELAY_MS) + Math.floor(Math.random() * (JITTER_MAX_MS - JITTER_MIN_MS) + JITTER_MIN_MS);
|
|
715
|
-
return new Promise((resolve) => setTimeout(resolve, delay));
|
|
716
|
-
}
|
|
717
|
-
//#endregion
|
|
718
545
|
//#region src/client.ts
|
|
719
546
|
var ContelloClient = class {
|
|
720
547
|
_pool;
|
|
@@ -758,10 +585,10 @@ var ContelloClient = class {
|
|
|
758
585
|
lazy: false,
|
|
759
586
|
keepAlive: 3e4,
|
|
760
587
|
retryAttempts: Infinity,
|
|
761
|
-
retryWait:
|
|
588
|
+
retryWait: _entwico_dash_async.exponentialBackoff,
|
|
762
589
|
shouldRetry: () => true,
|
|
763
590
|
jsonMessageReplacer: (key, value) => {
|
|
764
|
-
if (!key) return
|
|
591
|
+
if (!key) return (0, _contello_opentelemetry.injectTraceContext)(value);
|
|
765
592
|
return value;
|
|
766
593
|
},
|
|
767
594
|
...options.onError && { onNonLazyError: (e) => options.onError(e) },
|
|
@@ -803,7 +630,7 @@ var ContelloClient = class {
|
|
|
803
630
|
await this._agent.close();
|
|
804
631
|
}
|
|
805
632
|
async ping() {
|
|
806
|
-
return ping((query) => firstAsync(this.subscribe(query)));
|
|
633
|
+
return ping((query) => (0, _entwico_dash_async.firstAsync)(this.subscribe(query)));
|
|
807
634
|
}
|
|
808
635
|
/**
|
|
809
636
|
* Open a subscription on the websocket. Each `[Symbol.asyncIterator]()` call (the implicit one
|
|
@@ -897,148 +724,13 @@ var ContelloClient = class {
|
|
|
897
724
|
return wrap("@contello/client:upload", () => upload(this._url, this._project, this._token, data, meta, options));
|
|
898
725
|
}
|
|
899
726
|
execute(query, variables) {
|
|
900
|
-
return wrap("@contello/client:execute", () => firstAsync(this.subscribe(query, variables)));
|
|
727
|
+
return wrap("@contello/client:execute", () => (0, _entwico_dash_async.firstAsync)(this.subscribe(query, variables)), (0, _contello_opentelemetry.graphqlOperationAttributes)(query, variables));
|
|
901
728
|
}
|
|
902
729
|
};
|
|
903
730
|
function createContelloClient(options) {
|
|
904
731
|
return new ContelloClient(options);
|
|
905
732
|
}
|
|
906
733
|
//#endregion
|
|
907
|
-
//#region src/async-iterable-subject.ts
|
|
908
|
-
function createAsyncIterableSubject() {
|
|
909
|
-
const consumers = /* @__PURE__ */ new Set();
|
|
910
|
-
let status = { state: "open" };
|
|
911
|
-
const next = (value) => {
|
|
912
|
-
if (status.state !== "open") return;
|
|
913
|
-
for (const consumer of consumers) if (consumer.kind === "listener") consumer.next?.(value);
|
|
914
|
-
else if (consumer.pending) {
|
|
915
|
-
const p = consumer.pending;
|
|
916
|
-
consumer.pending = void 0;
|
|
917
|
-
p.resolve({
|
|
918
|
-
value,
|
|
919
|
-
done: false
|
|
920
|
-
});
|
|
921
|
-
} else consumer.queue.push(value);
|
|
922
|
-
};
|
|
923
|
-
const error = (err) => {
|
|
924
|
-
if (status.state !== "open") return;
|
|
925
|
-
status = {
|
|
926
|
-
state: "errored",
|
|
927
|
-
err
|
|
928
|
-
};
|
|
929
|
-
for (const consumer of consumers) if (consumer.kind === "listener") consumer.error?.(err);
|
|
930
|
-
else if (consumer.pending) {
|
|
931
|
-
const p = consumer.pending;
|
|
932
|
-
consumer.pending = void 0;
|
|
933
|
-
p.reject(err);
|
|
934
|
-
}
|
|
935
|
-
consumers.clear();
|
|
936
|
-
};
|
|
937
|
-
const complete = () => {
|
|
938
|
-
if (status.state !== "open") return;
|
|
939
|
-
status = { state: "completed" };
|
|
940
|
-
for (const consumer of consumers) if (consumer.kind === "listener") consumer.complete?.();
|
|
941
|
-
else if (consumer.pending) {
|
|
942
|
-
const p = consumer.pending;
|
|
943
|
-
consumer.pending = void 0;
|
|
944
|
-
p.resolve({
|
|
945
|
-
value: void 0,
|
|
946
|
-
done: true
|
|
947
|
-
});
|
|
948
|
-
}
|
|
949
|
-
consumers.clear();
|
|
950
|
-
};
|
|
951
|
-
const subscribe = (observerOrNext) => {
|
|
952
|
-
if (status.state !== "open") return () => {};
|
|
953
|
-
const consumer = {
|
|
954
|
-
kind: "listener",
|
|
955
|
-
...typeof observerOrNext === "function" ? { next: observerOrNext } : observerOrNext
|
|
956
|
-
};
|
|
957
|
-
consumers.add(consumer);
|
|
958
|
-
return () => {
|
|
959
|
-
consumers.delete(consumer);
|
|
960
|
-
};
|
|
961
|
-
};
|
|
962
|
-
return Object.assign({ [Symbol.asyncIterator]() {
|
|
963
|
-
if (status.state === "errored") {
|
|
964
|
-
const err = status.err;
|
|
965
|
-
return {
|
|
966
|
-
next: () => Promise.reject(err),
|
|
967
|
-
return: () => Promise.resolve({
|
|
968
|
-
value: void 0,
|
|
969
|
-
done: true
|
|
970
|
-
})
|
|
971
|
-
};
|
|
972
|
-
}
|
|
973
|
-
if (status.state === "completed") return {
|
|
974
|
-
next: () => Promise.resolve({
|
|
975
|
-
value: void 0,
|
|
976
|
-
done: true
|
|
977
|
-
}),
|
|
978
|
-
return: () => Promise.resolve({
|
|
979
|
-
value: void 0,
|
|
980
|
-
done: true
|
|
981
|
-
})
|
|
982
|
-
};
|
|
983
|
-
const consumer = {
|
|
984
|
-
kind: "iterator",
|
|
985
|
-
queue: []
|
|
986
|
-
};
|
|
987
|
-
consumers.add(consumer);
|
|
988
|
-
return {
|
|
989
|
-
next() {
|
|
990
|
-
if (consumer.queue.length > 0) return Promise.resolve({
|
|
991
|
-
value: consumer.queue.shift(),
|
|
992
|
-
done: false
|
|
993
|
-
});
|
|
994
|
-
if (status.state === "errored") return Promise.reject(status.err);
|
|
995
|
-
if (status.state === "completed") return Promise.resolve({
|
|
996
|
-
value: void 0,
|
|
997
|
-
done: true
|
|
998
|
-
});
|
|
999
|
-
return new Promise((resolve, reject) => {
|
|
1000
|
-
consumer.pending = {
|
|
1001
|
-
resolve,
|
|
1002
|
-
reject
|
|
1003
|
-
};
|
|
1004
|
-
});
|
|
1005
|
-
},
|
|
1006
|
-
return() {
|
|
1007
|
-
consumers.delete(consumer);
|
|
1008
|
-
if (consumer.pending) {
|
|
1009
|
-
const p = consumer.pending;
|
|
1010
|
-
consumer.pending = void 0;
|
|
1011
|
-
p.resolve({
|
|
1012
|
-
value: void 0,
|
|
1013
|
-
done: true
|
|
1014
|
-
});
|
|
1015
|
-
}
|
|
1016
|
-
return Promise.resolve({
|
|
1017
|
-
value: void 0,
|
|
1018
|
-
done: true
|
|
1019
|
-
});
|
|
1020
|
-
},
|
|
1021
|
-
throw(err) {
|
|
1022
|
-
consumers.delete(consumer);
|
|
1023
|
-
return Promise.reject(err);
|
|
1024
|
-
}
|
|
1025
|
-
};
|
|
1026
|
-
} }, {
|
|
1027
|
-
next,
|
|
1028
|
-
error,
|
|
1029
|
-
complete,
|
|
1030
|
-
subscribe
|
|
1031
|
-
});
|
|
1032
|
-
}
|
|
1033
|
-
//#endregion
|
|
1034
734
|
exports.ContelloClient = ContelloClient;
|
|
1035
|
-
exports.asyncKeepalive = asyncKeepalive;
|
|
1036
|
-
exports.collectAsync = collectAsync;
|
|
1037
|
-
exports.createAsyncIterableSubject = createAsyncIterableSubject;
|
|
1038
735
|
exports.createContelloClient = createContelloClient;
|
|
1039
736
|
exports.createSourceSubscription = createSourceSubscription;
|
|
1040
|
-
exports.exponentialBackoff = exponentialBackoff;
|
|
1041
|
-
exports.filterAsync = filterAsync;
|
|
1042
|
-
exports.firstAsync = firstAsync;
|
|
1043
|
-
exports.mapAsync = mapAsync;
|
|
1044
|
-
exports.runWithBackoff = runWithBackoff;
|
package/dist/index.d.cts
CHANGED
|
@@ -162,69 +162,5 @@ type LocalDate = {
|
|
|
162
162
|
//#region src/source-subscription.d.ts
|
|
163
163
|
declare function createSourceSubscription(source: SourceDef): string;
|
|
164
164
|
//#endregion
|
|
165
|
-
|
|
166
|
-
/**
|
|
167
|
-
* Returns the first value yielded by `iter`, then disposes the iterator. Throws if the iterable
|
|
168
|
-
* completes without yielding. Equivalent of rxjs's `firstValueFrom` for AsyncIterables.
|
|
169
|
-
*/
|
|
170
|
-
declare function firstAsync<T>(iter: AsyncIterable<T>): Promise<T>;
|
|
171
|
-
/** Lazy map over an async iterable. Cleanup propagates: breaking the outer iter disposes the inner. */
|
|
172
|
-
declare function mapAsync<T, R>(iter: AsyncIterable<T>, fn: (value: T) => R): AsyncIterable<R>;
|
|
173
|
-
/** Lazy filter over an async iterable. */
|
|
174
|
-
declare function filterAsync<T>(iter: AsyncIterable<T>, predicate: (value: T) => boolean): AsyncIterable<T>;
|
|
175
|
-
/**
|
|
176
|
-
* Concatenates all elements of all arrays yielded by `iter` into a single array. Used to support
|
|
177
|
-
* subscriptions that emit chunks of items before completing.
|
|
178
|
-
*/
|
|
179
|
-
declare function collectAsync<T>(iter: AsyncIterable<T[]>): Promise<T[]>;
|
|
180
|
-
/**
|
|
181
|
-
* Exponential backoff with jitter. `attempt` starts at 0 → ~1s+jitter, 1 → ~2s+jitter, etc.,
|
|
182
|
-
* capped at 30s. Returns a Promise that resolves after the delay.
|
|
183
|
-
*/
|
|
184
|
-
declare function exponentialBackoff(attempt: number): Promise<void>;
|
|
185
|
-
/**
|
|
186
|
-
* Runs `fn` with exponential-backoff retry on rejection. Returns once `fn` resolves successfully.
|
|
187
|
-
* `signal` aborts both the in-flight `fn` (if it observes the signal) and the backoff wait.
|
|
188
|
-
*/
|
|
189
|
-
declare function runWithBackoff(fn: () => Promise<unknown>, signal?: AbortSignal | undefined): Promise<void>;
|
|
190
|
-
/**
|
|
191
|
-
* Long-running stream wrapper: subscribes via `factory()`, yields every value, and on error or
|
|
192
|
-
* unexpected completion re-subscribes with exponential backoff. Stops only when `signal` aborts.
|
|
193
|
-
* Designed for subscriptions that should stay open across reconnects (e.g. the watcher).
|
|
194
|
-
*/
|
|
195
|
-
declare function asyncKeepalive<T>(factory: () => AsyncIterable<T>, signal?: AbortSignal | undefined): AsyncIterable<T>;
|
|
196
|
-
//#endregion
|
|
197
|
-
//#region src/async-iterable-subject.d.ts
|
|
198
|
-
/**
|
|
199
|
-
* Multicast event source with `next` / `error` / `complete` (Subject semantics) plus an
|
|
200
|
-
* `AsyncIterable` view. Two consumption modes that fan out from the same source:
|
|
201
|
-
*
|
|
202
|
-
* - `for await (const v of subject)` — iteration. Each `[Symbol.asyncIterator]()` call returns
|
|
203
|
-
* a fresh per-iterator queue. Stop by `break`ing the loop. On `.error(err)` the iterator's
|
|
204
|
-
* pending `next()` rejects, propagating into the for-await as a thrown exception.
|
|
205
|
-
*
|
|
206
|
-
* - `subject.subscribe(observerOrNext)` — observer style. Pass either a full/partial observer
|
|
207
|
-
* `{ next?, error?, complete? }` or just an `(value) => …` function as the `next`-only shortcut.
|
|
208
|
-
* Returns an unsubscribe function. Missing handlers default to no-ops.
|
|
209
|
-
*
|
|
210
|
-
* Producer side: call `.next(value)` to emit, `.error(err)` to fail the subject (all consumers
|
|
211
|
-
* see the error and are detached), `.complete()` to close cleanly (all consumers see done and
|
|
212
|
-
* are detached). After either `error` or `complete`, further `.next()` calls are dropped and
|
|
213
|
-
* new `.subscribe(...)` calls register a no-op unsubscribe.
|
|
214
|
-
*
|
|
215
|
-
* Backpressure: unbounded queue per pending iterator. Intended for low-frequency events.
|
|
216
|
-
*/
|
|
217
|
-
type AsyncIterableSubject<T> = AsyncIterable<T> & {
|
|
218
|
-
next: (value: T) => void;
|
|
219
|
-
error: (err: unknown) => void;
|
|
220
|
-
complete: () => void;
|
|
221
|
-
subscribe: (observerOrNext: ((value: T) => void) | {
|
|
222
|
-
next?: (value: T) => void;
|
|
223
|
-
error?: (err: unknown) => void;
|
|
224
|
-
complete?: () => void;
|
|
225
|
-
}) => () => void;
|
|
226
|
-
};
|
|
227
|
-
declare function createAsyncIterableSubject<T>(): AsyncIterableSubject<T>;
|
|
228
|
-
//#endregion
|
|
229
|
-
export { type AsyncIterableSubject, type ConnectionContext, type ConnectionEvents, ContelloClient, type ContelloClientOptions, type DownloadResult, type HttpAgentOptions, type LocalDate, type LocalDateTime, type OperationDef, type OperationKind, type OperationMap, type ProxyResult, type Rpc, type Schema, type SourceAccessors, type SourceCardinality, type SourceDef, type SourceMap, type UploadData, type UploadMetadata, type UploadOptions, asyncKeepalive, collectAsync, createAsyncIterableSubject, createContelloClient, createSourceSubscription, exponentialBackoff, filterAsync, firstAsync, mapAsync, runWithBackoff };
|
|
165
|
+
export { type ConnectionContext, type ConnectionEvents, ContelloClient, type ContelloClientOptions, type DownloadResult, type HttpAgentOptions, type LocalDate, type LocalDateTime, type OperationDef, type OperationKind, type OperationMap, type ProxyResult, type Rpc, type Schema, type SourceAccessors, type SourceCardinality, type SourceDef, type SourceMap, type UploadData, type UploadMetadata, type UploadOptions, createContelloClient, createSourceSubscription };
|
|
230
166
|
//# sourceMappingURL=index.d.cts.map
|
package/dist/index.d.cts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.cts","names":[],"sources":["../src/http.ts","../src/types.ts","../src/upload.ts","../src/client.ts","../src/scalars.ts","../src/source-subscription.ts"
|
|
1
|
+
{"version":3,"file":"index.d.cts","names":[],"sources":["../src/http.ts","../src/types.ts","../src/upload.ts","../src/client.ts","../src/scalars.ts","../src/source-subscription.ts"],"mappings":";;;KAiCY,gBAAA;EACV,UAAA;EACA,OAAA;EACA,oBAAA;EACA,gBAAA;AAAA;AAAA,KAcU,cAAA;EACV,QAAA;EACA,IAAA;EACA,KAAA,IAAS,OAAA,CAAQ,UAAA;EACjB,MAAA,IAAU,cAAA,CAAe,UAAA;AAAA;AAAA,KAiCf,WAAA;EACV,MAAA;EACA,OAAA,EAAS,OAAA;EACT,MAAA,IAAU,cAAA,CAAe,UAAA;AAAA;;;KC3Ff,aAAA;AAAA,KAEA,YAAA,iCAEG,MAAA,iCACC,aAAA,GAAgB,aAAA;EAE9B,QAAA;EACA,IAAA,EAAM,KAAA,EDyBI;ECvBV,QAAA,GAAW,OAAA;EAEX,WAAA,GAAc,UAAA;AAAA;AAAA,KAGJ,YAAA,GAAe,MAAM,SAAS,YAAA;AAAA,KAE9B,WAAA,WAAsB,YAAA,IAAgB,WAAA,CAAY,CAAA;AAAA,KAClD,cAAA,WAAyB,YAAA,IAAgB,WAAA,CAAY,CAAA;AAAA,KAErD,SAAA,WAAoB,YAAA,IAAgB,CAAA,kCAC5C,cAA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MAAA,gCAAsC,aAAA,CAAc,KAAA;EAuFhG,QAAA,CAAS,MAAA,WAAiB,OAAA,CAAQ,cAAA;EAIlC,QAAA,CAAS,IAAA,UAAc,MAAA,GAAS,WAAA,eAA0B,OAAA,CAAQ,WAAA;EAIlE,MAAA,CAAO,IAAA,EAAM,UAAA,EAAY,IAAA,EAAM,cAAA,EAAgB,OAAA,GAAU,aAAA,eAA4B,OAAA;EAMrF,OAAA,QAAe,KAAA,UAAe,SAAA,GAAY,MAAA,gCAAsC,OAAA,CAAQ,KAAA;AAAA;AAAA,iBAS1E,oBAAA,iBAAqC,MAAA,0BACnD,OAAA,EAAS,qBAAA,CAAsB,OAAA,IAC9B,cAAA,CAAe,OAAA;;;KChSN,aAAA;EACV,IAAA;EACA,KAAA;EACA,GAAA;EACA,IAAA;EACA,MAAA;EACA,MAAA;AAAA;AAAA,KAGU,SAAA;EACV,IAAA;EACA,KAAA;EACA,GAAA;AAAA;;;iBCcc,wBAAA,CAAyB,MAAiB,EAAT,SAAS"}
|
package/dist/index.d.ts
CHANGED
|
@@ -163,69 +163,5 @@ type LocalDate = {
|
|
|
163
163
|
//#region src/source-subscription.d.ts
|
|
164
164
|
declare function createSourceSubscription(source: SourceDef): string;
|
|
165
165
|
//#endregion
|
|
166
|
-
|
|
167
|
-
/**
|
|
168
|
-
* Returns the first value yielded by `iter`, then disposes the iterator. Throws if the iterable
|
|
169
|
-
* completes without yielding. Equivalent of rxjs's `firstValueFrom` for AsyncIterables.
|
|
170
|
-
*/
|
|
171
|
-
declare function firstAsync<T>(iter: AsyncIterable<T>): Promise<T>;
|
|
172
|
-
/** Lazy map over an async iterable. Cleanup propagates: breaking the outer iter disposes the inner. */
|
|
173
|
-
declare function mapAsync<T, R>(iter: AsyncIterable<T>, fn: (value: T) => R): AsyncIterable<R>;
|
|
174
|
-
/** Lazy filter over an async iterable. */
|
|
175
|
-
declare function filterAsync<T>(iter: AsyncIterable<T>, predicate: (value: T) => boolean): AsyncIterable<T>;
|
|
176
|
-
/**
|
|
177
|
-
* Concatenates all elements of all arrays yielded by `iter` into a single array. Used to support
|
|
178
|
-
* subscriptions that emit chunks of items before completing.
|
|
179
|
-
*/
|
|
180
|
-
declare function collectAsync<T>(iter: AsyncIterable<T[]>): Promise<T[]>;
|
|
181
|
-
/**
|
|
182
|
-
* Exponential backoff with jitter. `attempt` starts at 0 → ~1s+jitter, 1 → ~2s+jitter, etc.,
|
|
183
|
-
* capped at 30s. Returns a Promise that resolves after the delay.
|
|
184
|
-
*/
|
|
185
|
-
declare function exponentialBackoff(attempt: number): Promise<void>;
|
|
186
|
-
/**
|
|
187
|
-
* Runs `fn` with exponential-backoff retry on rejection. Returns once `fn` resolves successfully.
|
|
188
|
-
* `signal` aborts both the in-flight `fn` (if it observes the signal) and the backoff wait.
|
|
189
|
-
*/
|
|
190
|
-
declare function runWithBackoff(fn: () => Promise<unknown>, signal?: AbortSignal | undefined): Promise<void>;
|
|
191
|
-
/**
|
|
192
|
-
* Long-running stream wrapper: subscribes via `factory()`, yields every value, and on error or
|
|
193
|
-
* unexpected completion re-subscribes with exponential backoff. Stops only when `signal` aborts.
|
|
194
|
-
* Designed for subscriptions that should stay open across reconnects (e.g. the watcher).
|
|
195
|
-
*/
|
|
196
|
-
declare function asyncKeepalive<T>(factory: () => AsyncIterable<T>, signal?: AbortSignal | undefined): AsyncIterable<T>;
|
|
197
|
-
//#endregion
|
|
198
|
-
//#region src/async-iterable-subject.d.ts
|
|
199
|
-
/**
|
|
200
|
-
* Multicast event source with `next` / `error` / `complete` (Subject semantics) plus an
|
|
201
|
-
* `AsyncIterable` view. Two consumption modes that fan out from the same source:
|
|
202
|
-
*
|
|
203
|
-
* - `for await (const v of subject)` — iteration. Each `[Symbol.asyncIterator]()` call returns
|
|
204
|
-
* a fresh per-iterator queue. Stop by `break`ing the loop. On `.error(err)` the iterator's
|
|
205
|
-
* pending `next()` rejects, propagating into the for-await as a thrown exception.
|
|
206
|
-
*
|
|
207
|
-
* - `subject.subscribe(observerOrNext)` — observer style. Pass either a full/partial observer
|
|
208
|
-
* `{ next?, error?, complete? }` or just an `(value) => …` function as the `next`-only shortcut.
|
|
209
|
-
* Returns an unsubscribe function. Missing handlers default to no-ops.
|
|
210
|
-
*
|
|
211
|
-
* Producer side: call `.next(value)` to emit, `.error(err)` to fail the subject (all consumers
|
|
212
|
-
* see the error and are detached), `.complete()` to close cleanly (all consumers see done and
|
|
213
|
-
* are detached). After either `error` or `complete`, further `.next()` calls are dropped and
|
|
214
|
-
* new `.subscribe(...)` calls register a no-op unsubscribe.
|
|
215
|
-
*
|
|
216
|
-
* Backpressure: unbounded queue per pending iterator. Intended for low-frequency events.
|
|
217
|
-
*/
|
|
218
|
-
type AsyncIterableSubject<T> = AsyncIterable<T> & {
|
|
219
|
-
next: (value: T) => void;
|
|
220
|
-
error: (err: unknown) => void;
|
|
221
|
-
complete: () => void;
|
|
222
|
-
subscribe: (observerOrNext: ((value: T) => void) | {
|
|
223
|
-
next?: (value: T) => void;
|
|
224
|
-
error?: (err: unknown) => void;
|
|
225
|
-
complete?: () => void;
|
|
226
|
-
}) => () => void;
|
|
227
|
-
};
|
|
228
|
-
declare function createAsyncIterableSubject<T>(): AsyncIterableSubject<T>;
|
|
229
|
-
//#endregion
|
|
230
|
-
export { type AsyncIterableSubject, type ConnectionContext, type ConnectionEvents, ContelloClient, type ContelloClientOptions, type DownloadResult, type HttpAgentOptions, type LocalDate, type LocalDateTime, type OperationDef, type OperationKind, type OperationMap, type ProxyResult, type Rpc, type Schema, type SourceAccessors, type SourceCardinality, type SourceDef, type SourceMap, type UploadData, type UploadMetadata, type UploadOptions, asyncKeepalive, collectAsync, createAsyncIterableSubject, createContelloClient, createSourceSubscription, exponentialBackoff, filterAsync, firstAsync, mapAsync, runWithBackoff };
|
|
166
|
+
export { type ConnectionContext, type ConnectionEvents, ContelloClient, type ContelloClientOptions, type DownloadResult, type HttpAgentOptions, type LocalDate, type LocalDateTime, type OperationDef, type OperationKind, type OperationMap, type ProxyResult, type Rpc, type Schema, type SourceAccessors, type SourceCardinality, type SourceDef, type SourceMap, type UploadData, type UploadMetadata, type UploadOptions, createContelloClient, createSourceSubscription };
|
|
231
167
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/http.ts","../src/types.ts","../src/upload.ts","../src/client.ts","../src/scalars.ts","../src/source-subscription.ts"
|
|
1
|
+
{"version":3,"file":"index.d.ts","names":[],"sources":["../src/http.ts","../src/types.ts","../src/upload.ts","../src/client.ts","../src/scalars.ts","../src/source-subscription.ts"],"mappings":";;;;KAiCY,gBAAA;EACV,UAAA;EACA,OAAA;EACA,oBAAA;EACA,gBAAA;AAAA;AAAA,KAcU,cAAA;EACV,QAAA;EACA,IAAA;EACA,KAAA,IAAS,OAAA,CAAQ,UAAA;EACjB,MAAA,IAAU,cAAA,CAAe,UAAA;AAAA;AAAA,KAiCf,WAAA;EACV,MAAA;EACA,OAAA,EAAS,OAAA;EACT,MAAA,IAAU,cAAA,CAAe,UAAA;AAAA;;;KC3Ff,aAAA;AAAA,KAEA,YAAA,iCAEG,MAAA,iCACC,aAAA,GAAgB,aAAA;EAE9B,QAAA;EACA,IAAA,EAAM,KAAA,EDyBI;ECvBV,QAAA,GAAW,OAAA;EAEX,WAAA,GAAc,UAAA;AAAA;AAAA,KAGJ,YAAA,GAAe,MAAM,SAAS,YAAA;AAAA,KAE9B,WAAA,WAAsB,YAAA,IAAgB,WAAA,CAAY,CAAA;AAAA,KAClD,cAAA,WAAyB,YAAA,IAAgB,WAAA,CAAY,CAAA;AAAA,KAErD,SAAA,WAAoB,YAAA,IAAgB,CAAA,kCAC5C,cAAA,CAAe,CAAA,UAAW,MAAA,wBAClB,aAAA,CAAc,WAAA,CAAY,CAAA,MAC/B,SAAA,EAAW,cAAA,CAAe,CAAA,MAAO,aAAA,CAAc,WAAA,CAAY,CAAA,KAC9D,cAA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