@laserdata/laser-sdk 0.4.1 → 0.5.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.
Files changed (87) hide show
  1. package/README.md +42 -2
  2. package/dist/agent/reliable-consumer.d.ts.map +1 -1
  3. package/dist/agent/reliable-consumer.js +5 -1
  4. package/dist/agent/reliable-consumer.js.map +1 -1
  5. package/dist/bridges/a2a.d.ts +1 -1
  6. package/dist/bridges/a2a.js +1 -1
  7. package/dist/client/capabilities.d.ts +15 -2
  8. package/dist/client/capabilities.d.ts.map +1 -1
  9. package/dist/client/capabilities.js +22 -1
  10. package/dist/client/capabilities.js.map +1 -1
  11. package/dist/client/errors.d.ts +23 -1
  12. package/dist/client/errors.d.ts.map +1 -1
  13. package/dist/client/errors.js +34 -0
  14. package/dist/client/errors.js.map +1 -1
  15. package/dist/client/laser.d.ts +6 -0
  16. package/dist/client/laser.d.ts.map +1 -1
  17. package/dist/client/laser.js +25 -0
  18. package/dist/client/laser.js.map +1 -1
  19. package/dist/client/managed.d.ts +1 -0
  20. package/dist/client/managed.d.ts.map +1 -1
  21. package/dist/client/managed.js +15 -2
  22. package/dist/client/managed.js.map +1 -1
  23. package/dist/iggy/apache-iggy.d.ts +63 -2
  24. package/dist/iggy/apache-iggy.d.ts.map +1 -1
  25. package/dist/iggy/apache-iggy.js +343 -14
  26. package/dist/iggy/apache-iggy.js.map +1 -1
  27. package/dist/index.d.ts +8 -2
  28. package/dist/index.d.ts.map +1 -1
  29. package/dist/index.js +4 -1
  30. package/dist/index.js.map +1 -1
  31. package/dist/managed/filters.d.ts +358 -0
  32. package/dist/managed/filters.d.ts.map +1 -0
  33. package/dist/managed/filters.js +1913 -0
  34. package/dist/managed/filters.js.map +1 -0
  35. package/dist/stream/consumer.d.ts +11 -1
  36. package/dist/stream/consumer.d.ts.map +1 -1
  37. package/dist/stream/consumer.js +82 -9
  38. package/dist/stream/consumer.js.map +1 -1
  39. package/dist/stream/topic.d.ts +2 -0
  40. package/dist/stream/topic.d.ts.map +1 -1
  41. package/dist/stream/topic.js +6 -0
  42. package/dist/stream/topic.js.map +1 -1
  43. package/dist/wire/authz.d.ts +1 -1
  44. package/dist/wire/authz.d.ts.map +1 -1
  45. package/dist/wire/authz.js +12 -3
  46. package/dist/wire/authz.js.map +1 -1
  47. package/dist/wire/codes.d.ts +17 -0
  48. package/dist/wire/codes.d.ts.map +1 -1
  49. package/dist/wire/codes.js +17 -0
  50. package/dist/wire/codes.js.map +1 -1
  51. package/dist/wire/commands.d.ts +12 -1
  52. package/dist/wire/commands.d.ts.map +1 -1
  53. package/dist/wire/commands.js +13 -1
  54. package/dist/wire/commands.js.map +1 -1
  55. package/dist/wire/control.d.ts +4 -0
  56. package/dist/wire/control.d.ts.map +1 -1
  57. package/dist/wire/control.js +5 -0
  58. package/dist/wire/control.js.map +1 -1
  59. package/dist/wire/filter-codecs.d.ts +16 -0
  60. package/dist/wire/filter-codecs.d.ts.map +1 -0
  61. package/dist/wire/filter-codecs.js +519 -0
  62. package/dist/wire/filter-codecs.js.map +1 -0
  63. package/dist/wire/filter-eval.d.ts +75 -0
  64. package/dist/wire/filter-eval.d.ts.map +1 -0
  65. package/dist/wire/filter-eval.js +899 -0
  66. package/dist/wire/filter-eval.js.map +1 -0
  67. package/dist/wire/filter.d.ts +772 -0
  68. package/dist/wire/filter.d.ts.map +1 -0
  69. package/dist/wire/filter.js +2869 -0
  70. package/dist/wire/filter.js.map +1 -0
  71. package/dist/wire/hello.d.ts +18 -0
  72. package/dist/wire/hello.d.ts.map +1 -1
  73. package/dist/wire/hello.js +29 -3
  74. package/dist/wire/hello.js.map +1 -1
  75. package/dist/wire/http.d.ts +22 -0
  76. package/dist/wire/http.d.ts.map +1 -1
  77. package/dist/wire/http.js +54 -47
  78. package/dist/wire/http.js.map +1 -1
  79. package/dist/wire/limits.d.ts +25 -0
  80. package/dist/wire/limits.d.ts.map +1 -1
  81. package/dist/wire/limits.js +25 -0
  82. package/dist/wire/limits.js.map +1 -1
  83. package/dist/wire/result.d.ts +4 -0
  84. package/dist/wire/result.d.ts.map +1 -1
  85. package/dist/wire/result.js +50 -0
  86. package/dist/wire/result.js.map +1 -1
  87. package/package.json +1 -1
