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

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.
@@ -108,6 +108,9 @@ export enum FlushModeExperimental {
108
108
  // @internal
109
109
  export const gcBlobPrefix = "__gc";
110
110
 
111
+ // @internal
112
+ export const gcDataBlobKey = ".gcdata";
113
+
111
114
  // @internal
112
115
  export const gcDeletedBlobKey = "__deletedNodes";
113
116
 
@@ -186,6 +189,7 @@ export interface IFluidDataStoreChannel extends IDisposable {
186
189
  attachGraph(): void;
187
190
  readonly attachState: AttachState;
188
191
  readonly entryPoint: IFluidHandle<FluidObject>;
192
+ getAttachGCData?(telemetryContext?: ITelemetryContext): IGarbageCollectionData;
189
193
  getAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;
190
194
  getGCData(fullGC?: boolean): Promise<IGarbageCollectionData>;
191
195
  // (undocumented)
@@ -208,6 +212,7 @@ export interface IFluidDataStoreChannel extends IDisposable {
208
212
  export interface IFluidDataStoreContext extends IEventProvider<IFluidDataStoreContextEvents>, Partial<IProvideFluidDataStoreRegistry>, IProvideFluidHandleContext {
209
213
  // @deprecated (undocumented)
210
214
  addedGCOutboundReference?(srcHandle: IFluidHandle, outboundHandle: IFluidHandle): void;
215
+ addedGCOutboundRoute?(fromPath: string, toPath: string): void;
211
216
  readonly attachState: AttachState;
212
217
  // (undocumented)
213
218
  readonly baseSnapshot: ISnapshotTree | undefined;
@@ -200,9 +200,13 @@ export interface IFluidDataStoreChannel extends IDisposable {
200
200
  */
201
201
  makeVisibleAndAttachGraph(): void;
202
202
  /**
203
- * Retrieves the summary used as part of the initial summary message
203
+ * Synchronously retrieves the summary used as part of the initial summary message
204
204
  */
205
205
  getAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;
206
+ /**
207
+ * Synchronously retrieves GC Data (representing the outbound routes present) for the initial state of the DataStore
208
+ */
209
+ getAttachGCData?(telemetryContext?: ITelemetryContext): IGarbageCollectionData;
206
210
  /**
207
211
  * Processes the op.
208
212
  */
@@ -388,12 +392,24 @@ export interface IFluidDataStoreContext extends IEventProvider<IFluidDataStoreCo
388
392
  * @deprecated There is no replacement for this, its functionality is no longer needed at this layer.
389
393
  * It will be removed in a future release, sometime after 2.0.0-internal.8.0.0
390
394
  *
395
+ * Similar capability is exposed with from/to string paths instead of handles via @see addedGCOutboundRoute
396
+ *
391
397
  * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
392
398
  * all references added in the system.
393
399
  * @param srcHandle - The handle of the node that added the reference.
394
400
  * @param outboundHandle - The handle of the outbound node that is referenced.
395
401
  */
396
402
  addedGCOutboundReference?(srcHandle: IFluidHandle, outboundHandle: IFluidHandle): void;
403
+ /**
404
+ * (Same as @see addedGCOutboundReference, but with string paths instead of handles)
405
+ *
406
+ * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
407
+ * all references added in the system.
408
+ *
409
+ * @param fromPath - The absolute path of the node that added the reference.
410
+ * @param toPath - The absolute path of the outbound node that is referenced.
411
+ */
412
+ addedGCOutboundRoute?(fromPath: string, toPath: string): void;
397
413
  }
398
414
  /**
399
415
  * @alpha
@@ -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,oBAAoB,EACpB,WAAW,EACX,0BAA0B,EAC1B,YAAY,EACZ,QAAQ,EACR,SAAS,EACT,WAAW,EACX,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACN,SAAS,EACT,aAAa,EACb,WAAW,EACX,cAAc,EACd,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAAE,uBAAuB,EAAE,MAAM,oCAAoC,CAAC;AAC7E,OAAO,EACN,cAAc,EACd,gBAAgB,EAChB,cAAc,EACd,yBAAyB,EACzB,aAAa,EACb,MAAM,sC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AAG,OAAO,CAAC,YAAY,CAAC,eAAe,CAAC,CAAC,CAAC;IAEhG;;;;;OAKG;IACH,gBAAgB,IAAI,OAAO,CAAC,6BAA6B,CAAC,CAAC;IAE3D;;;;;;;;;;OAUG;IACH,wBAAwB,CAAC,CAAC,SAAS,EAAE,YAAY,EAAE,cAAc,EAAE,YAAY,GAAG,IAAI,CAAC;IAEvF;;;;;;;;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,IAAI,CAAC,CAAC;CACjB"}
@@ -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;;;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 * 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(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 * 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?(srcHandle: IFluidHandle, outboundHandle: IFluidHandle): void;\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<void>;\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.
@@ -1 +1 @@
1
- {"version":3,"file":"garbageCollection.d.ts","sourceRoot":"","sources":["../src/garbageCollection.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;AAEjD;;;;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"}
1
+ {"version":3,"file":"garbageCollection.d.ts","sourceRoot":"","sources":["../src/garbageCollection.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
+ /**
33
+ * The key for the GC Data blob in attach summaries.
34
+ *
35
+ * @internal
36
+ */
37
+ exports.gcDataBlobKey = ".gcdata";
32
38
  //# sourceMappingURL=garbageCollection.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"garbageCollection.js","sourceRoot":"","sources":["../src/garbageCollection.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","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 * They 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/**\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"]}
1
+ {"version":3,"file":"garbageCollection.js","sourceRoot":"","sources":["../src/garbageCollection.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"]}
package/dist/index.d.ts CHANGED
@@ -6,7 +6,7 @@ export { AttributionInfo, AttributionKey, DetachedAttributionKey, LocalAttributi
6
6
  export { AliasResult, CreateChildSummarizerNodeFn, FlushMode, FlushModeExperimental, IContainerRuntimeBase, IContainerRuntimeBaseEvents, IDataStore, IFluidDataStoreChannel, IFluidDataStoreContext, IFluidDataStoreContextDetached, IFluidDataStoreContextEvents, VisibilityState, } from "./dataStoreContext";
7
7
  export { IFluidDataStoreFactory, IProvideFluidDataStoreFactory } from "./dataStoreFactory";
8
8
  export { FluidDataStoreRegistryEntry, IFluidDataStoreRegistry, IProvideFluidDataStoreRegistry, NamedFluidDataStoreRegistryEntries, NamedFluidDataStoreRegistryEntry, } from "./dataStoreRegistry";
9
- export { gcBlobPrefix, gcDeletedBlobKey, gcTombstoneBlobKey, gcTreeKey, IGarbageCollectionData, IGarbageCollectionDetailsBase, } from "./garbageCollection";
9
+ export { gcBlobPrefix, gcDataBlobKey, gcDeletedBlobKey, gcTombstoneBlobKey, gcTreeKey, IGarbageCollectionData, IGarbageCollectionDetailsBase, } from "./garbageCollection";
10
10
  export { IAttachMessage, IEnvelope, IInboundSignalMessage, InboundAttachMessage, ISignalEnvelope, } from "./protocol";
11
11
  export { blobCountPropertyName, channelsTreeName, CreateChildSummarizerNodeParam, CreateSummarizerNodeSource, IExperimentalIncrementalSummaryContext, ISummarizeInternalResult, ISummarizeResult, ISummarizerNode, ISummarizerNodeConfig, ISummarizerNodeConfigWithGC, ISummarizerNodeWithGC, ISummaryStats, ISummaryTreeWithStats, ITelemetryContext, SummarizeInternalFn, totalBlobSizePropertyName, } from "./summary";
12
12
  export {
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACN,eAAe,EACf,cAAc,EACd,sBAAsB,EACtB,mBAAmB,EACnB,gBAAgB,GAChB,MAAM,eAAe,CAAC;AACvB,OAAO,EACN,WAAW,EACX,2BAA2B,EAC3B,SAAS,EACT,qBAAqB,EACrB,qBAAqB,EACrB,2BAA2B,EAC3B,UAAU,EACV,sBAAsB,EACtB,sBAAsB,EACtB,8BAA8B,EAC9B,4BAA4B,EAC5B,eAAe,GACf,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,sBAAsB,EAAE,6BAA6B,EAAE,MAAM,oBAAoB,CAAC;AAC3F,OAAO,EACN,2BAA2B,EAC3B,uBAAuB,EACvB,8BAA8B,EAC9B,kCAAkC,EAClC,gCAAgC,GAChC,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACN,YAAY,EACZ,gBAAgB,EAChB,kBAAkB,EAClB,SAAS,EACT,sBAAsB,EACtB,6BAA6B,GAC7B,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACN,cAAc,EACd,SAAS,EACT,qBAAqB,EACrB,oBAAoB,EACpB,eAAe,GACf,MAAM,YAAY,CAAC;AACpB,OAAO,EACN,qBAAqB,EACrB,gBAAgB,EAChB,8BAA8B,EAC9B,0BAA0B,EAC1B,sCAAsC,EACtC,wBAAwB,EACxB,gBAAgB,EAChB,eAAe,EACf,qBAAqB,EACrB,2BAA2B,EAC3B,qBAAqB,EACrB,aAAa,EACb,qBAAqB,EACrB,iBAAiB,EACjB,mBAAmB,EACnB,yBAAyB,GACzB,MAAM,WAAW,CAAC;AAInB,OAAO;AACN;;GAEG;AACH,YAAY;AACZ;;GAEG;AACH,aAAa;AACb;;GAEG;AACH,iBAAiB;AACjB;;GAEG;AACH,eAAe;AACf;;GAEG;AACH,mBAAmB;AACnB;;GAEG;AACH,sBAAsB;AACtB;;GAEG;AACH,mCAAmC;AACnC;;GAEG;AACH,wCAAwC;AACxC;;GAEG;AACH,SAAS;AACT;;GAEG;AACH,wBAAwB;AACxB;;GAEG;AACH,QAAQ,GACR,MAAM,+BAA+B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EACN,eAAe,EACf,cAAc,EACd,sBAAsB,EACtB,mBAAmB,EACnB,gBAAgB,GAChB,MAAM,eAAe,CAAC;AACvB,OAAO,EACN,WAAW,EACX,2BAA2B,EAC3B,SAAS,EACT,qBAAqB,EACrB,qBAAqB,EACrB,2BAA2B,EAC3B,UAAU,EACV,sBAAsB,EACtB,sBAAsB,EACtB,8BAA8B,EAC9B,4BAA4B,EAC5B,eAAe,GACf,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,sBAAsB,EAAE,6BAA6B,EAAE,MAAM,oBAAoB,CAAC;AAC3F,OAAO,EACN,2BAA2B,EAC3B,uBAAuB,EACvB,8BAA8B,EAC9B,kCAAkC,EAClC,gCAAgC,GAChC,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACN,YAAY,EACZ,aAAa,EACb,gBAAgB,EAChB,kBAAkB,EAClB,SAAS,EACT,sBAAsB,EACtB,6BAA6B,GAC7B,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACN,cAAc,EACd,SAAS,EACT,qBAAqB,EACrB,oBAAoB,EACpB,eAAe,GACf,MAAM,YAAY,CAAC;AACpB,OAAO,EACN,qBAAqB,EACrB,gBAAgB,EAChB,8BAA8B,EAC9B,0BAA0B,EAC1B,sCAAsC,EACtC,wBAAwB,EACxB,gBAAgB,EAChB,eAAe,EACf,qBAAqB,EACrB,2BAA2B,EAC3B,qBAAqB,EACrB,aAAa,EACb,qBAAqB,EACrB,iBAAiB,EACjB,mBAAmB,EACnB,yBAAyB,GACzB,MAAM,WAAW,CAAC;AAInB,OAAO;AACN;;GAEG;AACH,YAAY;AACZ;;GAEG;AACH,aAAa;AACb;;GAEG;AACH,iBAAiB;AACjB;;GAEG;AACH,eAAe;AACf;;GAEG;AACH,mBAAmB;AACnB;;GAEG;AACH,sBAAsB;AACtB;;GAEG;AACH,mCAAmC;AACnC;;GAEG;AACH,wCAAwC;AACxC;;GAEG;AACH,SAAS;AACT;;GAEG;AACH,wBAAwB;AACxB;;GAEG;AACH,QAAQ,GACR,MAAM,+BAA+B,CAAC"}
package/dist/index.js CHANGED
@@ -4,7 +4,7 @@
4
4
  * Licensed under the MIT License.
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
- exports.IdCompressor = exports.totalBlobSizePropertyName = exports.CreateSummarizerNodeSource = exports.channelsTreeName = exports.blobCountPropertyName = exports.gcTreeKey = exports.gcTombstoneBlobKey = exports.gcDeletedBlobKey = exports.gcBlobPrefix = exports.IFluidDataStoreRegistry = exports.IFluidDataStoreFactory = exports.VisibilityState = exports.FlushModeExperimental = exports.FlushMode = void 0;
7
+ exports.IdCompressor = exports.totalBlobSizePropertyName = exports.CreateSummarizerNodeSource = exports.channelsTreeName = exports.blobCountPropertyName = exports.gcTreeKey = exports.gcTombstoneBlobKey = exports.gcDeletedBlobKey = exports.gcDataBlobKey = exports.gcBlobPrefix = exports.IFluidDataStoreRegistry = exports.IFluidDataStoreFactory = exports.VisibilityState = exports.FlushModeExperimental = exports.FlushMode = void 0;
8
8
  var dataStoreContext_1 = require("./dataStoreContext");
9
9
  Object.defineProperty(exports, "FlushMode", { enumerable: true, get: function () { return dataStoreContext_1.FlushMode; } });
10
10
  Object.defineProperty(exports, "FlushModeExperimental", { enumerable: true, get: function () { return dataStoreContext_1.FlushModeExperimental; } });
@@ -15,6 +15,7 @@ var dataStoreRegistry_1 = require("./dataStoreRegistry");
15
15
  Object.defineProperty(exports, "IFluidDataStoreRegistry", { enumerable: true, get: function () { return dataStoreRegistry_1.IFluidDataStoreRegistry; } });
16
16
  var garbageCollection_1 = require("./garbageCollection");
17
17
  Object.defineProperty(exports, "gcBlobPrefix", { enumerable: true, get: function () { return garbageCollection_1.gcBlobPrefix; } });
18
+ Object.defineProperty(exports, "gcDataBlobKey", { enumerable: true, get: function () { return garbageCollection_1.gcDataBlobKey; } });
18
19
  Object.defineProperty(exports, "gcDeletedBlobKey", { enumerable: true, get: function () { return garbageCollection_1.gcDeletedBlobKey; } });
19
20
  Object.defineProperty(exports, "gcTombstoneBlobKey", { enumerable: true, get: function () { return garbageCollection_1.gcTombstoneBlobKey; } });
20
21
  Object.defineProperty(exports, "gcTreeKey", { enumerable: true, get: function () { return garbageCollection_1.gcTreeKey; } });
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AASH,uDAa4B;AAV3B,6GAAA,SAAS,OAAA;AACT,yHAAA,qBAAqB,OAAA;AAQrB,mHAAA,eAAe,OAAA;AAEhB,uDAA2F;AAAlF,0HAAA,sBAAsB,OAAA;AAC/B,yDAM6B;AAJ5B,4HAAA,uBAAuB,OAAA;AAKxB,yDAO6B;AAN5B,iHAAA,YAAY,OAAA;AACZ,qHAAA,gBAAgB,OAAA;AAChB,uHAAA,kBAAkB,OAAA;AAClB,8GAAA,SAAS,OAAA;AAWV,qCAiBmB;AAhBlB,gHAAA,qBAAqB,OAAA;AACrB,2GAAA,gBAAgB,OAAA;AAEhB,qHAAA,0BAA0B,OAAA;AAY1B,oHAAA,yBAAyB,OAAA;AAG1B,0CAA0C;AAC1C,iCAAiC;AACjC,+DA6CuC;AA5CtC;;GAEG;AACH,6GAAA,YAAY,OAAA","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport {\n\tAttributionInfo,\n\tAttributionKey,\n\tDetachedAttributionKey,\n\tLocalAttributionKey,\n\tOpAttributionKey,\n} from \"./attribution\";\nexport {\n\tAliasResult,\n\tCreateChildSummarizerNodeFn,\n\tFlushMode,\n\tFlushModeExperimental,\n\tIContainerRuntimeBase,\n\tIContainerRuntimeBaseEvents,\n\tIDataStore,\n\tIFluidDataStoreChannel,\n\tIFluidDataStoreContext,\n\tIFluidDataStoreContextDetached,\n\tIFluidDataStoreContextEvents,\n\tVisibilityState,\n} from \"./dataStoreContext\";\nexport { IFluidDataStoreFactory, IProvideFluidDataStoreFactory } from \"./dataStoreFactory\";\nexport {\n\tFluidDataStoreRegistryEntry,\n\tIFluidDataStoreRegistry,\n\tIProvideFluidDataStoreRegistry,\n\tNamedFluidDataStoreRegistryEntries,\n\tNamedFluidDataStoreRegistryEntry,\n} from \"./dataStoreRegistry\";\nexport {\n\tgcBlobPrefix,\n\tgcDeletedBlobKey,\n\tgcTombstoneBlobKey,\n\tgcTreeKey,\n\tIGarbageCollectionData,\n\tIGarbageCollectionDetailsBase,\n} from \"./garbageCollection\";\nexport {\n\tIAttachMessage,\n\tIEnvelope,\n\tIInboundSignalMessage,\n\tInboundAttachMessage,\n\tISignalEnvelope,\n} from \"./protocol\";\nexport {\n\tblobCountPropertyName,\n\tchannelsTreeName,\n\tCreateChildSummarizerNodeParam,\n\tCreateSummarizerNodeSource,\n\tIExperimentalIncrementalSummaryContext,\n\tISummarizeInternalResult,\n\tISummarizeResult,\n\tISummarizerNode,\n\tISummarizerNodeConfig,\n\tISummarizerNodeConfigWithGC,\n\tISummarizerNodeWithGC,\n\tISummaryStats,\n\tISummaryTreeWithStats,\n\tITelemetryContext,\n\tSummarizeInternalFn,\n\ttotalBlobSizePropertyName,\n} from \"./summary\";\n\n// Re-exports for backwards compatibility.\n// Will be removed in the future.\nexport {\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tIdCompressor,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tIIdCompressor,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tIIdCompressorCore,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tIdCreationRange,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tOpSpaceCompressedId,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSerializedIdCompressor,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSerializedIdCompressorWithNoSession,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSerializedIdCompressorWithOngoingSession,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSessionId,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSessionSpaceCompressedId,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tStableId,\n} from \"@fluidframework/id-compressor\";\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AASH,uDAa4B;AAV3B,6GAAA,SAAS,OAAA;AACT,yHAAA,qBAAqB,OAAA;AAQrB,mHAAA,eAAe,OAAA;AAEhB,uDAA2F;AAAlF,0HAAA,sBAAsB,OAAA;AAC/B,yDAM6B;AAJ5B,4HAAA,uBAAuB,OAAA;AAKxB,yDAQ6B;AAP5B,iHAAA,YAAY,OAAA;AACZ,kHAAA,aAAa,OAAA;AACb,qHAAA,gBAAgB,OAAA;AAChB,uHAAA,kBAAkB,OAAA;AAClB,8GAAA,SAAS,OAAA;AAWV,qCAiBmB;AAhBlB,gHAAA,qBAAqB,OAAA;AACrB,2GAAA,gBAAgB,OAAA;AAEhB,qHAAA,0BAA0B,OAAA;AAY1B,oHAAA,yBAAyB,OAAA;AAG1B,0CAA0C;AAC1C,iCAAiC;AACjC,+DA6CuC;AA5CtC;;GAEG;AACH,6GAAA,YAAY,OAAA","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport {\n\tAttributionInfo,\n\tAttributionKey,\n\tDetachedAttributionKey,\n\tLocalAttributionKey,\n\tOpAttributionKey,\n} from \"./attribution\";\nexport {\n\tAliasResult,\n\tCreateChildSummarizerNodeFn,\n\tFlushMode,\n\tFlushModeExperimental,\n\tIContainerRuntimeBase,\n\tIContainerRuntimeBaseEvents,\n\tIDataStore,\n\tIFluidDataStoreChannel,\n\tIFluidDataStoreContext,\n\tIFluidDataStoreContextDetached,\n\tIFluidDataStoreContextEvents,\n\tVisibilityState,\n} from \"./dataStoreContext\";\nexport { IFluidDataStoreFactory, IProvideFluidDataStoreFactory } from \"./dataStoreFactory\";\nexport {\n\tFluidDataStoreRegistryEntry,\n\tIFluidDataStoreRegistry,\n\tIProvideFluidDataStoreRegistry,\n\tNamedFluidDataStoreRegistryEntries,\n\tNamedFluidDataStoreRegistryEntry,\n} from \"./dataStoreRegistry\";\nexport {\n\tgcBlobPrefix,\n\tgcDataBlobKey,\n\tgcDeletedBlobKey,\n\tgcTombstoneBlobKey,\n\tgcTreeKey,\n\tIGarbageCollectionData,\n\tIGarbageCollectionDetailsBase,\n} from \"./garbageCollection\";\nexport {\n\tIAttachMessage,\n\tIEnvelope,\n\tIInboundSignalMessage,\n\tInboundAttachMessage,\n\tISignalEnvelope,\n} from \"./protocol\";\nexport {\n\tblobCountPropertyName,\n\tchannelsTreeName,\n\tCreateChildSummarizerNodeParam,\n\tCreateSummarizerNodeSource,\n\tIExperimentalIncrementalSummaryContext,\n\tISummarizeInternalResult,\n\tISummarizeResult,\n\tISummarizerNode,\n\tISummarizerNodeConfig,\n\tISummarizerNodeConfigWithGC,\n\tISummarizerNodeWithGC,\n\tISummaryStats,\n\tISummaryTreeWithStats,\n\tITelemetryContext,\n\tSummarizeInternalFn,\n\ttotalBlobSizePropertyName,\n} from \"./summary\";\n\n// Re-exports for backwards compatibility.\n// Will be removed in the future.\nexport {\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tIdCompressor,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tIIdCompressor,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tIIdCompressorCore,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tIdCreationRange,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tOpSpaceCompressedId,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSerializedIdCompressor,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSerializedIdCompressorWithNoSession,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSerializedIdCompressorWithOngoingSession,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSessionId,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tSessionSpaceCompressedId,\n\t/**\n\t * @deprecated Import from `@fluidframework/id-compressor` instead.\n\t */\n\tStableId,\n} from \"@fluidframework/id-compressor\";\n"]}
@@ -139,6 +139,8 @@ export declare enum FlushMode {
139
139
 
140
140
  /* Excluded from this release type: gcBlobPrefix */
141
141
 
142
+ /* Excluded from this release type: gcDataBlobKey */
143
+
142
144
  /* Excluded from this release type: gcDeletedBlobKey */
143
145
 
144
146
  /* Excluded from this release type: gcTombstoneBlobKey */
@@ -330,9 +332,13 @@ export declare interface IFluidDataStoreChannel extends IDisposable {
330
332
  */
331
333
  makeVisibleAndAttachGraph(): void;
332
334
  /**
333
- * Retrieves the summary used as part of the initial summary message
335
+ * Synchronously retrieves the summary used as part of the initial summary message
334
336
  */
335
337
  getAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;
338
+ /**
339
+ * Synchronously retrieves GC Data (representing the outbound routes present) for the initial state of the DataStore
340
+ */
341
+ getAttachGCData?(telemetryContext?: ITelemetryContext): IGarbageCollectionData;
336
342
  /**
337
343
  * Processes the op.
338
344
  */
@@ -505,12 +511,24 @@ export declare interface IFluidDataStoreContext extends IEventProvider<IFluidDat
505
511
  * @deprecated There is no replacement for this, its functionality is no longer needed at this layer.
506
512
  * It will be removed in a future release, sometime after 2.0.0-internal.8.0.0
507
513
  *
514
+ * Similar capability is exposed with from/to string paths instead of handles via @see addedGCOutboundRoute
515
+ *
508
516
  * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
509
517
  * all references added in the system.
510
518
  * @param srcHandle - The handle of the node that added the reference.
511
519
  * @param outboundHandle - The handle of the outbound node that is referenced.
512
520
  */
513
521
  addedGCOutboundReference?(srcHandle: IFluidHandle, outboundHandle: IFluidHandle): void;
522
+ /**
523
+ * (Same as @see addedGCOutboundReference, but with string paths instead of handles)
524
+ *
525
+ * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
526
+ * all references added in the system.
527
+ *
528
+ * @param fromPath - The absolute path of the node that added the reference.
529
+ * @param toPath - The absolute path of the outbound node that is referenced.
530
+ */
531
+ addedGCOutboundRoute?(fromPath: string, toPath: string): void;
514
532
  }
515
533
 
516
534
  /**
@@ -61,6 +61,8 @@ import { TelemetryEventPropertyType } from '@fluidframework/core-interfaces';
61
61
 
62
62
  /* Excluded from this release type: gcBlobPrefix */
63
63
 
64
+ /* Excluded from this release type: gcDataBlobKey */
65
+
64
66
  /* Excluded from this release type: gcDeletedBlobKey */
65
67
 
66
68
  /* Excluded from this release type: gcTombstoneBlobKey */
@@ -61,6 +61,8 @@ import { TelemetryEventPropertyType } from '@fluidframework/core-interfaces';
61
61
 
62
62
  /* Excluded from this release type: gcBlobPrefix */
63
63
 
64
+ /* Excluded from this release type: gcDataBlobKey */
65
+
64
66
  /* Excluded from this release type: gcDeletedBlobKey */
65
67
 
66
68
  /* Excluded from this release type: gcTombstoneBlobKey */
@@ -171,12 +171,19 @@ export declare enum FlushModeExperimental {
171
171
  }
172
172
 
173
173
  /**
174
- * They prefix for GC blobs in the GC tree in summary.
174
+ * The prefix for GC blobs in the GC tree in summary.
175
175
  *
176
176
  * @internal
177
177
  */
178
178
  export declare const gcBlobPrefix = "__gc";
179
179
 
180
+ /**
181
+ * The key for the GC Data blob in attach summaries.
182
+ *
183
+ * @internal
184
+ */
185
+ export declare const gcDataBlobKey = ".gcdata";
186
+
180
187
  /**
181
188
  * The key for deleted nodes blob in the GC tree in summary.
182
189
  *
@@ -383,9 +390,13 @@ export declare interface IFluidDataStoreChannel extends IDisposable {
383
390
  */
384
391
  makeVisibleAndAttachGraph(): void;
385
392
  /**
386
- * Retrieves the summary used as part of the initial summary message
393
+ * Synchronously retrieves the summary used as part of the initial summary message
387
394
  */
388
395
  getAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;
396
+ /**
397
+ * Synchronously retrieves GC Data (representing the outbound routes present) for the initial state of the DataStore
398
+ */
399
+ getAttachGCData?(telemetryContext?: ITelemetryContext): IGarbageCollectionData;
389
400
  /**
390
401
  * Processes the op.
391
402
  */
@@ -558,12 +569,24 @@ export declare interface IFluidDataStoreContext extends IEventProvider<IFluidDat
558
569
  * @deprecated There is no replacement for this, its functionality is no longer needed at this layer.
559
570
  * It will be removed in a future release, sometime after 2.0.0-internal.8.0.0
560
571
  *
572
+ * Similar capability is exposed with from/to string paths instead of handles via @see addedGCOutboundRoute
573
+ *
561
574
  * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
562
575
  * all references added in the system.
563
576
  * @param srcHandle - The handle of the node that added the reference.
564
577
  * @param outboundHandle - The handle of the outbound node that is referenced.
565
578
  */
566
579
  addedGCOutboundReference?(srcHandle: IFluidHandle, outboundHandle: IFluidHandle): void;
580
+ /**
581
+ * (Same as @see addedGCOutboundReference, but with string paths instead of handles)
582
+ *
583
+ * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
584
+ * all references added in the system.
585
+ *
586
+ * @param fromPath - The absolute path of the node that added the reference.
587
+ * @param toPath - The absolute path of the outbound node that is referenced.
588
+ */
589
+ addedGCOutboundRoute?(fromPath: string, toPath: string): void;
567
590
  }
568
591
 
569
592
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fluidframework/runtime-definitions",
3
- "version": "2.0.0-rc.1.0.3",
3
+ "version": "2.0.0-rc.1.0.5",
4
4
  "description": "Fluid Runtime definitions",
5
5
  "homepage": "https://fluidframework.com",
6
6
  "repository": {
@@ -37,10 +37,10 @@
37
37
  "main": "dist/index.js",
38
38
  "types": "dist/index.d.ts",
39
39
  "dependencies": {
40
- "@fluidframework/container-definitions": ">=2.0.0-rc.1.0.3 <2.0.0-rc.1.1.0",
41
- "@fluidframework/core-interfaces": ">=2.0.0-rc.1.0.3 <2.0.0-rc.1.1.0",
42
- "@fluidframework/driver-definitions": ">=2.0.0-rc.1.0.3 <2.0.0-rc.1.1.0",
43
- "@fluidframework/id-compressor": ">=2.0.0-rc.1.0.3 <2.0.0-rc.1.1.0",
40
+ "@fluidframework/container-definitions": ">=2.0.0-rc.1.0.5 <2.0.0-rc.1.1.0",
41
+ "@fluidframework/core-interfaces": ">=2.0.0-rc.1.0.5 <2.0.0-rc.1.1.0",
42
+ "@fluidframework/driver-definitions": ">=2.0.0-rc.1.0.5 <2.0.0-rc.1.1.0",
43
+ "@fluidframework/id-compressor": ">=2.0.0-rc.1.0.5 <2.0.0-rc.1.1.0",
44
44
  "@fluidframework/protocol-definitions": "^3.1.0"
45
45
  },
46
46
  "devDependencies": {
@@ -258,10 +258,15 @@ export interface IFluidDataStoreChannel extends IDisposable {
258
258
  makeVisibleAndAttachGraph(): void;
259
259
 
260
260
  /**
261
- * Retrieves the summary used as part of the initial summary message
261
+ * Synchronously retrieves the summary used as part of the initial summary message
262
262
  */
263
263
  getAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;
264
264
 
265
+ /**
266
+ * Synchronously retrieves GC Data (representing the outbound routes present) for the initial state of the DataStore
267
+ */
268
+ getAttachGCData?(telemetryContext?: ITelemetryContext): IGarbageCollectionData;
269
+
265
270
  /**
266
271
  * Processes the op.
267
272
  */
@@ -486,12 +491,25 @@ export interface IFluidDataStoreContext
486
491
  * @deprecated There is no replacement for this, its functionality is no longer needed at this layer.
487
492
  * It will be removed in a future release, sometime after 2.0.0-internal.8.0.0
488
493
  *
494
+ * Similar capability is exposed with from/to string paths instead of handles via @see addedGCOutboundRoute
495
+ *
489
496
  * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
490
497
  * all references added in the system.
491
498
  * @param srcHandle - The handle of the node that added the reference.
492
499
  * @param outboundHandle - The handle of the outbound node that is referenced.
493
500
  */
494
501
  addedGCOutboundReference?(srcHandle: IFluidHandle, outboundHandle: IFluidHandle): void;
502
+
503
+ /**
504
+ * (Same as @see addedGCOutboundReference, but with string paths instead of handles)
505
+ *
506
+ * Called when a new outbound reference is added to another node. This is used by garbage collection to identify
507
+ * all references added in the system.
508
+ *
509
+ * @param fromPath - The absolute path of the node that added the reference.
510
+ * @param toPath - The absolute path of the outbound node that is referenced.
511
+ */
512
+ addedGCOutboundRoute?(fromPath: string, toPath: string): void;
495
513
  }
496
514
 
497
515
  /**
@@ -10,7 +10,7 @@
10
10
  */
11
11
  export const gcTreeKey = "gc";
12
12
  /**
13
- * They prefix for GC blobs in the GC tree in summary.
13
+ * The prefix for GC blobs in the GC tree in summary.
14
14
  *
15
15
  * @internal
16
16
  */
@@ -27,6 +27,12 @@ export const gcTombstoneBlobKey = "__tombstones";
27
27
  * @internal
28
28
  */
29
29
  export const gcDeletedBlobKey = "__deletedNodes";
30
+ /**
31
+ * The key for the GC Data blob in attach summaries.
32
+ *
33
+ * @internal
34
+ */
35
+ export const gcDataBlobKey = ".gcdata";
30
36
 
31
37
  /**
32
38
  * Garbage collection data returned by nodes in a Container.
package/src/index.ts CHANGED
@@ -34,6 +34,7 @@ export {
34
34
  } from "./dataStoreRegistry";
35
35
  export {
36
36
  gcBlobPrefix,
37
+ gcDataBlobKey,
37
38
  gcDeletedBlobKey,
38
39
  gcTombstoneBlobKey,
39
40
  gcTreeKey,