@fluidframework/runtime-definitions 2.0.0-rc.1.0.3 → 2.0.0-rc.2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. package/.eslintrc.cjs +1 -1
  2. package/CHANGELOG.md +75 -0
  3. package/api-extractor-cjs.json +8 -0
  4. package/api-extractor-lint.json +1 -1
  5. package/api-extractor.json +1 -1
  6. package/api-report/runtime-definitions.api.md +103 -112
  7. package/dist/dataStoreContext.d.ts +124 -62
  8. package/dist/dataStoreContext.d.ts.map +1 -1
  9. package/dist/dataStoreContext.js +3 -0
  10. package/dist/dataStoreContext.js.map +1 -1
  11. package/dist/dataStoreFactory.d.ts +1 -1
  12. package/dist/dataStoreFactory.d.ts.map +1 -1
  13. package/dist/dataStoreFactory.js.map +1 -1
  14. package/dist/dataStoreRegistry.d.ts +1 -1
  15. package/dist/dataStoreRegistry.d.ts.map +1 -1
  16. package/dist/dataStoreRegistry.js.map +1 -1
  17. package/dist/{garbageCollection.d.ts → garbageCollectionDefinitions.d.ts} +8 -2
  18. package/dist/garbageCollectionDefinitions.d.ts.map +1 -0
  19. package/dist/{garbageCollection.js → garbageCollectionDefinitions.js} +9 -3
  20. package/dist/garbageCollectionDefinitions.js.map +1 -0
  21. package/dist/index.d.ts +12 -52
  22. package/dist/index.d.ts.map +1 -1
  23. package/dist/index.js +20 -26
  24. package/dist/index.js.map +1 -1
  25. package/dist/package.json +3 -0
  26. package/dist/protocol.d.ts +2 -1
  27. package/dist/protocol.d.ts.map +1 -1
  28. package/dist/protocol.js.map +1 -1
  29. package/dist/runtime-definitions-alpha.d.ts +193 -166
  30. package/dist/runtime-definitions-beta.d.ts +37 -57
  31. package/dist/runtime-definitions-public.d.ts +37 -57
  32. package/dist/runtime-definitions-untrimmed.d.ts +200 -167
  33. package/dist/summary.d.ts +15 -20
  34. package/dist/summary.d.ts.map +1 -1
  35. package/dist/summary.js.map +1 -1
  36. package/dist/tsdoc-metadata.json +1 -1
  37. package/lib/attribution.d.ts +71 -0
  38. package/lib/attribution.d.ts.map +1 -0
  39. package/lib/attribution.js +6 -0
  40. package/lib/attribution.js.map +1 -0
  41. package/lib/dataStoreContext.d.ts +469 -0
  42. package/lib/dataStoreContext.d.ts.map +1 -0
  43. package/lib/dataStoreContext.js +67 -0
  44. package/lib/dataStoreContext.js.map +1 -0
  45. package/lib/dataStoreFactory.d.ts +33 -0
  46. package/lib/dataStoreFactory.d.ts.map +1 -0
  47. package/lib/dataStoreFactory.js +9 -0
  48. package/lib/dataStoreFactory.js.map +1 -0
  49. package/lib/dataStoreRegistry.d.ts +41 -0
  50. package/lib/dataStoreRegistry.d.ts.map +1 -0
  51. package/lib/dataStoreRegistry.js +9 -0
  52. package/lib/dataStoreRegistry.js.map +1 -0
  53. package/lib/garbageCollectionDefinitions.d.ts +62 -0
  54. package/lib/garbageCollectionDefinitions.d.ts.map +1 -0
  55. package/lib/garbageCollectionDefinitions.js +35 -0
  56. package/lib/garbageCollectionDefinitions.js.map +1 -0
  57. package/lib/index.d.ts +17 -0
  58. package/lib/index.d.ts.map +1 -0
  59. package/lib/index.js +10 -0
  60. package/lib/index.js.map +1 -0
  61. package/lib/protocol.d.ts +77 -0
  62. package/lib/protocol.d.ts.map +1 -0
  63. package/lib/protocol.js +6 -0
  64. package/lib/protocol.js.map +1 -0
  65. package/lib/runtime-definitions-alpha.d.ts +1025 -0
  66. package/lib/runtime-definitions-beta.d.ts +244 -0
  67. package/lib/runtime-definitions-public.d.ts +244 -0
  68. package/lib/runtime-definitions-untrimmed.d.ts +1106 -0
  69. package/lib/summary.d.ts +322 -0
  70. package/lib/summary.d.ts.map +1 -0
  71. package/lib/summary.js +26 -0
  72. package/lib/summary.js.map +1 -0
  73. package/package.json +111 -34
  74. package/src/dataStoreContext.ts +148 -77
  75. package/src/dataStoreFactory.ts +1 -1
  76. package/src/dataStoreRegistry.ts +1 -1
  77. package/src/{garbageCollection.ts → garbageCollectionDefinitions.ts} +7 -1
  78. package/src/index.ts +26 -70
  79. package/src/protocol.ts +2 -1
  80. package/src/summary.ts +18 -20
  81. package/tsconfig.cjs.json +7 -0
  82. package/tsconfig.json +2 -5
  83. package/dist/garbageCollection.d.ts.map +0 -1
  84. package/dist/garbageCollection.js.map +0 -1
@@ -2,16 +2,16 @@
2
2
  * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
3
3
  * Licensed under the MIT License.
4
4
  */
5
- import { IEvent, IEventProvider, ITelemetryBaseLogger, IDisposable, IProvideFluidHandleContext, IFluidHandle, IRequest, IResponse, FluidObject } from "@fluidframework/core-interfaces";
6
- import { IAudience, IDeltaManager, AttachState, ILoaderOptions } from "@fluidframework/container-definitions";
7
- import { IDocumentStorageService } from "@fluidframework/driver-definitions";
8
- import { IClientDetails, IDocumentMessage, IQuorumClients, ISequencedDocumentMessage, ISnapshotTree } from "@fluidframework/protocol-definitions";
9
- import { IIdCompressor } from "@fluidframework/id-compressor";
10
- import { IProvideFluidDataStoreFactory } from "./dataStoreFactory";
11
- import { IProvideFluidDataStoreRegistry } from "./dataStoreRegistry";
12
- import { IGarbageCollectionData, IGarbageCollectionDetailsBase } from "./garbageCollection";
13
- import { IInboundSignalMessage } from "./protocol";
14
- import { CreateChildSummarizerNodeParam, ISummarizerNodeWithGC, ISummaryTreeWithStats, ITelemetryContext, SummarizeInternalFn } from "./summary";
5
+ import type { IEvent, IEventProvider, ITelemetryBaseLogger, IDisposable, IProvideFluidHandleContext, IFluidHandle, IRequest, IResponse, FluidObject } from "@fluidframework/core-interfaces";
6
+ import type { IAudience, IDeltaManager, AttachState } from "@fluidframework/container-definitions";
7
+ import type { IDocumentStorageService } from "@fluidframework/driver-definitions";
8
+ import type { IClientDetails, IDocumentMessage, IQuorumClients, ISequencedDocumentMessage, ISnapshotTree } from "@fluidframework/protocol-definitions";
9
+ import type { IIdCompressor } from "@fluidframework/id-compressor";
10
+ import type { IProvideFluidDataStoreFactory } from "./dataStoreFactory.js";
11
+ import type { IProvideFluidDataStoreRegistry } from "./dataStoreRegistry.js";
12
+ import type { IGarbageCollectionData, IGarbageCollectionDetailsBase } from "./garbageCollectionDefinitions.js";
13
+ import type { IInboundSignalMessage } from "./protocol.js";
14
+ import type { CreateChildSummarizerNodeParam, ISummarizerNodeWithGC, ISummaryTreeWithStats, ITelemetryContext, SummarizeInternalFn } from "./summary.js";
15
15
  /**
16
16
  * Runtime flush mode handling
17
17
  * @alpha
@@ -19,6 +19,9 @@ import { CreateChildSummarizerNodeParam, ISummarizerNodeWithGC, ISummaryTreeWith
19
19
  export declare enum FlushMode {
20
20
  /**
21
21
  * In Immediate flush mode the runtime will immediately send all operations to the driver layer.
22
+ *
23
+ * @deprecated This option will be removed in the next major version and should not be used. Use {@link FlushMode.TurnBased} instead, which is the default.
24
+ * See https://github.com/microsoft/FluidFramework/tree/main/packages/runtime/container-runtime/src/opLifecycle#how-batching-works
22
25
  */
23
26
  Immediate = 0,
24
27
  /**
@@ -85,6 +88,7 @@ export interface IContainerRuntimeBaseEvents extends IEvent {
85
88
  (event: "op", listener: (op: ISequencedDocumentMessage, runtimeMessage?: boolean) => void): any;
86
89
  (event: "batchEnd", listener: (error: any, op: ISequencedDocumentMessage) => void): any;
87
90
  (event: "signal", listener: (message: IInboundSignalMessage, local: boolean) => void): any;
91
+ (event: "dispose", listener: () => void): any;
88
92
  }
89
93
  /**
90
94
  * Encapsulates the return codes of the aliasing API.
@@ -128,6 +132,7 @@ export interface IDataStore {
128
132
  export interface IContainerRuntimeBase extends IEventProvider<IContainerRuntimeBaseEvents> {
129
133
  readonly logger: ITelemetryBaseLogger;
130
134
  readonly clientDetails: IClientDetails;
135
+ readonly disposed: boolean;
131
136
  /**
132
137
  * Invokes the given callback and guarantees that all operations generated within the callback will be ordered
133
138
  * sequentially.
@@ -139,12 +144,13 @@ export interface IContainerRuntimeBase extends IEventProvider<IContainerRuntimeB
139
144
  * Submits a container runtime level signal to be sent to other clients.
140
145
  * @param type - Type of the signal.
141
146
  * @param content - Content of the signal.
147
+ * @param targetClientId - When specified, the signal is only sent to the provided client id.
142
148
  */
143
- submitSignal(type: string, content: any): void;
149
+ submitSignal(type: string, content: any, targetClientId?: string): void;
144
150
  /**
145
151
  * @deprecated 0.16 Issue #1537, #3631
146
152
  */
147
- _createDataStoreWithProps(pkg: string | string[], props?: any, id?: string): Promise<IDataStore>;
153
+ _createDataStoreWithProps(pkg: Readonly<string | string[]>, props?: any, id?: string): Promise<IDataStore>;
148
154
  /**
149
155
  * Creates a data store and returns an object that exposes a handle to the data store's entryPoint, and also serves
150
156
  * as the data store's router. The data store is not bound to a container, and in such state is not persisted to
@@ -152,13 +158,20 @@ export interface IContainerRuntimeBase extends IEventProvider<IContainerRuntimeB
152
158
  * already attached DDS (or non-attached DDS that will eventually get attached to storage) will result in this
153
159
  * store being attached to storage.
154
160
  * @param pkg - Package name of the data store factory
161
+ * @param loadingGroupId - This represents the group of the datastore within a container or its snapshot.
162
+ * When not specified the datastore will belong to a `default` group. Read more about it in this
163
+ * {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}
155
164
  */