@@ -0,0 +1,358 @@
1
+ import type { Capabilities } from "../client/capabilities.js";
2
+ import { type CoordinatorConnection, type IggyHeaderValue, type LaserTransport } from "../iggy/apache-iggy.js";
3
+ import { CompiledFilter } from "../wire/filter-eval.js";
4
+ import { type AppliedPolicy, type ConsumerFilter, type FilterBinding, type FilterBindingPage, type FilterDetail, type FilterGroupRef, type FilterHeader, type FilterMutation, type FilterMutationOutcome, type FilterMutationResult, type FilterPage, type FilterPreview, type FilterRef, type FilterRevisionPage, type FilterRevisionRef, type FilterSource, type FilterState, type FilterTestResult, type FilterValidation, type FilteredPollRequest, type FilteredStart, type ReadMode, type SourceGeneration, type StopReason } from "../wire/filter.js";
5
+ /** How long the typed catalog verbs wait for a mutation's authoritative outcome. */
6
+ export declare const DEFAULT_OUTCOME_WAIT_MS = 30000;
7
+ /**
8
+ * Marks a page or record with the reader that read it, so an acknowledgment
9
+ * can tell its own records from another reader's. A spread copy keeps it.
10
+ */
11
+ export declare const READER_TAG: unique symbol;
12
+ /** The reader membership and read sequence behind one page or record. */
13
+ export interface ReaderTag {
14
+ readonly owner: object;
15
+ readonly sequence: number;
16
+ }
17
+ /** The transport a filters handle needs. */
18
+ export type FilterTransport = Pick<LaserTransport, "sendManaged" | "getTopicPartitionCount" | "joinConsumerGroup" | "leaveConsumerGroup" | "joinExistingConsumerGroup" | "openNodeConnection" | "openCoordinator" | "connectsNodes"> & Partial<Pick<LaserTransport, "ensureConsumerGroup">>;
19
+ /** One page of matching records from one partition. */
20
+ export interface MatchedPage {
21
+ readonly partitionId: number;
22
+ readonly records: readonly MatchedRecord[];
23
+ /** The filter the server executed. */
24
+ readonly policy: AppliedPolicy;
25
+ /** The source history the page was read from. */
26
+ readonly generation: SourceGeneration;
27
+ readonly stop: StopReason;
28
+ readonly examined: number;
29
+ /** The partition head when the page was read. Reported, not progress. */
30
+ readonly frontier: bigint;
31
+ /**
32
+ * The offset acknowledging this page stores, once every earlier page is
33
+ * handled too. Absent on a local page, which cannot be acknowledged.
34
+ */
35
+ readonly safeAckOffset?: bigint;
36
+ readonly [READER_TAG]?: ReaderTag;
37
+ }
38
+ /** One matching record, unchanged from the stream. Acknowledge the original reader-owned object. Cloning payload data does not transfer acknowledgment ownership. */
39
+ export interface MatchedRecord {
40
+ readonly headersMalformed?: boolean;
41
+ /** Decode a JSON payload. Other codecs keep their original encoded bytes. */
42
+ json(): unknown;
43
+ readonly partitionId: number;
44
+ readonly offset: bigint;
45
+ /** The partition head when the record was read. */
46
+ readonly frontier: bigint;
47
+ /** `false` when the filter could not evaluate the record and a `pass` fault, foreign-record, or mismatch policy returned it unevaluated. */
48
+ readonly evaluated: boolean;
49
+ readonly payload: Uint8Array;
50
+ readonly headers: ReadonlyMap<string, IggyHeaderValue>;
51
+ /** The record's batch timestamp in whole microseconds, as stored. */
52
+ readonly timestampMicros?: bigint;
53
+ readonly [READER_TAG]?: ReaderTag;
54
+ }
55
+ export interface FilterPreviewOptions {
56
+ readonly fromOffset?: bigint;
57
+ readonly maxExamined?: number;
58
+ readonly maxRecords?: number;
59
+ readonly explain?: boolean;
60
+ }
61
+ export interface FilterListOptions {
62
+ readonly nameContains?: string;
63
+ readonly state?: FilterState;
64
+ /** Only filters with a lower id. Pass the last id of a page, with page 0, to page stably. */
65
+ readonly beforeId?: number;
66
+ readonly page?: number;
67
+ readonly pageSize?: number;
68
+ }
69
+ export interface CatalogPageOptions {
70
+ readonly page?: number;
71
+ readonly pageSize?: number;
72
+ }
73
+ /**
74
+ * Server-side consumer filters: filtered readers, previews, sample tests, and
75
+ * the saved-filter catalog. Build it with `Laser.filters()`. Native reads need
76
+ * a server that serves consumer filters. The catalog also needs a managed
77
+ * plane. Either missing throws `UnsupportedError`.
78
+ */
79
+ export declare class Filters {
80
+ private readonly transport;
81
+ private readonly capabilities;
82
+ constructor(transport: FilterTransport, capabilities: () => Promise<Capabilities>);
83
+ /** A filtered reader over `stream` / `topic`. */
84
+ reader(stream: string, topic: string): FilteredReaderBuilder;
85
+ /** Validate and compile `filter` on the server without running it. */
86
+ validate(filter: ConsumerFilter): Promise<FilterValidation>;
87
+ /** Evaluate a filter against one supplied record and explain the verdict. */
88
+ test(filter: FilterRef, payload: Uint8Array | string, headers?: readonly FilterHeader[]): Promise<FilterTestResult>;
89
+ /** Preview a filter over stored records of one partition. It joins no group and stores no offset. */
90
+ preview(stream: string, topic: string, partitionId: number, filter: FilterRef, options?: FilterPreviewOptions): Promise<FilterPreview>;
91
+ /** One saved filter with its latest revision and bindings. */
92
+ get(filterId: number): Promise<FilterDetail>;
93
+ /** One page of saved filters, newest first. */
94
+ list(options?: FilterListOptions): Promise<FilterPage>;
95
+ /** One page of a filter's revisions, newest first. */
96
+ revisions(filterId: number, options?: CatalogPageOptions): Promise<FilterRevisionPage>;
97
+ /** The binding of one consumer group. Throws with reason `not_found` when it is unbound. */
98
+ binding(group: FilterGroupRef): Promise<FilterBinding>;
99
+ /** One page of bindings, optionally narrowed to one filter, one stream, or one stream and topic. */
100
+ bindings(options?: CatalogPageOptions & {
101
+ readonly filterId?: number;
102
+ readonly stream?: string;
103
+ readonly topic?: string;
104
+ }): Promise<FilterBindingPage>;
105
+ /** The recorded outcome of a mutation. Throws with reason `not_found` until the catalog applies it. */
106
+ operation(operationId: bigint): Promise<FilterMutationOutcome>;
107
+ /** Save a new filter as revision 1. */
108
+ register(name: string, filter: ConsumerFilter, options?: {
109
+ readonly description?: string;
110
+ }): Promise<FilterRevisionRef>;
111
+ /** Add a revision. `expectedRevision` must still be the latest one. */
112
+ revise(filterId: number, expectedRevision: number, filter: ConsumerFilter): Promise<FilterRevisionRef>;
113
+ /** Replace a filter's description. */
114
+ describe(filterId: number, description: string): Promise<void>;
115
+ /** Hide a filter from new bindings. Existing bindings keep executing. */
116
+ archive(filterId: number): Promise<void>;
117
+ /** Delete a filter. Throws with reason `conflict` while a consumer group is bound to it. */
118
+ delete(filterId: number): Promise<void>;
119
+ /** Pin an existing consumer group to one revision. */
120
+ bind(group: FilterGroupRef, filterId: number, revision: number): Promise<FilterBinding>;
121
+ /** Release a consumer group while it is still bound to `expectedDigest`. */
122
+ unbind(group: FilterGroupRef, expectedDigest: Uint8Array): Promise<FilterBinding>;
123
+ /** Release this exact saved binding, even after its group name was reused. */
124
+ unbindBinding(binding: FilterBinding): Promise<FilterBinding>;
125
+ /**
126
+ * Submit a mutation under a new operation id and wait for its authoritative
127
+ * outcome. A lost reply is retried under the same id, which the catalog
128
+ * answers with the first attempt's outcome. A rejection throws
129
+ * `FilterExecutionError`. An outcome still pending after
130
+ * {@link DEFAULT_OUTCOME_WAIT_MS} throws `AmbiguousMutationError` naming the
131
+ * operation id.
132
+ */
133
+ apply(mutation: FilterMutation): Promise<FilterMutationResult>;
134
+ /**
135
+ * {@link Filters.apply} under a caller-chosen `operationId`, so a caller that
136
+ * records the id first can resume the same mutation after a crash.
137
+ */
138
+ applyAs(operationId: bigint, mutation: FilterMutation): Promise<FilterMutationResult>;
139
+ /** Create the group if absent, then bind it. A failed bind can leave an unbound group. */
140
+ createConsumerGroup(group: FilterGroupRef, filterId: number, revision: number): Promise<FilterBinding>;
141
+ /** Pause or resume a revision without changing its executable content or digest. */
142
+ setRevisionEnabled(filterId: number, revision: number, enabled: boolean): Promise<void>;
143
+ /** Send one mutation under a caller-chosen `operationId`. The outcome may be pending. */
144
+ mutate(operationId: bigint, mutation: FilterMutation): Promise<FilterMutationOutcome>;
145
+ /** Wait for the outcome of `operationId` for at most `timeoutMs`. */
146
+ waitForOutcome(operationId: bigint, timeoutMs: number): Promise<FilterMutationResult>;
147
+ private submit;
148
+ private native;
149
+ private catalog;
150
+ }
151
+ /** Builds a {@link FilteredReader}. Start from `Filters.reader`. */
152
+ export declare class FilteredReaderBuilder {
153
+ private readonly transport;
154
+ private readonly capabilities;
155
+ private readonly filters;
156
+ private readonly source;
157
+ private consumerName?;
158
+ private readonly partitionIds;
159
+ private filterRef?;
160
+ private startAt;
161
+ private pageCount;
162
+ private replyBytes;
163
+ private mode;
164
+ private guarded;
165
+ private idleMs;
166
+ private maxUnacked;
167
+ constructor(transport: FilterTransport, capabilities: () => Promise<Capabilities>, filters: Filters, source: FilterSource);
168
+ /** Read as the independent consumer `name`. */
169
+ consumer(name: string): this;
170
+ /**
171
+ * Read as a member of the existing consumer group `name`. A reader built
172
+ * from a connection string joins over its own connection, so every reader
173
+ * is its own member.
174
+ */
175
+ group(name: string): this;
176
+ /** Read the existing group by its native numeric identity. */
177
+ groupId(id: bigint | number): this;
178
+ /**
179
+ * Read only `partitionId`. Repeat for more. An independent consumer reads
180
+ * every partition when none is named, including partitions added later.
181
+ */
182
+ partition(partitionId: number): this;
183
+ /** Which filter runs. A group defaults to its bound revision. */
184
+ filter(filter: FilterRef): this;
185
+ /** Run `filter` from the request. Needs no catalog. */
186
+ inline(filter: ConsumerFilter): this;
187
+ /** Run a saved revision. */
188
+ revision(filterId: number, revision: number): this;
189
+ /**
190
+ * Where each partition read at the build starts. Defaults to after the
191
+ * stored offset. A partition a group hands this reader later always resumes
192
+ * after the group's stored offset, so the previous owner's unacknowledged
193
+ * backlog is read, not skipped.
194
+ */
195
+ start(start: FilteredStart): this;
196
+ /** Most matching records per page. */
197
+ count(count: number): this;
198
+ /** Most record bytes per page. The server may lower it. */
199
+ maxReplyBytes(bytes: number): this;
200
+ /**
201
+ * `primary` (the default) reads from each partition primary and can
202
+ * acknowledge, and needs a Laser connected from a connection string.
203
+ * `local` reads any replica, cannot acknowledge, and keeps no pending pages.
204
+ */
205
+ readMode(mode: ReadMode): this;
206
+ /** Re-evaluate returned records and fail on disagreement. Regex predicates cannot use this guard. */
207
+ localGuard(enabled: boolean): this;
208
+ /**
209
+ * How long `nextPage` waits after a round that found nothing new, and how
210
+ * long a failing or blocked partition waits before it is read again.
211
+ */
212
+ idleInterval(milliseconds: number): this;
213
+ /** Most outstanding record-bearing pages per partition. Defaults to 1024. */
214
+ maxUnackedPages(pages: number): this;
215
+ build(): Promise<FilteredReader>;
216
+ }
217
+ type SourceIncarnation = Pick<SourceGeneration, "streamId" | "streamCreatedAtMicros" | "topicId" | "topicCreatedAtMicros">;
218
+ /** What a filtered reader is built from. Builders assemble it, tests may construct it directly. */
219
+ interface ReaderSettings {
220
+ readonly pinnedSource?: SourceIncarnation;
221
+ readonly transport: FilterTransport;
222
+ readonly filters: Filters;
223
+ readonly coordinator: CoordinatorConnection;
224
+ readonly request: FilteredPollRequest;
225
+ readonly inlineDigest: Uint8Array | undefined;
226
+ readonly start: FilteredStart;
227
+ readonly idleIntervalMs: number;
228
+ readonly maxUnackedPages?: number;
229
+ readonly guard: CompiledFilter | undefined;
230
+ readonly guardEnabled?: boolean;
231
+ readonly membership: Membership | undefined;
232
+ readonly discovers: boolean;
233
+ readonly partitionIds: readonly number[];
234
+ }
235
+ /**
236
+ * Reads only the records a consumer filter selects, with their original
237
+ * offsets, and stores progress through fenced acknowledgments. Pages are read
238
+ * ahead of acknowledgments, and a page's safe offset is stored only after it
239
+ * and every earlier page of the partition are fully handled. Pages that
240
+ * matched nothing are stored by the reader itself. A partition that fails,
241
+ * faults, or blocks waits one idle interval before it is read again, while
242
+ * the others keep reading. A purge or a new group binding restarts the
243
+ * partition from its stored offset once, and the error that reports it
244
+ * reaches the caller. Drive one reader from one task at a time.
245
+ */
246
+ export declare class FilteredReader implements AsyncDisposable, AsyncIterable<MatchedRecord> {
247
+ private readonly settings;
248
+ private readonly progress;
249
+ private readonly revoked;
250
+ private readonly routes;
251
+ private readonly buffered;
252
+ private guard;
253
+ private cursor;
254
+ private examined;
255
+ private sequence;
256
+ private owner;
257
+ private readonly retiredOwners;
258
+ private listedAt;
259
+ private closed;
260
+ private deferredError;
261
+ private pinnedSource;
262
+ private readonly lostRoutes;
263
+ constructor(settings: ReaderSettings);
264
+ /** The next page with at least one match. Waits while nothing is new, up to `timeoutMs` when given. */
265
+ nextPage(options?: {
266
+ readonly timeoutMs?: number;
267
+ }): Promise<MatchedPage>;
268
+ /**
269
+ * Read each partition in turn until a page matches or every partition has
270
+ * nothing new, without the idle wait. `undefined` when nothing is new.
271
+ */
272
+ tryNextPage(): Promise<MatchedPage | undefined>;
273
+ /** One bounded round without an idle wait. The flag means unmatched work remains. */
274
+ readRound(): Promise<readonly [MatchedPage | undefined, boolean]>;
275
+ /** Source records examined in the last bounded round, including empty pages. */
276
+ examinedInRound(): number;
277
+ /** The next matching record, one at a time over `nextPage`. */
278
+ nextRecord(options?: {
279
+ readonly timeoutMs?: number;
280
+ }): Promise<MatchedRecord>;
281
+ /** Mark one record handled, and store the progress this completes. */
282
+ ack(record: MatchedRecord): Promise<void>;
283
+ /** Mark this partition's preceding records through `record` handled. Later records stay pending. */
284
+ ackThrough(record: MatchedRecord): Promise<void>;
285
+ /** Mark every record of `page` handled, and store the progress this completes. */
286
+ ackPage(page: MatchedPage): Promise<void>;
287
+ /** The partitions this reader reads now. */
288
+ partitions(): readonly number[];
289
+ /** How long this reader waits, in milliseconds, when nothing is new. */
290
+ idleIntervalMs(): number;
291
+ /**
292
+ * Whether `value` was read by this reader in its current membership, so it
293
+ * can still be acknowledged. A rejoin retires every earlier page.
294
+ */
295
+ owns(value: MatchedPage | MatchedRecord): boolean;
296
+ /**
297
+ * Data connections this reader opened to partition primaries. A healthy
298
+ * reader opens one per node and keeps it: the count grows only when a node
299
+ * stops being primary, a connection fails, or the group session ends.
300
+ */
301
+ dataConnectionsOpened(): number;
302
+ /**
303
+ * Store completed progress, leave the group, and close the data
304
+ * connections. A round still running stops at its next step and opens
305
+ * nothing new.
306
+ */
307
+ close(): Promise<void>;
308
+ [Symbol.asyncDispose](): Promise<void>;
309
+ [Symbol.asyncIterator](): AsyncIterator<MatchedRecord>;
310
+ private round;
311
+ private read;
312
+ private restartAfter;
313
+ private flush;
314
+ private exchange;
315
+ private refreshMembership;
316
+ private refreshPartitions;
317
+ private retire;
318
+ private partitionProgress;
319
+ private requireSequence;
320
+ private sequenceOf;
321
+ private requireOpen;
322
+ private requireAcknowledgments;
323
+ }
324
+ /** This reader's membership of a consumer group, held by its coordinator connection. */
325
+ declare class Membership {
326
+ private readonly coordinator;
327
+ private readonly source;
328
+ private readonly group;
329
+ private readonly transport;
330
+ private readonly pinnedSource;
331
+ private sourceReplaced;
332
+ private generation;
333
+ private assigned;
334
+ private syncedAt;
335
+ private rejoined;
336
+ private readonly request;
337
+ private constructor();
338
+ static join(coordinator: CoordinatorConnection, source: FilterSource, group: string | number, transport: FilterTransport, pinnedSource: SourceIncarnation | undefined): Promise<Membership>;
339
+ get partitions(): readonly number[];
340
+ isDue(): boolean;
341
+ expire(): void;
342
+ /** Read the current assignment. `true` when it changed. */
343
+ sync(): Promise<boolean>;
344
+ takeRejoined(): boolean;
345
+ leave(): Promise<void>;
346
+ }
347
+ /**
348
+ * What a fresh route means for the data connection already open to its node.
349
+ *
350
+ * A connection stays open for the life of its session. The first 24 bytes
351
+ * name the session, its client id and number. The metadata watermark after
352
+ * them grows with every write the coordinator commits, and that alone never
353
+ * justifies a new connection: the attachment is sent again on the open one,
354
+ * which only raises its read-your-writes floor.
355
+ */
356
+ export declare function sessionReuse(open: Uint8Array, routed: Uint8Array): "keep" | "raise" | "replace";
357
+ export {};
358
+ //# sourceMappingURL=filters.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"filters.d.ts","sourceRoot":"","sources":["../../src/managed/filters.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAA;AAe7D,OAAO,EACL,KAAK,qBAAqB,EAE1B,KAAK,eAAe,EACpB,KAAK,cAAc,EAKpB,MAAM,wBAAwB,CAAA;AAoB/B,OAAO,EAAE,cAAc,EAAgC,MAAM,wBAAwB,CAAA;AACrF,OAAO,EACL,KAAK,aAAa,EAClB,KAAK,cAAc,EAEnB,KAAK,aAAa,EAClB,KAAK,iBA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