156
- createDataStore(pkg: string | string[]): Promise<IDataStore>;
165
+ createDataStore(pkg: Readonly<string | string[]>, loadingGroupId?: string): Promise<IDataStore>;
157
166
  /**
158
167
  * Creates detached data store context. Only after context.attachRuntime() is called,
159
168
  * data store initialization is considered complete.
169
+ * @param pkg - Package name of the data store factory
170
+ * @param loadingGroupId - This represents the group of the datastore within a container or its snapshot.
171
+ * When not specified the datastore will belong to a `default` group. Read more about it in this
172
+ * {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}.
160
173
  */
161
- createDetachedDataStore(pkg: Readonly<string[]>): IFluidDataStoreContextDetached;
174
+ createDetachedDataStore(pkg: Readonly<string[]>, loadingGroupId?: string): IFluidDataStoreContextDetached;
162
175
  /**
163
176
  * Get an absolute url for a provided container-relative request.
164
177
  * Returns undefined if the container or data store isn't attached to storage.
@@ -174,6 +187,28 @@ export interface IContainerRuntimeBase extends IEventProvider<IContainerRuntimeB
174
187
  * Returns the current audience.
175
188
  */
176
189
  getAudience(): IAudience;
190
+ /**
191
+ * Generates a new ID that is guaranteed to be unique across all sessions for this container.
192
+ * It could be in compact form (non-negative integer, oppotunistic), but it could also be UUID string.
193
+ * UUIDs generated will have low entropy in groups and will compress well.
194
+ * It can be leveraged anywhere in container where container unique IDs are required, i.e. any place
195
+ * that uses uuid() and stores result in container is likely candidate to start leveraging this API.
196
+ * If you always want to convert to string, instead of doing String(generateDocumentUniqueId()), consider
197
+ * doing encodeCompactIdToString(generateDocumentUniqueId()).
198
+ *
199
+ * For more details, please see IIdCompressor.generateDocumentUniqueId()
200
+ */
201
+ generateDocumentUniqueId(): number | string;
202
+ /**
203
+ * Api to fetch the snapshot from the service for a loadingGroupIds.
204
+ * @param loadingGroupIds - LoadingGroupId for which the snapshot is asked for.
205
+ * @param pathParts - Parts of the path, which we want to extract from the snapshot tree.
206
+ * @returns - snapshotTree and the sequence number of the snapshot.
207
+ */
208
+ getSnapshotForLoadingGroupId(loadingGroupIds: string[], pathParts: string[]): Promise<{
209
+ snapshotTree: ISnapshotTree;
210
+ sequenceNumber: number;
211
+ }>;
177
212
  }
178
213
  /**
179
214
  * Minimal interface a data store runtime needs to provide for IFluidDataStoreContext to bind to control.
@@ -183,34 +218,27 @@ export interface IContainerRuntimeBase extends IEventProvider<IContainerRuntimeB
183
218
  * @alpha
184
219
  */
185
220
  export interface IFluidDataStoreChannel extends IDisposable {
186
- readonly id: string;
187
- /**
188
- * Indicates the attachment state of the channel to a host service.
189
- */
190
- readonly attachState: AttachState;
191
- readonly visibilityState: VisibilityState;
192
- /**
193
- * Runs through the graph and attaches the bound handles. Then binds this runtime to the container.
194
- * @deprecated This will be removed in favor of {@link IFluidDataStoreChannel.makeVisibleAndAttachGraph}.
195
- */
196
- attachGraph(): void;
197
221
  /**
198
222
  * Makes the data store channel visible in the container. Also, runs through its graph and attaches all
199
223
  * bound handles that represent its dependencies in the container's graph.
200
224
  */
201
225
  makeVisibleAndAttachGraph(): void;
202
226
  /**
203
- * Retrieves the summary used as part of the initial summary message
227
+ * Synchronously retrieves the summary used as part of the initial summary message
204
228
  */
205
229
  getAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;
230
+ /**
231
+ * Synchronously retrieves GC Data (representing the outbound routes present) for the initial state of the DataStore
232
+ */
233
+ getAttachGCData?(telemetryContext?: ITelemetryContext): IGarbageCollectionData;
206
234
  /**
207
235
  * Processes the op.
208
236
  */
209
- process(message: ISequencedDocumentMessage, local: boolean, localOpMetadata: unknown): void;
237
+ process(message: ISequencedDocumentMessage, local: boolean, localOpMetadata: unknown, addedOutboundReference?: (fromNodePath: string, toNodePath: string) => void): void;
210
238
  /**
211
239
  * Processes the signal.
212
240
  */
213
- processSignal(message: any, local: boolean): void;
241
+ processSignal(message: IInboundSignalMessage, local: boolean): void;
214
242
  /**
215
243
  * Generates a summary for the channel.
216
244
  * Introduced with summarizerNode - will be required in a future release.
@@ -274,47 +302,38 @@ export interface IFluidDataStoreContextEvents extends IEvent {
274
302
  (event: "attaching" | "attached", listener: () => void): any;
275
303
  }
276
304
  /**
277
- * Represents the context for the data store. It is used by the data store runtime to
278
- * get information and call functionality to the container.
305
+ * Represents the context for the data store like objects. It is used by the data store runtime to
306
+ * get information and call functionality to its parent.
307
+ *
308
+ * This layout is temporary, as {@link IFluidParentContext} and {@link IFluidDataStoreContext} will converge.
309
+ *
279
310
  * @alpha
280
311
  */
281
- export interface IFluidDataStoreContext extends IEventProvider<IFluidDataStoreContextEvents>, Partial<IProvideFluidDataStoreRegistry>, IProvideFluidHandleContext {
282
- readonly id: string;
283
- /**
284
- * A data store created by a client, is a local data store for that client. Also, when a detached container loads
285
- * from a snapshot, all the data stores are treated as local data stores because at that stage the container
286
- * still doesn't exists in storage and so the data store couldn't have been created by any other client.
287
- * Value of this never changes even after the data store is attached.
288
- * As implementer of data store runtime, you can use this property to check that this data store belongs to this
289
- * client and hence implement any scenario based on that.
290
- */
291
- readonly isLocalDataStore: boolean;
292
- /**
293
- * The package path of the data store as per the package factory.
294
- */
295
- readonly packagePath: readonly string[];
296
- readonly options: ILoaderOptions;
312
+ export interface IFluidParentContext extends IProvideFluidHandleContext, Partial<IProvideFluidDataStoreRegistry> {
313
+ readonly options: Record<string | number, any>;
297
314
  readonly clientId: string | undefined;
298
315
  readonly connected: boolean;
299
316
  readonly deltaManager: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>;
300
317
  readonly storage: IDocumentStorageService;
301
- readonly baseSnapshot: ISnapshotTree | undefined;
302
318
  readonly logger: ITelemetryBaseLogger;
303
319
  readonly clientDetails: IClientDetails;
304
320
  readonly idCompressor?: IIdCompressor;
321
+ /**
322
+ * Represents the loading group to which the data store belongs to. Please refer to this readme for more context.
323
+ * {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}
324
+ */
325
+ readonly loadingGroupId?: string;
305
326
  /**
306
327
  * Indicates the attachment state of the data store to a host service.
307
328
  */
308
329
  readonly attachState: AttachState;
309
330
  readonly containerRuntime: IContainerRuntimeBase;
310
- /**
311
- * @deprecated 0.16 Issue #1635, #3631
312
- */
313
- readonly createProps?: any;
314
331
  /**
315
332
  * Ambient services provided with the context
316
333
  */
317
334
  readonly scope: FluidObject;
335
+ readonly gcThrowOnTombstoneUsage: boolean;
336
+ readonly gcTombstoneEnforcementAllowed: boolean;
318
337
  /**
319
338
  * Returns the current quorum.
320
339
  */
@@ -353,11 +372,6 @@ export interface IFluidDataStoreContext extends IEventProvider<IFluidDataStoreCo
353
372
  * when they are marked as root. For non-root data stores, this happens when their handle is added to a visible DDS.
354
373
  */
355
374
  makeLocallyVisible(): void;
356
- /**
357
- * Call by IFluidDataStoreChannel, indicates that a channel is dirty and needs to be part of the summary.
358
- * @param address - The address of the channel that is dirty.
359
- */
360
- setChannelDirty(address: string): void;
361
375
  /**
362
376
  * Get an absolute url to the container based on the provided relativeUrl.
363
377
  * Returns undefined if the container or data store isn't attached to storage.
@@ -376,7 +390,55 @@ export interface IFluidDataStoreContext extends IEventProvider<IFluidDataStoreCo
376
390
  * If it is local, it will throw unsupported errors on calls to summarize.
377
391
  */
378
392
  createParam: CreateChildSummarizerNodeParam): CreateChildSummarizerNodeFn;
393
+ deleteChildSummarizerNode?(id: string): void;
379
394
  uploadBlob(blob: ArrayBufferLike, signal?: AbortSignal): Promise<IFluidHandle<ArrayBufferLike>>;
395
+ /**
396
+ * @deprecated There is no replacement for this, its functionality is no longer needed at this layer.
397
+ * It will be removed in a future release, sometime after 2.0.0-internal.8.0.0
398
+ *
399
+ * Similar capability is exposed with from/to string paths instead of handles via @see addedGCOutboundRoute
400
+ *
401
+ * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
402
+ * all references added in the system.
403
+ * @param srcHandle - The handle of the node that added the reference.
404
+ * @param outboundHandle - The handle of the outbound node that is referenced.
405
+ */
406
+ addedGCOutboundReference?(srcHandle: {
407
+ absolutePath: string;
408
+ }, outboundHandle: {
409
+ absolutePath: string;
410
+ }): void;
411
+ }
412
+ /**
413
+ * Represents the context for the data store. It is used by the data store runtime to
414
+ * get information and call functionality to the container.
415
+ * @alpha
416
+ */
417
+ export interface IFluidDataStoreContext extends IEventProvider<IFluidDataStoreContextEvents>, IFluidParentContext {
418
+ readonly id: string;
419
+ /**
420
+ * A data store created by a client, is a local data store for that client. Also, when a detached container loads
421
+ * from a snapshot, all the data stores are treated as local data stores because at that stage the container
422
+ * still doesn't exists in storage and so the data store couldn't have been created by any other client.
423
+ * Value of this never changes even after the data store is attached.
424
+ * As implementer of data store runtime, you can use this property to check that this data store belongs to this
425
+ * client and hence implement any scenario based on that.
426
+ */
427
+ readonly isLocalDataStore: boolean;
428
+ /**
429
+ * The package path of the data store as per the package factory.
430
+ */
431
+ readonly packagePath: readonly string[];
432
+ readonly baseSnapshot: ISnapshotTree | undefined;
433
+ /**
434
+ * @deprecated 0.16 Issue #1635, #3631
435
+ */
436
+ readonly createProps?: any;
437
+ /**
438
+ * Call by IFluidDataStoreChannel, indicates that a channel is dirty and needs to be part of the summary.
439
+ * @param address - The address of the channel that is dirty.
440
+ */
441
+ setChannelDirty(address: string): void;
380
442
  /**
381
443
  * @deprecated The functionality to get base GC details has been moved to summarizer node.
382
444
  *
@@ -385,15 +447,15 @@ export interface IFluidDataStoreContext extends IEventProvider<IFluidDataStoreCo
385
447
  */
386
448
  getBaseGCDetails(): Promise<IGarbageCollectionDetailsBase>;
387
449
  /**
388
- * @deprecated There is no replacement for this, its functionality is no longer needed at this layer.
389
- * It will be removed in a future release, sometime after 2.0.0-internal.8.0.0
450
+ * (Same as @see addedGCOutboundReference, but with string paths instead of handles)
390
451
  *
391
452
  * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
392
453
  * all references added in the system.
393
- * @param srcHandle - The handle of the node that added the reference.
394
- * @param outboundHandle - The handle of the outbound node that is referenced.
454
+ *
455
+ * @param fromPath - The absolute path of the node that added the reference.
456
+ * @param toPath - The absolute path of the outbound node that is referenced.
395
457
  */
396
- addedGCOutboundReference?(srcHandle: IFluidHandle, outboundHandle: IFluidHandle): void;
458
+ addedGCOutboundRoute?(fromPath: string, toPath: string): void;
397
459
  }
398
460
  /**
399
461
  * @alpha
@@ -402,6 +464,6 @@ export interface IFluidDataStoreContextDetached extends IFluidDataStoreContext {
402
464
  /**
403
465
  * Binds a runtime to the context.
404
466
  */
405
- attachRuntime(factory: IProvideFluidDataStoreFactory, dataStoreRuntime: IFluidDataStoreChannel): Promise<void>;
467
+ attachRuntime(factory: IProvideFluidDataStoreFactory, dataStoreRuntime: IFluidDataStoreChannel): Promise<IDataStore>;
406
468
  }
407
469
  //# sourceMappingURL=dataStoreContext.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"dataStoreContext.d.ts","sourceRoot":"","sources":["../src/dataStoreContext.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACN,MAAM,EACN,cAAc,EACd,oBA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,WAAW,CAAC,EAAE,GAAG,CAAC;IAE3B;;;OAGG;IACH,eAAe,CAAC,OAAO,EAAE,MAAM,GAAG,IAAI,CAAC;IAEvC;;;;;OAKG;IACH,gBAAgB,IAAI,OAAO,CAAC,6BAA6B,CAAC,CAAC;IAE3D;;;;;;;;OAQG;IACH,oBAAoB,CAAC,CAAC,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI,CAAC;CAC9D;AAED;;GAEG;AACH,MAAM,WAAW,8BAA+B,SAAQ,sBAAsB;IAC7E;;OAEG;IACH,aAAa,CACZ,OAAO,EAAE,6BAA6B,EACtC,gBAAgB,EAAE,sBAAsB,GACtC,OAAO,CAAC,UAAU,CAAC,CAAC;CACvB"}
@@ -13,6 +13,9 @@ var FlushMode;
13
13
  (function (FlushMode) {
14
14
  /**
15
15
  * In Immediate flush mode the runtime will immediately send all operations to the driver layer.
16
+ *
17
+ * @deprecated This option will be removed in the next major version and should not be used. Use {@link FlushMode.TurnBased} instead, which is the default.
18
+ * See https://github.com/microsoft/FluidFramework/tree/main/packages/runtime/container-runtime/src/opLifecycle#how-batching-works
16
19
  */
17
20
  FlushMode[FlushMode["Immediate"] = 0] = "Immediate";
18
21
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"dataStoreContext.js","sourceRoot":"","sources":["../src/dataStoreContext.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAwCH;;;GAGG;AACH,IAAY,SAWX;AAXD,WAAY,SAAS;IACpB;;OAEG;IACH,mDAAS,CAAA;IAET;;;OAGG;IACH,mDAAS,CAAA;AACV,CAAC,EAXW,SAAS,yBAAT,SAAS,QAWpB;AAED;;GAEG;AACH,IAAY,qBAWX;AAXD,WAAY,qBAAqB;IAChC;;;;;;;;OAQG;IACH,mEAAS,CAAA;AACV,CAAC,EAXW,qBAAqB,qCAArB,qBAAqB,QAWhC;AAED;;;;GAIG;AACU,QAAA,eAAe,GAAG;IAC9B;;OAEG;IACH,UAAU,EAAE,YAAY;IAExB;;;;OAIG;IACH,cAAc,EAAE,gBAAgB;IAEhC;;;;;;;;OAQG;IACH,eAAe,EAAE,iBAAiB;CAClC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport {\n\tIEvent,\n\tIEventProvider,\n\tITelemetryBaseLogger,\n\tIDisposable,\n\tIProvideFluidHandleContext,\n\tIFluidHandle,\n\tIRequest,\n\tIResponse,\n\tFluidObject,\n} from \"@fluidframework/core-interfaces\";\nimport {\n\tIAudience,\n\tIDeltaManager,\n\tAttachState,\n\tILoaderOptions,\n} from \"@fluidframework/container-definitions\";\nimport { IDocumentStorageService } from \"@fluidframework/driver-definitions\";\nimport {\n\tIClientDetails,\n\tIDocumentMessage,\n\tIQuorumClients,\n\tISequencedDocumentMessage,\n\tISnapshotTree,\n} from \"@fluidframework/protocol-definitions\";\nimport { IIdCompressor } from \"@fluidframework/id-compressor\";\nimport { IProvideFluidDataStoreFactory } from \"./dataStoreFactory\";\nimport { IProvideFluidDataStoreRegistry } from \"./dataStoreRegistry\";\nimport { IGarbageCollectionData, IGarbageCollectionDetailsBase } from \"./garbageCollection\";\nimport { IInboundSignalMessage } from \"./protocol\";\nimport {\n\tCreateChildSummarizerNodeParam,\n\tISummarizerNodeWithGC,\n\tISummaryTreeWithStats,\n\tITelemetryContext,\n\tSummarizeInternalFn,\n} from \"./summary\";\n\n/**\n * Runtime flush mode handling\n * @alpha\n */\nexport enum FlushMode {\n\t/**\n\t * In Immediate flush mode the runtime will immediately send all operations to the driver layer.\n\t */\n\tImmediate,\n\n\t/**\n\t * When in TurnBased flush mode the runtime will buffer operations in the current turn and send them as a single\n\t * batch at the end of the turn. The flush call on the runtime can be used to force send the current batch.\n\t */\n\tTurnBased,\n}\n\n/**\n * @internal\n */\nexport enum FlushModeExperimental {\n\t/**\n\t * When in Async flush mode, the runtime will accumulate all operations across JS turns and send them as a single\n\t * batch when all micro-tasks are complete.\n\t *\n\t * This feature requires a version of the loader which supports reference sequence numbers. If an older version of\n\t * the loader is used, the runtime will fall back on FlushMode.TurnBased.\n\t *\n\t * @experimental - Not ready for use\n\t */\n\tAsync = 2,\n}\n\n/**\n * This tells the visibility state of a Fluid object. It basically tracks whether the object is not visible, visible\n * locally within the container only or visible globally to all clients.\n * @alpha\n */\nexport const VisibilityState = {\n\t/**\n\t * Indicates that the object is not visible. This is the state when an object is first created.\n\t */\n\tNotVisible: \"NotVisible\",\n\n\t/**\n\t * Indicates that the object is visible locally within the container. This is the state when an object is attached\n\t * to the container's graph but the container itself isn't globally visible. The object's state goes from not\n\t * visible to locally visible.\n\t */\n\tLocallyVisible: \"LocallyVisible\",\n\n\t/**\n\t * Indicates that the object is visible globally to all clients. This is the state of an object in 2 scenarios:\n\t *\n\t * 1. It is attached to the container's graph when the container is globally visible. The object's state goes from\n\t * not visible to globally visible.\n\t *\n\t * 2. When a container becomes globally visible, all locally visible objects go from locally visible to globally\n\t * visible.\n\t */\n\tGloballyVisible: \"GloballyVisible\",\n};\n/**\n * @alpha\n */\nexport type VisibilityState = (typeof VisibilityState)[keyof typeof VisibilityState];\n\n/**\n * @alpha\n */\nexport interface IContainerRuntimeBaseEvents extends IEvent {\n\t(event: \"batchBegin\", listener: (op: ISequencedDocumentMessage) => void);\n\t/**\n\t * @param runtimeMessage - tells if op is runtime op. If it is, it was unpacked, i.e. it's type and content\n\t * represent internal container runtime type / content.\n\t */\n\t(event: \"op\", listener: (op: ISequencedDocumentMessage, runtimeMessage?: boolean) => void);\n\t(event: \"batchEnd\", listener: (error: any, op: ISequencedDocumentMessage) => void);\n\t(event: \"signal\", listener: (message: IInboundSignalMessage, local: boolean) => void);\n}\n\n/**\n * Encapsulates the return codes of the aliasing API.\n *\n * 'Success' - the datastore has been successfully aliased. It can now be used.\n * 'Conflict' - there is already a datastore bound to the provided alias. To acquire it's entry point, use\n * the `IContainerRuntime.getAliasedDataStoreEntryPoint` function. The current datastore should be discarded\n * and will be garbage collected. The current datastore cannot be aliased to a different value.\n * 'AlreadyAliased' - the datastore has already been previously bound to another alias name.\n * @alpha\n */\nexport type AliasResult = \"Success\" | \"Conflict\" | \"AlreadyAliased\";\n\n/**\n * Exposes some functionality/features of a data store:\n * - Handle to the data store's entryPoint\n * - Fluid router for the data store\n * - Can be assigned an alias\n * @alpha\n */\nexport interface IDataStore {\n\t/**\n\t * Attempt to assign an alias to the datastore.\n\t * If the operation succeeds, the datastore can be referenced\n\t * by the supplied alias and will not be garbage collected.\n\t *\n\t * @param alias - Given alias for this datastore.\n\t * @returns A promise with the {@link AliasResult}\n\t */\n\ttrySetAlias(alias: string): Promise<AliasResult>;\n\n\t/**\n\t * Exposes a handle to the root object / entryPoint of the data store. Use this as the primary way of interacting\n\t * with it.\n\t */\n\treadonly entryPoint: IFluidHandle<FluidObject>;\n}\n\n/**\n * A reduced set of functionality of IContainerRuntime that a data store context/data store runtime will need\n * TODO: this should be merged into IFluidDataStoreContext\n * @alpha\n */\nexport interface IContainerRuntimeBase extends IEventProvider<IContainerRuntimeBaseEvents> {\n\treadonly logger: ITelemetryBaseLogger;\n\treadonly clientDetails: IClientDetails;\n\n\t/**\n\t * Invokes the given callback and guarantees that all operations generated within the callback will be ordered\n\t * sequentially.\n\t *\n\t * If the callback throws an error, the container will close and the error will be logged.\n\t */\n\torderSequentially(callback: () => void): void;\n\n\t/**\n\t * Submits a container runtime level signal to be sent to other clients.\n\t * @param type - Type of the signal.\n\t * @param content - Content of the signal.\n\t */\n\tsubmitSignal(type: string, content: any): void;\n\n\t/**\n\t * @deprecated 0.16 Issue #1537, #3631\n\t */\n\t_createDataStoreWithProps(\n\t\tpkg: string | string[],\n\t\tprops?: any,\n\t\tid?: string,\n\t): Promise<IDataStore>;\n\n\t/**\n\t * Creates a data store and returns an object that exposes a handle to the data store's entryPoint, and also serves\n\t * as the data store's router. The data store is not bound to a container, and in such state is not persisted to\n\t * storage (file). Storing the entryPoint handle (or any other handle inside the data store, e.g. for DDS) into an\n\t * already attached DDS (or non-attached DDS that will eventually get attached to storage) will result in this\n\t * store being attached to storage.\n\t * @param pkg - Package name of the data store factory\n\t */\n\tcreateDataStore(pkg: string | string[]): Promise<IDataStore>;\n\n\t/**\n\t * Creates detached data store context. Only after context.attachRuntime() is called,\n\t * data store initialization is considered complete.\n\t */\n\tcreateDetachedDataStore(pkg: Readonly<string[]>): IFluidDataStoreContextDetached;\n\n\t/**\n\t * Get an absolute url for a provided container-relative request.\n\t * Returns undefined if the container or data store isn't attached to storage.\n\t * @param relativeUrl - A relative request within the container\n\t */\n\tgetAbsoluteUrl(relativeUrl: string): Promise<string | undefined>;\n\n\tuploadBlob(blob: ArrayBufferLike, signal?: AbortSignal): Promise<IFluidHandle<ArrayBufferLike>>;\n\n\t/**\n\t * Returns the current quorum.\n\t */\n\tgetQuorum(): IQuorumClients;\n\n\t/**\n\t * Returns the current audience.\n\t */\n\tgetAudience(): IAudience;\n}\n\n/**\n * Minimal interface a data store runtime needs to provide for IFluidDataStoreContext to bind to control.\n *\n * Functionality include attach, snapshot, op/signal processing, request routes, expose an entryPoint,\n * and connection state notifications\n * @alpha\n */\nexport interface IFluidDataStoreChannel extends IDisposable {\n\treadonly id: string;\n\n\t/**\n\t * Indicates the attachment state of the channel to a host service.\n\t */\n\treadonly attachState: AttachState;\n\n\treadonly visibilityState: VisibilityState;\n\n\t/**\n\t * Runs through the graph and attaches the bound handles. Then binds this runtime to the container.\n\t * @deprecated This will be removed in favor of {@link IFluidDataStoreChannel.makeVisibleAndAttachGraph}.\n\t */\n\tattachGraph(): void;\n\n\t/**\n\t * Makes the data store channel visible in the container. Also, runs through its graph and attaches all\n\t * bound handles that represent its dependencies in the container's graph.\n\t */\n\tmakeVisibleAndAttachGraph(): void;\n\n\t/**\n\t * Retrieves the summary used as part of the initial summary message\n\t */\n\tgetAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;\n\n\t/**\n\t * Processes the op.\n\t */\n\tprocess(message: ISequencedDocumentMessage, local: boolean, localOpMetadata: unknown): void;\n\n\t/**\n\t * Processes the signal.\n\t */\n\tprocessSignal(message: any, local: boolean): void;\n\n\t/**\n\t * Generates a summary for the channel.\n\t * Introduced with summarizerNode - will be required in a future release.\n\t * @param fullTree - true to bypass optimizations and force a full summary tree.\n\t * @param trackState - This tells whether we should track state from this summary.\n\t * @param telemetryContext - summary data passed through the layers for telemetry purposes\n\t */\n\tsummarize(\n\t\tfullTree?: boolean,\n\t\ttrackState?: boolean,\n\t\ttelemetryContext?: ITelemetryContext,\n\t): Promise<ISummaryTreeWithStats>;\n\n\t/**\n\t * Returns the data used for garbage collection. This includes a list of GC nodes that represent this context\n\t * including any of its children. Each node has a list of outbound routes to other GC nodes in the document.\n\t * @param fullGC - true to bypass optimizations and force full generation of GC data.\n\t */\n\tgetGCData(fullGC?: boolean): Promise<IGarbageCollectionData>;\n\n\t/**\n\t * After GC has run, called to notify this channel of routes that are used in it.\n\t * @param usedRoutes - The routes that are used in this channel.\n\t */\n\tupdateUsedRoutes(usedRoutes: string[]): void;\n\n\t/**\n\t * Notifies this object about changes in the connection state.\n\t * @param value - New connection state.\n\t * @param clientId - ID of the client. It's old ID when in disconnected state and\n\t * it's new client ID when we are connecting or connected.\n\t */\n\tsetConnectionState(connected: boolean, clientId?: string);\n\n\t/**\n\t * Ask the DDS to resubmit a message. This could be because we reconnected and this message was not acked.\n\t * @param type - The type of the original message.\n\t * @param content - The content of the original message.\n\t * @param localOpMetadata - The local metadata associated with the original message.\n\t */\n\treSubmit(type: string, content: any, localOpMetadata: unknown);\n\n\tapplyStashedOp(content: any): Promise<unknown>;\n\n\t/**\n\t * Revert a local message.\n\t * @param type - The type of the original message.\n\t * @param content - The content of the original message.\n\t * @param localOpMetadata - The local metadata associated with the original message.\n\t */\n\trollback?(type: string, content: any, localOpMetadata: unknown): void;\n\n\t/**\n\t * Exposes a handle to the root object / entryPoint of the component. Use this as the primary way of interacting\n\t * with the component.\n\t */\n\treadonly entryPoint: IFluidHandle<FluidObject>;\n\n\trequest(request: IRequest): Promise<IResponse>;\n}\n\n/**\n * @alpha\n */\nexport type CreateChildSummarizerNodeFn = (\n\tsummarizeInternal: SummarizeInternalFn,\n\tgetGCDataFn: (fullGC?: boolean) => Promise<IGarbageCollectionData>,\n\t/**\n\t * @deprecated The functionality to get base GC details has been moved to summarizer node.\n\t */\n\tgetBaseGCDetailsFn?: () => Promise<IGarbageCollectionDetailsBase>,\n) => ISummarizerNodeWithGC;\n\n/**\n * @alpha\n */\nexport interface IFluidDataStoreContextEvents extends IEvent {\n\t(event: \"attaching\" | \"attached\", listener: () => void);\n}\n\n/**\n * Represents the context for the data store. It is used by the data store runtime to\n * get information and call functionality to the container.\n * @alpha\n */\nexport interface IFluidDataStoreContext\n\textends IEventProvider<IFluidDataStoreContextEvents>,\n\t\tPartial<IProvideFluidDataStoreRegistry>,\n\t\tIProvideFluidHandleContext {\n\treadonly id: string;\n\t/**\n\t * A data store created by a client, is a local data store for that client. Also, when a detached container loads\n\t * from a snapshot, all the data stores are treated as local data stores because at that stage the container\n\t * still doesn't exists in storage and so the data store couldn't have been created by any other client.\n\t * Value of this never changes even after the data store is attached.\n\t * As implementer of data store runtime, you can use this property to check that this data store belongs to this\n\t * client and hence implement any scenario based on that.\n\t */\n\treadonly isLocalDataStore: boolean;\n\t/**\n\t * The package path of the data store as per the package factory.\n\t */\n\treadonly packagePath: readonly string[];\n\treadonly options: ILoaderOptions;\n\treadonly clientId: string | undefined;\n\treadonly connected: boolean;\n\treadonly deltaManager: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>;\n\treadonly storage: IDocumentStorageService;\n\treadonly baseSnapshot: ISnapshotTree | undefined;\n\treadonly logger: ITelemetryBaseLogger;\n\treadonly clientDetails: IClientDetails;\n\treadonly idCompressor?: IIdCompressor;\n\t/**\n\t * Indicates the attachment state of the data store to a host service.\n\t */\n\treadonly attachState: AttachState;\n\n\treadonly containerRuntime: IContainerRuntimeBase;\n\n\t/**\n\t * @deprecated 0.16 Issue #1635, #3631\n\t */\n\treadonly createProps?: any;\n\n\t/**\n\t * Ambient services provided with the context\n\t */\n\treadonly scope: FluidObject;\n\n\t/**\n\t * Returns the current quorum.\n\t */\n\tgetQuorum(): IQuorumClients;\n\n\t/**\n\t * Returns the current audience.\n\t */\n\tgetAudience(): IAudience;\n\n\t/**\n\t * Invokes the given callback and expects that no ops are submitted\n\t * until execution finishes. If an op is submitted, an error will be raised.\n\t *\n\t * Can be disabled by feature gate `Fluid.ContainerRuntime.DisableOpReentryCheck`\n\t *\n\t * @param callback - the callback to be invoked\n\t */\n\tensureNoDataModelChanges<T>(callback: () => T): T;\n\n\t/**\n\t * Submits the message to be sent to other clients.\n\t * @param type - Type of the message.\n\t * @param content - Content of the message.\n\t * @param localOpMetadata - The local metadata associated with the message. This is kept locally and not sent to\n\t * the server. This will be sent back when this message is received back from the server. This is also sent if\n\t * we are asked to resubmit the message.\n\t */\n\tsubmitMessage(type: string, content: any, localOpMetadata: unknown): void;\n\n\t/**\n\t * Submits the signal to be sent to other clients.\n\t * @param type - Type of the signal.\n\t * @param content - Content of the signal.\n\t * @param targetClientId - When specified, the signal is only sent to the provided client id.\n\t */\n\tsubmitSignal(type: string, content: any, targetClientId?: string): void;\n\n\t/**\n\t * Called to make the data store locally visible in the container. This happens automatically for root data stores\n\t * when they are marked as root. For non-root data stores, this happens when their handle is added to a visible DDS.\n\t */\n\tmakeLocallyVisible(): void;\n\n\t/**\n\t * Call by IFluidDataStoreChannel, indicates that a channel is dirty and needs to be part of the summary.\n\t * @param address - The address of the channel that is dirty.\n\t */\n\tsetChannelDirty(address: string): void;\n\n\t/**\n\t * Get an absolute url to the container based on the provided relativeUrl.\n\t * Returns undefined if the container or data store isn't attached to storage.\n\t * @param relativeUrl - A relative request within the container\n\t */\n\tgetAbsoluteUrl(relativeUrl: string): Promise<string | undefined>;\n\n\tgetCreateChildSummarizerNodeFn(\n\t\t/**\n\t\t * Initial id or path part of this node\n\t\t */\n\t\tid: string,\n\t\t/**\n\t\t * Information needed to create the node.\n\t\t * If it is from a base summary, it will assert that a summary has been seen.\n\t\t * Attach information if it is created from an attach op.\n\t\t * If it is local, it will throw unsupported errors on calls to summarize.\n\t\t */\n\t\tcreateParam: CreateChildSummarizerNodeParam,\n\t): CreateChildSummarizerNodeFn;\n\n\tuploadBlob(blob: ArrayBufferLike, signal?: AbortSignal): Promise<IFluidHandle<ArrayBufferLike>>;\n\n\t/**\n\t * @deprecated The functionality to get base GC details has been moved to summarizer node.\n\t *\n\t * Returns the GC details in the initial summary of this data store. This is used to initialize the data store\n\t * and its children with the GC details from the previous summary.\n\t */\n\tgetBaseGCDetails(): Promise<IGarbageCollectionDetailsBase>;\n\n\t/**\n\t * @deprecated There is no replacement for this, its functionality is no longer needed at this layer.\n\t * It will be removed in a future release, sometime after 2.0.0-internal.8.0.0\n\t *\n\t * Called when a new outbound reference is added to another node. This is used by garbage collection to identify\n\t * all references added in the system.\n\t * @param srcHandle - The handle of the node that added the reference.\n\t * @param outboundHandle - The handle of the outbound node that is referenced.\n\t */\n\taddedGCOutboundReference?(srcHandle: IFluidHandle, outboundHandle: IFluidHandle): void;\n}\n\n/**\n * @alpha\n */\nexport interface IFluidDataStoreContextDetached extends IFluidDataStoreContext {\n\t/**\n\t * Binds a runtime to the context.\n\t */\n\tattachRuntime(\n\t\tfactory: IProvideFluidDataStoreFactory,\n\t\tdataStoreRuntime: IFluidDataStoreChannel,\n\t): Promise<void>;\n}\n"]}
1
+ {"version":3,"file":"dataStoreContext.js","sourceRoot":"","sources":["../src/dataStoreContext.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAsCH;;;GAGG;AACH,IAAY,SAcX;AAdD,WAAY,SAAS;IACpB;;;;;OAKG;IACH,mDAAS,CAAA;IAET;;;OAGG;IACH,mDAAS,CAAA;AACV,CAAC,EAdW,SAAS,yBAAT,SAAS,QAcpB;AAED;;GAEG;AACH,IAAY,qBAWX;AAXD,WAAY,qBAAqB;IAChC;;;;;;;;OAQG;IACH,mEAAS,CAAA;AACV,CAAC,EAXW,qBAAqB,qCAArB,qBAAqB,QAWhC;AAED;;;;GAIG;AACU,QAAA,eAAe,GAAG;IAC9B;;OAEG;IACH,UAAU,EAAE,YAAY;IAExB;;;;OAIG;IACH,cAAc,EAAE,gBAAgB;IAEhC;;;;;;;;OAQG;IACH,eAAe,EAAE,iBAAiB;CAClC,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type {\n\tIEvent,\n\tIEventProvider,\n\tITelemetryBaseLogger,\n\tIDisposable,\n\tIProvideFluidHandleContext,\n\tIFluidHandle,\n\tIRequest,\n\tIResponse,\n\tFluidObject,\n} from \"@fluidframework/core-interfaces\";\nimport type { IAudience, IDeltaManager, AttachState } from \"@fluidframework/container-definitions\";\nimport type { IDocumentStorageService } from \"@fluidframework/driver-definitions\";\nimport type {\n\tIClientDetails,\n\tIDocumentMessage,\n\tIQuorumClients,\n\tISequencedDocumentMessage,\n\tISnapshotTree,\n} from \"@fluidframework/protocol-definitions\";\nimport type { IIdCompressor } from \"@fluidframework/id-compressor\";\nimport type { IProvideFluidDataStoreFactory } from \"./dataStoreFactory.js\";\nimport type { IProvideFluidDataStoreRegistry } from \"./dataStoreRegistry.js\";\nimport type {\n\tIGarbageCollectionData,\n\tIGarbageCollectionDetailsBase,\n} from \"./garbageCollectionDefinitions.js\";\nimport type { IInboundSignalMessage } from \"./protocol.js\";\nimport type {\n\tCreateChildSummarizerNodeParam,\n\tISummarizerNodeWithGC,\n\tISummaryTreeWithStats,\n\tITelemetryContext,\n\tSummarizeInternalFn,\n} from \"./summary.js\";\n\n/**\n * Runtime flush mode handling\n * @alpha\n */\nexport enum FlushMode {\n\t/**\n\t * In Immediate flush mode the runtime will immediately send all operations to the driver layer.\n\t *\n\t * @deprecated This option will be removed in the next major version and should not be used. Use {@link FlushMode.TurnBased} instead, which is the default.\n\t * See https://github.com/microsoft/FluidFramework/tree/main/packages/runtime/container-runtime/src/opLifecycle#how-batching-works\n\t */\n\tImmediate,\n\n\t/**\n\t * When in TurnBased flush mode the runtime will buffer operations in the current turn and send them as a single\n\t * batch at the end of the turn. The flush call on the runtime can be used to force send the current batch.\n\t */\n\tTurnBased,\n}\n\n/**\n * @internal\n */\nexport enum FlushModeExperimental {\n\t/**\n\t * When in Async flush mode, the runtime will accumulate all operations across JS turns and send them as a single\n\t * batch when all micro-tasks are complete.\n\t *\n\t * This feature requires a version of the loader which supports reference sequence numbers. If an older version of\n\t * the loader is used, the runtime will fall back on FlushMode.TurnBased.\n\t *\n\t * @experimental - Not ready for use\n\t */\n\tAsync = 2,\n}\n\n/**\n * This tells the visibility state of a Fluid object. It basically tracks whether the object is not visible, visible\n * locally within the container only or visible globally to all clients.\n * @alpha\n */\nexport const VisibilityState = {\n\t/**\n\t * Indicates that the object is not visible. This is the state when an object is first created.\n\t */\n\tNotVisible: \"NotVisible\",\n\n\t/**\n\t * Indicates that the object is visible locally within the container. This is the state when an object is attached\n\t * to the container's graph but the container itself isn't globally visible. The object's state goes from not\n\t * visible to locally visible.\n\t */\n\tLocallyVisible: \"LocallyVisible\",\n\n\t/**\n\t * Indicates that the object is visible globally to all clients. This is the state of an object in 2 scenarios:\n\t *\n\t * 1. It is attached to the container's graph when the container is globally visible. The object's state goes from\n\t * not visible to globally visible.\n\t *\n\t * 2. When a container becomes globally visible, all locally visible objects go from locally visible to globally\n\t * visible.\n\t */\n\tGloballyVisible: \"GloballyVisible\",\n};\n/**\n * @alpha\n */\nexport type VisibilityState = (typeof VisibilityState)[keyof typeof VisibilityState];\n\n/**\n * @alpha\n */\nexport interface IContainerRuntimeBaseEvents extends IEvent {\n\t(event: \"batchBegin\", listener: (op: ISequencedDocumentMessage) => void);\n\t/**\n\t * @param runtimeMessage - tells if op is runtime op. If it is, it was unpacked, i.e. it's type and content\n\t * represent internal container runtime type / content.\n\t */\n\t(event: \"op\", listener: (op: ISequencedDocumentMessage, runtimeMessage?: boolean) => void);\n\t(event: \"batchEnd\", listener: (error: any, op: ISequencedDocumentMessage) => void);\n\t(event: \"signal\", listener: (message: IInboundSignalMessage, local: boolean) => void);\n\t(event: \"dispose\", listener: () => void);\n}\n\n/**\n * Encapsulates the return codes of the aliasing API.\n *\n * 'Success' - the datastore has been successfully aliased. It can now be used.\n * 'Conflict' - there is already a datastore bound to the provided alias. To acquire it's entry point, use\n * the `IContainerRuntime.getAliasedDataStoreEntryPoint` function. The current datastore should be discarded\n * and will be garbage collected. The current datastore cannot be aliased to a different value.\n * 'AlreadyAliased' - the datastore has already been previously bound to another alias name.\n * @alpha\n */\nexport type AliasResult = \"Success\" | \"Conflict\" | \"AlreadyAliased\";\n\n/**\n * Exposes some functionality/features of a data store:\n * - Handle to the data store's entryPoint\n * - Fluid router for the data store\n * - Can be assigned an alias\n * @alpha\n */\nexport interface IDataStore {\n\t/**\n\t * Attempt to assign an alias to the datastore.\n\t * If the operation succeeds, the datastore can be referenced\n\t * by the supplied alias and will not be garbage collected.\n\t *\n\t * @param alias - Given alias for this datastore.\n\t * @returns A promise with the {@link AliasResult}\n\t */\n\ttrySetAlias(alias: string): Promise<AliasResult>;\n\n\t/**\n\t * Exposes a handle to the root object / entryPoint of the data store. Use this as the primary way of interacting\n\t * with it.\n\t */\n\treadonly entryPoint: IFluidHandle<FluidObject>;\n}\n\n/**\n * A reduced set of functionality of IContainerRuntime that a data store context/data store runtime will need\n * TODO: this should be merged into IFluidDataStoreContext\n * @alpha\n */\nexport interface IContainerRuntimeBase extends IEventProvider<IContainerRuntimeBaseEvents> {\n\treadonly logger: ITelemetryBaseLogger;\n\treadonly clientDetails: IClientDetails;\n\treadonly disposed: boolean;\n\n\t/**\n\t * Invokes the given callback and guarantees that all operations generated within the callback will be ordered\n\t * sequentially.\n\t *\n\t * If the callback throws an error, the container will close and the error will be logged.\n\t */\n\torderSequentially(callback: () => void): void;\n\n\t/**\n\t * Submits a container runtime level signal to be sent to other clients.\n\t * @param type - Type of the signal.\n\t * @param content - Content of the signal.\n\t * @param targetClientId - When specified, the signal is only sent to the provided client id.\n\t */\n\tsubmitSignal(type: string, content: any, targetClientId?: string): void;\n\n\t/**\n\t * @deprecated 0.16 Issue #1537, #3631\n\t */\n\t_createDataStoreWithProps(\n\t\tpkg: Readonly<string | string[]>,\n\t\tprops?: any,\n\t\tid?: string,\n\t): Promise<IDataStore>;\n\n\t/**\n\t * Creates a data store and returns an object that exposes a handle to the data store's entryPoint, and also serves\n\t * as the data store's router. The data store is not bound to a container, and in such state is not persisted to\n\t * storage (file). Storing the entryPoint handle (or any other handle inside the data store, e.g. for DDS) into an\n\t * already attached DDS (or non-attached DDS that will eventually get attached to storage) will result in this\n\t * store being attached to storage.\n\t * @param pkg - Package name of the data store factory\n\t * @param loadingGroupId - This represents the group of the datastore within a container or its snapshot.\n\t * When not specified the datastore will belong to a `default` group. Read more about it in this\n\t * {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}\n\t */\n\tcreateDataStore(pkg: Readonly<string | string[]>, loadingGroupId?: string): Promise<IDataStore>;\n\n\t/**\n\t * Creates detached data store context. Only after context.attachRuntime() is called,\n\t * data store initialization is considered complete.\n\t * @param pkg - Package name of the data store factory\n\t * @param loadingGroupId - This represents the group of the datastore within a container or its snapshot.\n\t * When not specified the datastore will belong to a `default` group. Read more about it in this\n\t * {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}.\n\t */\n\tcreateDetachedDataStore(\n\t\tpkg: Readonly<string[]>,\n\t\tloadingGroupId?: string,\n\t): IFluidDataStoreContextDetached;\n\n\t/**\n\t * Get an absolute url for a provided container-relative request.\n\t * Returns undefined if the container or data store isn't attached to storage.\n\t * @param relativeUrl - A relative request within the container\n\t */\n\tgetAbsoluteUrl(relativeUrl: string): Promise<string | undefined>;\n\n\tuploadBlob(blob: ArrayBufferLike, signal?: AbortSignal): Promise<IFluidHandle<ArrayBufferLike>>;\n\n\t/**\n\t * Returns the current quorum.\n\t */\n\tgetQuorum(): IQuorumClients;\n\n\t/**\n\t * Returns the current audience.\n\t */\n\tgetAudience(): IAudience;\n\n\t/**\n\t * Generates a new ID that is guaranteed to be unique across all sessions for this container.\n\t * It could be in compact form (non-negative integer, oppotunistic), but it could also be UUID string.\n\t * UUIDs generated will have low entropy in groups and will compress well.\n\t * It can be leveraged anywhere in container where container unique IDs are required, i.e. any place\n\t * that uses uuid() and stores result in container is likely candidate to start leveraging this API.\n\t * If you always want to convert to string, instead of doing String(generateDocumentUniqueId()), consider\n\t * doing encodeCompactIdToString(generateDocumentUniqueId()).\n\t *\n\t * For more details, please see IIdCompressor.generateDocumentUniqueId()\n\t */\n\tgenerateDocumentUniqueId(): number | string;\n\n\t/**\n\t * Api to fetch the snapshot from the service for a loadingGroupIds.\n\t * @param loadingGroupIds - LoadingGroupId for which the snapshot is asked for.\n\t * @param pathParts - Parts of the path, which we want to extract from the snapshot tree.\n\t * @returns - snapshotTree and the sequence number of the snapshot.\n\t */\n\tgetSnapshotForLoadingGroupId(\n\t\tloadingGroupIds: string[],\n\t\tpathParts: string[],\n\t): Promise<{ snapshotTree: ISnapshotTree; sequenceNumber: number }>;\n}\n\n/**\n * Minimal interface a data store runtime needs to provide for IFluidDataStoreContext to bind to control.\n *\n * Functionality include attach, snapshot, op/signal processing, request routes, expose an entryPoint,\n * and connection state notifications\n * @alpha\n */\nexport interface IFluidDataStoreChannel extends IDisposable {\n\t/**\n\t * Makes the data store channel visible in the container. Also, runs through its graph and attaches all\n\t * bound handles that represent its dependencies in the container's graph.\n\t */\n\tmakeVisibleAndAttachGraph(): void;\n\n\t/**\n\t * Synchronously retrieves the summary used as part of the initial summary message\n\t */\n\tgetAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;\n\n\t/**\n\t * Synchronously retrieves GC Data (representing the outbound routes present) for the initial state of the DataStore\n\t */\n\tgetAttachGCData?(telemetryContext?: ITelemetryContext): IGarbageCollectionData;\n\n\t/**\n\t * Processes the op.\n\t */\n\tprocess(\n\t\tmessage: ISequencedDocumentMessage,\n\t\tlocal: boolean,\n\t\tlocalOpMetadata: unknown,\n\t\taddedOutboundReference?: (fromNodePath: string, toNodePath: string) => void,\n\t): void;\n\n\t/**\n\t * Processes the signal.\n\t */\n\tprocessSignal(message: IInboundSignalMessage, local: boolean): void;\n\n\t/**\n\t * Generates a summary for the channel.\n\t * Introduced with summarizerNode - will be required in a future release.\n\t * @param fullTree - true to bypass optimizations and force a full summary tree.\n\t * @param trackState - This tells whether we should track state from this summary.\n\t * @param telemetryContext - summary data passed through the layers for telemetry purposes\n\t */\n\tsummarize(\n\t\tfullTree?: boolean,\n\t\ttrackState?: boolean,\n\t\ttelemetryContext?: ITelemetryContext,\n\t): Promise<ISummaryTreeWithStats>;\n\n\t/**\n\t * Returns the data used for garbage collection. This includes a list of GC nodes that represent this context\n\t * including any of its children. Each node has a list of outbound routes to other GC nodes in the document.\n\t * @param fullGC - true to bypass optimizations and force full generation of GC data.\n\t */\n\tgetGCData(fullGC?: boolean): Promise<IGarbageCollectionData>;\n\n\t/**\n\t * After GC has run, called to notify this channel of routes that are used in it.\n\t * @param usedRoutes - The routes that are used in this channel.\n\t */\n\tupdateUsedRoutes(usedRoutes: string[]): void;\n\n\t/**\n\t * Notifies this object about changes in the connection state.\n\t * @param value - New connection state.\n\t * @param clientId - ID of the client. It's old ID when in disconnected state and\n\t * it's new client ID when we are connecting or connected.\n\t */\n\tsetConnectionState(connected: boolean, clientId?: string);\n\n\t/**\n\t * Ask the DDS to resubmit a message. This could be because we reconnected and this message was not acked.\n\t * @param type - The type of the original message.\n\t * @param content - The content of the original message.\n\t * @param localOpMetadata - The local metadata associated with the original message.\n\t */\n\treSubmit(type: string, content: any, localOpMetadata: unknown);\n\n\tapplyStashedOp(content: any): Promise<unknown>;\n\n\t/**\n\t * Revert a local message.\n\t * @param type - The type of the original message.\n\t * @param content - The content of the original message.\n\t * @param localOpMetadata - The local metadata associated with the original message.\n\t */\n\trollback?(type: string, content: any, localOpMetadata: unknown): void;\n\n\t/**\n\t * Exposes a handle to the root object / entryPoint of the component. Use this as the primary way of interacting\n\t * with the component.\n\t */\n\treadonly entryPoint: IFluidHandle<FluidObject>;\n\n\trequest(request: IRequest): Promise<IResponse>;\n}\n\n/**\n * @alpha\n */\nexport type CreateChildSummarizerNodeFn = (\n\tsummarizeInternal: SummarizeInternalFn,\n\tgetGCDataFn: (fullGC?: boolean) => Promise<IGarbageCollectionData>,\n\t/**\n\t * @deprecated The functionality to get base GC details has been moved to summarizer node.\n\t */\n\tgetBaseGCDetailsFn?: () => Promise<IGarbageCollectionDetailsBase>,\n) => ISummarizerNodeWithGC;\n\n/**\n * @alpha\n */\nexport interface IFluidDataStoreContextEvents extends IEvent {\n\t(event: \"attaching\" | \"attached\", listener: () => void);\n}\n\n/**\n * Represents the context for the data store like objects. It is used by the data store runtime to\n * get information and call functionality to its parent.\n *\n * This layout is temporary, as {@link IFluidParentContext} and {@link IFluidDataStoreContext} will converge.\n *\n * @alpha\n */\nexport interface IFluidParentContext\n\textends IProvideFluidHandleContext,\n\t\tPartial<IProvideFluidDataStoreRegistry> {\n\treadonly options: Record<string | number, any>;\n\treadonly clientId: string | undefined;\n\treadonly connected: boolean;\n\treadonly deltaManager: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>;\n\treadonly storage: IDocumentStorageService;\n\treadonly logger: ITelemetryBaseLogger;\n\treadonly clientDetails: IClientDetails;\n\treadonly idCompressor?: IIdCompressor;\n\t/**\n\t * Represents the loading group to which the data store belongs to. Please refer to this readme for more context.\n\t * {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}\n\t */\n\treadonly loadingGroupId?: string;\n\t/**\n\t * Indicates the attachment state of the data store to a host service.\n\t */\n\treadonly attachState: AttachState;\n\n\treadonly containerRuntime: IContainerRuntimeBase;\n\n\t/**\n\t * Ambient services provided with the context\n\t */\n\treadonly scope: FluidObject;\n\n\treadonly gcThrowOnTombstoneUsage: boolean;\n\treadonly gcTombstoneEnforcementAllowed: boolean;\n\n\t/**\n\t * Returns the current quorum.\n\t */\n\tgetQuorum(): IQuorumClients;\n\n\t/**\n\t * Returns the current audience.\n\t */\n\tgetAudience(): IAudience;\n\n\t/**\n\t * Invokes the given callback and expects that no ops are submitted\n\t * until execution finishes. If an op is submitted, an error will be raised.\n\t *\n\t * Can be disabled by feature gate `Fluid.ContainerRuntime.DisableOpReentryCheck`\n\t *\n\t * @param callback - the callback to be invoked\n\t */\n\tensureNoDataModelChanges<T>(callback: () => T): T;\n\n\t/**\n\t * Submits the message to be sent to other clients.\n\t * @param type - Type of the message.\n\t * @param content - Content of the message.\n\t * @param localOpMetadata - The local metadata associated with the message. This is kept locally and not sent to\n\t * the server. This will be sent back when this message is received back from the server. This is also sent if\n\t * we are asked to resubmit the message.\n\t */\n\tsubmitMessage(type: string, content: any, localOpMetadata: unknown): void;\n\n\t/**\n\t * Submits the signal to be sent to other clients.\n\t * @param type - Type of the signal.\n\t * @param content - Content of the signal.\n\t * @param targetClientId - When specified, the signal is only sent to the provided client id.\n\t */\n\tsubmitSignal(type: string, content: any, targetClientId?: string): void;\n\n\t/**\n\t * Called to make the data store locally visible in the container. This happens automatically for root data stores\n\t * when they are marked as root. For non-root data stores, this happens when their handle is added to a visible DDS.\n\t */\n\tmakeLocallyVisible(): void;\n\n\t/**\n\t * Get an absolute url to the container based on the provided relativeUrl.\n\t * Returns undefined if the container or data store isn't attached to storage.\n\t * @param relativeUrl - A relative request within the container\n\t */\n\tgetAbsoluteUrl(relativeUrl: string): Promise<string | undefined>;\n\n\tgetCreateChildSummarizerNodeFn(\n\t\t/**\n\t\t * Initial id or path part of this node\n\t\t */\n\t\tid: string,\n\t\t/**\n\t\t * Information needed to create the node.\n\t\t * If it is from a base summary, it will assert that a summary has been seen.\n\t\t * Attach information if it is created from an attach op.\n\t\t * If it is local, it will throw unsupported errors on calls to summarize.\n\t\t */\n\t\tcreateParam: CreateChildSummarizerNodeParam,\n\t): CreateChildSummarizerNodeFn;\n\n\tdeleteChildSummarizerNode?(id: string): void;\n\n\tuploadBlob(blob: ArrayBufferLike, signal?: AbortSignal): Promise<IFluidHandle<ArrayBufferLike>>;\n\n\t/**\n\t * @deprecated There is no replacement for this, its functionality is no longer needed at this layer.\n\t * It will be removed in a future release, sometime after 2.0.0-internal.8.0.0\n\t *\n\t * Similar capability is exposed with from/to string paths instead of handles via @see addedGCOutboundRoute\n\t *\n\t * Called when a new outbound reference is added to another node. This is used by garbage collection to identify\n\t * all references added in the system.\n\t * @param srcHandle - The handle of the node that added the reference.\n\t * @param outboundHandle - The handle of the outbound node that is referenced.\n\t */\n\taddedGCOutboundReference?(\n\t\tsrcHandle: { absolutePath: string },\n\t\toutboundHandle: { absolutePath: string },\n\t): void;\n}\n\n/**\n * Represents the context for the data store. It is used by the data store runtime to\n * get information and call functionality to the container.\n * @alpha\n */\nexport interface IFluidDataStoreContext\n\textends IEventProvider<IFluidDataStoreContextEvents>,\n\t\tIFluidParentContext {\n\treadonly id: string;\n\t/**\n\t * A data store created by a client, is a local data store for that client. Also, when a detached container loads\n\t * from a snapshot, all the data stores are treated as local data stores because at that stage the container\n\t * still doesn't exists in storage and so the data store couldn't have been created by any other client.\n\t * Value of this never changes even after the data store is attached.\n\t * As implementer of data store runtime, you can use this property to check that this data store belongs to this\n\t * client and hence implement any scenario based on that.\n\t */\n\treadonly isLocalDataStore: boolean;\n\t/**\n\t * The package path of the data store as per the package factory.\n\t */\n\treadonly packagePath: readonly string[];\n\treadonly baseSnapshot: ISnapshotTree | undefined;\n\n\t/**\n\t * @deprecated 0.16 Issue #1635, #3631\n\t */\n\treadonly createProps?: any;\n\n\t/**\n\t * Call by IFluidDataStoreChannel, indicates that a channel is dirty and needs to be part of the summary.\n\t * @param address - The address of the channel that is dirty.\n\t */\n\tsetChannelDirty(address: string): void;\n\n\t/**\n\t * @deprecated The functionality to get base GC details has been moved to summarizer node.\n\t *\n\t * Returns the GC details in the initial summary of this data store. This is used to initialize the data store\n\t * and its children with the GC details from the previous summary.\n\t */\n\tgetBaseGCDetails(): Promise<IGarbageCollectionDetailsBase>;\n\n\t/**\n\t * (Same as @see addedGCOutboundReference, but with string paths instead of handles)\n\t *\n\t * Called when a new outbound reference is added to another node. This is used by garbage collection to identify\n\t * all references added in the system.\n\t *\n\t * @param fromPath - The absolute path of the node that added the reference.\n\t * @param toPath - The absolute path of the outbound node that is referenced.\n\t */\n\taddedGCOutboundRoute?(fromPath: string, toPath: string): void;\n}\n\n/**\n * @alpha\n */\nexport interface IFluidDataStoreContextDetached extends IFluidDataStoreContext {\n\t/**\n\t * Binds a runtime to the context.\n\t */\n\tattachRuntime(\n\t\tfactory: IProvideFluidDataStoreFactory,\n\t\tdataStoreRuntime: IFluidDataStoreChannel,\n\t): Promise<IDataStore>;\n}\n"]}
@@ -2,7 +2,7 @@
2
2
  * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
3
3
  * Licensed under the MIT License.
4
4
  */
5
- import { IFluidDataStoreContext, IFluidDataStoreChannel } from "./dataStoreContext";
5
+ import type { IFluidDataStoreContext, IFluidDataStoreChannel } from "./dataStoreContext.js";
6
6
  /**
7
7
  * @alpha
8
8
  */
@@ -1 +1 @@
1
- {"version":3,"file":"dataStoreFactory.d.ts","sourceRoot":"","sources":["../src/dataStoreFactory.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,sBAAsB,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AAEpF;;GAEG;AACH,eAAO,MAAM,sBAAsB,EAAE,MAAM,6BAAwD,CAAC;AAEpG;;GAEG;AACH,MAAM,WAAW,6BAA6B;IAC7C,QAAQ,CAAC,sBAAsB,EAAE,sBAAsB,CAAC;CACxD;AAED;;;;GAIG;AACH,MAAM,WAAW,sBAAuB,SAAQ,6BAA6B;IAC5E;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;;;OAIG;IACH,oBAAoB,CACnB,OAAO,EAAE,sBAAsB,EAC/B,QAAQ,EAAE,OAAO,GACf,OAAO,CAAC,sBAAsB,CAAC,CAAC;CACnC"}
1
+ {"version":3,"file":"dataStoreFactory.d.ts","sourceRoot":"","sources":["../src/dataStoreFactory.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,sBAAsB,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAE5F;;GAEG;AACH,eAAO,MAAM,sBAAsB,EAAE,MAAM,6BAAwD,CAAC;AAEpG;;GAEG;AACH,MAAM,WAAW,6BAA6B;IAC7C,QAAQ,CAAC,sBAAsB,EAAE,sBAAsB,CAAC;CACxD;AAED;;;;GAIG;AACH,MAAM,WAAW,sBAAuB,SAAQ,6BAA6B;IAC5E;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;;;OAIG;IACH,oBAAoB,CACnB,OAAO,EAAE,sBAAsB,EAC/B,QAAQ,EAAE,OAAO,GACf,OAAO,CAAC,sBAAsB,CAAC,CAAC;CACnC"}
@@ -1 +1 @@
1
- {"version":3,"file":"dataStoreFactory.js","sourceRoot":"","sources":["../src/dataStoreFactory.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH;;GAEG;AACU,QAAA,sBAAsB,GAAwC,wBAAwB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { IFluidDataStoreContext, IFluidDataStoreChannel } from \"./dataStoreContext\";\n\n/**\n * @alpha\n */\nexport const IFluidDataStoreFactory: keyof IProvideFluidDataStoreFactory = \"IFluidDataStoreFactory\";\n\n/**\n * @alpha\n */\nexport interface IProvideFluidDataStoreFactory {\n\treadonly IFluidDataStoreFactory: IFluidDataStoreFactory;\n}\n\n/**\n * IFluidDataStoreFactory create data stores. It is associated with an identifier (its `type` member)\n * and usually provided to consumers using this mapping through a data store registry.\n * @alpha\n */\nexport interface IFluidDataStoreFactory extends IProvideFluidDataStoreFactory {\n\t/**\n\t * String that uniquely identifies the type of data store created by this factory.\n\t */\n\ttype: string;\n\n\t/**\n\t * Generates runtime for the data store from the data store context. Once created should be bound to the context.\n\t * @param context - Context for the data store.\n\t * @param existing - If instantiating from an existing file.\n\t */\n\tinstantiateDataStore(\n\t\tcontext: IFluidDataStoreContext,\n\t\texisting: boolean,\n\t): Promise<IFluidDataStoreChannel>;\n}\n"]}
1
+ {"version":3,"file":"dataStoreFactory.js","sourceRoot":"","sources":["../src/dataStoreFactory.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH;;GAEG;AACU,QAAA,sBAAsB,GAAwC,wBAAwB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IFluidDataStoreContext, IFluidDataStoreChannel } from \"./dataStoreContext.js\";\n\n/**\n * @alpha\n */\nexport const IFluidDataStoreFactory: keyof IProvideFluidDataStoreFactory = \"IFluidDataStoreFactory\";\n\n/**\n * @alpha\n */\nexport interface IProvideFluidDataStoreFactory {\n\treadonly IFluidDataStoreFactory: IFluidDataStoreFactory;\n}\n\n/**\n * IFluidDataStoreFactory create data stores. It is associated with an identifier (its `type` member)\n * and usually provided to consumers using this mapping through a data store registry.\n * @alpha\n */\nexport interface IFluidDataStoreFactory extends IProvideFluidDataStoreFactory {\n\t/**\n\t * String that uniquely identifies the type of data store created by this factory.\n\t */\n\ttype: string;\n\n\t/**\n\t * Generates runtime for the data store from the data store context. Once created should be bound to the context.\n\t * @param context - Context for the data store.\n\t * @param existing - If instantiating from an existing file.\n\t */\n\tinstantiateDataStore(\n\t\tcontext: IFluidDataStoreContext,\n\t\texisting: boolean,\n\t): Promise<IFluidDataStoreChannel>;\n}\n"]}
@@ -2,7 +2,7 @@
2
2
  * Copyright (c) Microsoft Corporation and contributors. All rights reserved.
3
3
  * Licensed under the MIT License.
4
4
  */
5
- import { IProvideFluidDataStoreFactory } from "./dataStoreFactory";
5
+ import type { IProvideFluidDataStoreFactory } from "./dataStoreFactory.js";
6
6
  /**
7
7
  * A single registry entry that may be used to create data stores
8
8
  * It has to have either factory or registry, or both.
@@ -1 +1 @@
1
- {"version":3,"file":"dataStoreRegistry.d.ts","sourceRoot":"","sources":["../src/dataStoreRegistry.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,6BAA6B,EAAE,MAAM,oBAAoB,CAAC;AAEnE;;;;GAIG;AACH,MAAM,MAAM,2BAA2B,GAAG,QAAQ,CACjD,OAAO,CAAC,8BAA8B,GAAG,6BAA6B,CAAC,CACvE,CAAC;AACF;;;;GAIG;AACH,MAAM,MAAM,gCAAgC,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,2BAA2B,CAAC,CAAC,CAAC;AAC9F;;;GAGG;AACH,MAAM,MAAM,kCAAkC,GAAG,QAAQ,CAAC,gCAAgC,CAAC,CAAC;AAE5F;;GAEG;AACH,eAAO,MAAM,uBAAuB,EAAE,MAAM,8BAClB,CAAC;AAE3B;;GAEG;AACH,MAAM,WAAW,8BAA8B;IAC9C,QAAQ,CAAC,uBAAuB,EAAE,uBAAuB,CAAC;CAC1D;AAED;;;;GAIG;AACH,MAAM,WAAW,uBAAwB,SAAQ,8BAA8B;IAC9E,GAAG,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,2BAA2B,GAAG,SAAS,CAAC,CAAC;CACpE"}
1
+ {"version":3,"file":"dataStoreRegistry.d.ts","sourceRoot":"","sources":["../src/dataStoreRegistry.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,6BAA6B,EAAE,MAAM,uBAAuB,CAAC;AAE3E;;;;GAIG;AACH,MAAM,MAAM,2BAA2B,GAAG,QAAQ,CACjD,OAAO,CAAC,8BAA8B,GAAG,6BAA6B,CAAC,CACvE,CAAC;AACF;;;;GAIG;AACH,MAAM,MAAM,gCAAgC,GAAG,CAAC,MAAM,EAAE,OAAO,CAAC,2BAA2B,CAAC,CAAC,CAAC;AAC9F;;;GAGG;AACH,MAAM,MAAM,kCAAkC,GAAG,QAAQ,CAAC,gCAAgC,CAAC,CAAC;AAE5F;;GAEG;AACH,eAAO,MAAM,uBAAuB,EAAE,MAAM,8BAClB,CAAC;AAE3B;;GAEG;AACH,MAAM,WAAW,8BAA8B;IAC9C,QAAQ,CAAC,uBAAuB,EAAE,uBAAuB,CAAC;CAC1D;AAED;;;;GAIG;AACH,MAAM,WAAW,uBAAwB,SAAQ,8BAA8B;IAC9E,GAAG,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,2BAA2B,GAAG,SAAS,CAAC,CAAC;CACpE"}
@@ -1 +1 @@
1
- {"version":3,"file":"dataStoreRegistry.js","sourceRoot":"","sources":["../src/dataStoreRegistry.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAwBH;;GAEG;AACU,QAAA,uBAAuB,GACnC,yBAAyB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { IProvideFluidDataStoreFactory } from \"./dataStoreFactory\";\n\n/**\n * A single registry entry that may be used to create data stores\n * It has to have either factory or registry, or both.\n * @alpha\n */\nexport type FluidDataStoreRegistryEntry = Readonly<\n\tPartial<IProvideFluidDataStoreRegistry & IProvideFluidDataStoreFactory>\n>;\n/**\n * An associated pair of an identifier and registry entry. Registry entries\n * may be dynamically loaded.\n * @alpha\n */\nexport type NamedFluidDataStoreRegistryEntry = [string, Promise<FluidDataStoreRegistryEntry>];\n/**\n * An iterable identifier/registry entry pair list\n * @alpha\n */\nexport type NamedFluidDataStoreRegistryEntries = Iterable<NamedFluidDataStoreRegistryEntry>;\n\n/**\n * @alpha\n */\nexport const IFluidDataStoreRegistry: keyof IProvideFluidDataStoreRegistry =\n\t\"IFluidDataStoreRegistry\";\n\n/**\n * @alpha\n */\nexport interface IProvideFluidDataStoreRegistry {\n\treadonly IFluidDataStoreRegistry: IFluidDataStoreRegistry;\n}\n\n/**\n * An association of identifiers to data store registry entries, where the\n * entries can be used to create data stores.\n * @alpha\n */\nexport interface IFluidDataStoreRegistry extends IProvideFluidDataStoreRegistry {\n\tget(name: string): Promise<FluidDataStoreRegistryEntry | undefined>;\n}\n"]}
1
+ {"version":3,"file":"dataStoreRegistry.js","sourceRoot":"","sources":["../src/dataStoreRegistry.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAwBH;;GAEG;AACU,QAAA,uBAAuB,GACnC,yBAAyB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IProvideFluidDataStoreFactory } from \"./dataStoreFactory.js\";\n\n/**\n * A single registry entry that may be used to create data stores\n * It has to have either factory or registry, or both.\n * @alpha\n */\nexport type FluidDataStoreRegistryEntry = Readonly<\n\tPartial<IProvideFluidDataStoreRegistry & IProvideFluidDataStoreFactory>\n>;\n/**\n * An associated pair of an identifier and registry entry. Registry entries\n * may be dynamically loaded.\n * @alpha\n */\nexport type NamedFluidDataStoreRegistryEntry = [string, Promise<FluidDataStoreRegistryEntry>];\n/**\n * An iterable identifier/registry entry pair list\n * @alpha\n */\nexport type NamedFluidDataStoreRegistryEntries = Iterable<NamedFluidDataStoreRegistryEntry>;\n\n/**\n * @alpha\n */\nexport const IFluidDataStoreRegistry: keyof IProvideFluidDataStoreRegistry =\n\t\"IFluidDataStoreRegistry\";\n\n/**\n * @alpha\n */\nexport interface IProvideFluidDataStoreRegistry {\n\treadonly IFluidDataStoreRegistry: IFluidDataStoreRegistry;\n}\n\n/**\n * An association of identifiers to data store registry entries, where the\n * entries can be used to create data stores.\n * @alpha\n */\nexport interface IFluidDataStoreRegistry extends IProvideFluidDataStoreRegistry {\n\tget(name: string): Promise<FluidDataStoreRegistryEntry | undefined>;\n}\n"]}
@@ -9,7 +9,7 @@
9
9
  */
10
10
  export declare const gcTreeKey = "gc";
11
11
  /**
12
- * They prefix for GC blobs in the GC tree in summary.
12
+ * The prefix for GC blobs in the GC tree in summary.
13
13
  *
14
14
  * @internal
15
15
  */
@@ -26,6 +26,12 @@ export declare const gcTombstoneBlobKey = "__tombstones";
26
26
  * @internal
27
27
  */
28
28
  export declare const gcDeletedBlobKey = "__deletedNodes";
29
+ /**
30
+ * The key for the GC Data blob in attach summaries.
31
+ *
32
+ * @internal
33
+ */
34
+ export declare const gcDataBlobKey = ".gcdata";
29
35
  /**
30
36
  * Garbage collection data returned by nodes in a Container.
31
37
  * Used for running GC in the Container.
@@ -53,4 +59,4 @@ export interface IGarbageCollectionDetailsBase {
53
59
  */
54
60
  gcData?: IGarbageCollectionData;
55
61
  }
56
- //# sourceMappingURL=garbageCollection.d.ts.map
62
+ //# sourceMappingURL=garbageCollectionDefinitions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"garbageCollectionDefinitions.d.ts","sourceRoot":"","sources":["../src/garbageCollectionDefinitions.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;GAIG;AACH,eAAO,MAAM,SAAS,OAAO,CAAC;AAC9B;;;;GAIG;AACH,eAAO,MAAM,YAAY,SAAS,CAAC;AACnC;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,iBAAiB,CAAC;AACjD;;;;GAIG;AACH,eAAO,MAAM,gBAAgB,mBAAmB,CAAC;AACjD;;;;GAIG;AACH,eAAO,MAAM,aAAa,YAAY,CAAC;AAEvC;;;;GAIG;AACH,MAAM,WAAW,sBAAsB;IACtC;;OAEG;IACH,OAAO,EAAE;QAAE,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,EAAE,CAAA;KAAE,CAAC;CACpC;AAED;;;GAGG;AACH,MAAM,WAAW,6BAA6B;IAC7C;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB;;OAEG;IACH,MAAM,CAAC,EAAE,sBAAsB,CAAC;CAChC"}
@@ -4,7 +4,7 @@
4
4
  * Licensed under the MIT License.
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
- exports.gcDeletedBlobKey = exports.gcTombstoneBlobKey = exports.gcBlobPrefix = exports.gcTreeKey = void 0;
7
+ exports.gcDataBlobKey = exports.gcDeletedBlobKey = exports.gcTombstoneBlobKey = exports.gcBlobPrefix = exports.gcTreeKey = void 0;
8
8
  /**
9
9
  * The key for the GC tree in summary.
10
10
  *
@@ -12,7 +12,7 @@ exports.gcDeletedBlobKey = exports.gcTombstoneBlobKey = exports.gcBlobPrefix = e
12
12
  */
13
13
  exports.gcTreeKey = "gc";
14
14
  /**
15
- * They prefix for GC blobs in the GC tree in summary.
15
+ * The prefix for GC blobs in the GC tree in summary.
16
16
  *
17
17
  * @internal
18
18
  */
@@ -29,4 +29,10 @@ exports.gcTombstoneBlobKey = "__tombstones";
29
29
  * @internal
30
30
  */
31
31
  exports.gcDeletedBlobKey = "__deletedNodes";
32
- //# sourceMappingURL=garbageCollection.js.map
32
+ /**
33
+ * The key for the GC Data blob in attach summaries.
34
+ *
35
+ * @internal
36
+ */
37
+ exports.gcDataBlobKey = ".gcdata";
38
+ //# sourceMappingURL=garbageCollectionDefinitions.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"garbageCollectionDefinitions.js","sourceRoot":"","sources":["../src/garbageCollectionDefinitions.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH;;;;GAIG;AACU,QAAA,SAAS,GAAG,IAAI,CAAC;AAC9B;;;;GAIG;AACU,QAAA,YAAY,GAAG,MAAM,CAAC;AACnC;;;;GAIG;AACU,QAAA,kBAAkB,GAAG,cAAc,CAAC;AACjD;;;;GAIG;AACU,QAAA,gBAAgB,GAAG,gBAAgB,CAAC;AACjD;;;;GAIG;AACU,QAAA,aAAa,GAAG,SAAS,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * The key for the GC tree in summary.\n *\n * @internal\n */\nexport const gcTreeKey = \"gc\";\n/**\n * The prefix for GC blobs in the GC tree in summary.\n *\n * @internal\n */\nexport const gcBlobPrefix = \"__gc\";\n/**\n * The key for tombstone blob in the GC tree in summary.\n *\n * @internal\n */\nexport const gcTombstoneBlobKey = \"__tombstones\";\n/**\n * The key for deleted nodes blob in the GC tree in summary.\n *\n * @internal\n */\nexport const gcDeletedBlobKey = \"__deletedNodes\";\n/**\n * The key for the GC Data blob in attach summaries.\n *\n * @internal\n */\nexport const gcDataBlobKey = \".gcdata\";\n\n/**\n * Garbage collection data returned by nodes in a Container.\n * Used for running GC in the Container.\n * @public\n */\nexport interface IGarbageCollectionData {\n\t/**\n\t * The GC nodes of a Fluid object in the Container. Each node has an id and a set of routes to other GC nodes.\n\t */\n\tgcNodes: { [id: string]: string[] };\n}\n\n/**\n * GC details provided to each node during creation.\n * @alpha\n */\nexport interface IGarbageCollectionDetailsBase {\n\t/**\n\t * A list of routes to Fluid objects that are used in this node.\n\t */\n\tusedRoutes?: string[];\n\t/**\n\t * The GC data of this node.\n\t */\n\tgcData?: IGarbageCollectionData;\n}\n"]}