@fluidframework/container-runtime 2.0.0-dev-rc.1.0.0.232845 → 2.0.0-dev-rc.2.0.0.246488
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.cjs +5 -5
- package/{.mocharc.js → .mocharc.cjs} +1 -1
- package/CHANGELOG.md +54 -0
- package/README.md +45 -0
- package/{api-extractor-esm.json → api-extractor-cjs.json} +5 -1
- package/api-extractor-lint.json +1 -1
- package/api-extractor.json +1 -1
- package/api-report/container-runtime.api.md +426 -33
- package/dist/batchTracker.d.ts +1 -2
- package/dist/batchTracker.d.ts.map +1 -1
- package/dist/batchTracker.js.map +1 -1
- package/dist/blobManager.d.ts +0 -5
- package/dist/blobManager.d.ts.map +1 -1
- package/dist/blobManager.js +0 -12
- package/dist/blobManager.js.map +1 -1
- package/dist/channelCollection.d.ts +226 -0
- package/dist/channelCollection.d.ts.map +1 -0
- package/dist/{dataStores.js → channelCollection.js} +455 -150
- package/dist/channelCollection.js.map +1 -0
- package/dist/connectionTelemetry.d.ts +11 -1
- package/dist/connectionTelemetry.d.ts.map +1 -1
- package/dist/connectionTelemetry.js +42 -4
- package/dist/connectionTelemetry.js.map +1 -1
- package/dist/container-runtime-alpha.d.ts +128 -48
- package/dist/container-runtime-beta.d.ts +67 -9
- package/dist/container-runtime-public.d.ts +67 -9
- package/dist/container-runtime-untrimmed.d.ts +692 -49
- package/dist/containerHandleContext.d.ts +1 -1
- package/dist/containerHandleContext.d.ts.map +1 -1
- package/dist/containerHandleContext.js.map +1 -1
- package/dist/containerRuntime.d.ts +81 -64
- package/dist/containerRuntime.d.ts.map +1 -1
- package/dist/containerRuntime.js +522 -379
- package/dist/containerRuntime.js.map +1 -1
- package/dist/dataStore.d.ts +2 -3
- package/dist/dataStore.d.ts.map +1 -1
- package/dist/dataStore.js +12 -11
- package/dist/dataStore.js.map +1 -1
- package/dist/dataStoreContext.d.ts +118 -41
- package/dist/dataStoreContext.d.ts.map +1 -1
- package/dist/dataStoreContext.js +248 -159
- package/dist/dataStoreContext.js.map +1 -1
- package/dist/dataStoreContexts.d.ts +2 -1
- package/dist/dataStoreContexts.d.ts.map +1 -1
- package/dist/dataStoreContexts.js +1 -0
- package/dist/dataStoreContexts.js.map +1 -1
- package/dist/dataStoreRegistry.d.ts +4 -0
- package/dist/dataStoreRegistry.d.ts.map +1 -1
- package/dist/dataStoreRegistry.js +2 -2
- package/dist/dataStoreRegistry.js.map +1 -1
- package/dist/deltaManagerSummarizerProxy.d.ts +29 -4
- package/dist/deltaManagerSummarizerProxy.d.ts.map +1 -1
- package/dist/deltaManagerSummarizerProxy.js +91 -5
- package/dist/deltaManagerSummarizerProxy.js.map +1 -1
- package/dist/gc/garbageCollection.d.ts +12 -6
- package/dist/gc/garbageCollection.d.ts.map +1 -1
- package/dist/gc/garbageCollection.js +116 -78
- package/dist/gc/garbageCollection.js.map +1 -1
- package/dist/gc/gcConfigs.d.ts +2 -2
- package/dist/gc/gcConfigs.d.ts.map +1 -1
- package/dist/gc/gcConfigs.js +30 -23
- package/dist/gc/gcConfigs.js.map +1 -1
- package/dist/gc/gcDefinitions.d.ts +22 -13
- package/dist/gc/gcDefinitions.d.ts.map +1 -1
- package/dist/gc/gcDefinitions.js +7 -4
- package/dist/gc/gcDefinitions.js.map +1 -1
- package/dist/gc/gcHelpers.d.ts +2 -2
- package/dist/gc/gcHelpers.d.ts.map +1 -1
- package/dist/gc/gcHelpers.js.map +1 -1
- package/dist/gc/gcReferenceGraphAlgorithm.d.ts +1 -1
- package/dist/gc/gcReferenceGraphAlgorithm.d.ts.map +1 -1
- package/dist/gc/gcReferenceGraphAlgorithm.js.map +1 -1
- package/dist/gc/gcSummaryStateTracker.d.ts +12 -5
- package/dist/gc/gcSummaryStateTracker.d.ts.map +1 -1
- package/dist/gc/gcSummaryStateTracker.js +18 -6
- package/dist/gc/gcSummaryStateTracker.js.map +1 -1
- package/dist/gc/gcTelemetry.d.ts +6 -7
- package/dist/gc/gcTelemetry.d.ts.map +1 -1
- package/dist/gc/gcTelemetry.js +20 -18
- package/dist/gc/gcTelemetry.js.map +1 -1
- package/dist/gc/gcUnreferencedStateTracker.d.ts +1 -1
- package/dist/gc/gcUnreferencedStateTracker.d.ts.map +1 -1
- package/dist/gc/gcUnreferencedStateTracker.js +10 -10
- package/dist/gc/gcUnreferencedStateTracker.js.map +1 -1
- package/dist/gc/index.d.ts +8 -8
- package/dist/gc/index.d.ts.map +1 -1
- package/dist/gc/index.js +40 -39
- package/dist/gc/index.js.map +1 -1
- package/dist/index.d.ts +11 -21
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +36 -42
- package/dist/index.js.map +1 -1
- package/dist/messageTypes.d.ts +3 -3
- package/dist/messageTypes.d.ts.map +1 -1
- package/dist/messageTypes.js.map +1 -1
- package/dist/opLifecycle/batchManager.d.ts +2 -2
- package/dist/opLifecycle/batchManager.d.ts.map +1 -1
- package/dist/opLifecycle/batchManager.js.map +1 -1
- package/dist/opLifecycle/definitions.d.ts +2 -2
- package/dist/opLifecycle/definitions.d.ts.map +1 -1
- package/dist/opLifecycle/definitions.js.map +1 -1
- package/dist/opLifecycle/index.d.ts +8 -8
- package/dist/opLifecycle/index.d.ts.map +1 -1
- package/dist/opLifecycle/index.js +18 -18
- package/dist/opLifecycle/index.js.map +1 -1
- package/dist/opLifecycle/opCompressor.d.ts +1 -1
- package/dist/opLifecycle/opCompressor.d.ts.map +1 -1
- package/dist/opLifecycle/opCompressor.js +4 -4
- package/dist/opLifecycle/opCompressor.js.map +1 -1
- package/dist/opLifecycle/opDecompressor.d.ts +1 -1
- package/dist/opLifecycle/opDecompressor.d.ts.map +1 -1
- package/dist/opLifecycle/opDecompressor.js +3 -3
- package/dist/opLifecycle/opDecompressor.js.map +1 -1
- package/dist/opLifecycle/opGroupingManager.d.ts +1 -1
- package/dist/opLifecycle/opGroupingManager.d.ts.map +1 -1
- package/dist/opLifecycle/opGroupingManager.js +1 -10
- package/dist/opLifecycle/opGroupingManager.js.map +1 -1
- package/dist/opLifecycle/opSplitter.d.ts +1 -1
- package/dist/opLifecycle/opSplitter.d.ts.map +1 -1
- package/dist/opLifecycle/opSplitter.js +5 -5
- package/dist/opLifecycle/opSplitter.js.map +1 -1
- package/dist/opLifecycle/outbox.d.ts +7 -7
- package/dist/opLifecycle/outbox.d.ts.map +1 -1
- package/dist/opLifecycle/outbox.js +32 -18
- package/dist/opLifecycle/outbox.js.map +1 -1
- package/dist/opLifecycle/remoteMessageProcessor.d.ts +4 -4
- package/dist/opLifecycle/remoteMessageProcessor.d.ts.map +1 -1
- package/dist/opLifecycle/remoteMessageProcessor.js +7 -4
- package/dist/opLifecycle/remoteMessageProcessor.js.map +1 -1
- package/dist/package.json +3 -0
- package/dist/packageVersion.d.ts +1 -1
- package/dist/packageVersion.js +1 -1
- package/dist/packageVersion.js.map +1 -1
- package/dist/pendingStateManager.d.ts +2 -1
- package/dist/pendingStateManager.d.ts.map +1 -1
- package/dist/pendingStateManager.js +18 -10
- package/dist/pendingStateManager.js.map +1 -1
- package/dist/scheduleManager.d.ts +1 -2
- package/dist/scheduleManager.d.ts.map +1 -1
- package/dist/scheduleManager.js +9 -5
- package/dist/scheduleManager.js.map +1 -1
- package/dist/summary/index.d.ts +12 -12
- package/dist/summary/index.d.ts.map +1 -1
- package/dist/summary/index.js +43 -43
- package/dist/summary/index.js.map +1 -1
- package/dist/summary/orderedClientElection.d.ts.map +1 -1
- package/dist/summary/orderedClientElection.js +12 -8
- package/dist/summary/orderedClientElection.js.map +1 -1
- package/dist/summary/runWhileConnectedCoordinator.d.ts +1 -1
- package/dist/summary/runWhileConnectedCoordinator.d.ts.map +1 -1
- package/dist/summary/runWhileConnectedCoordinator.js.map +1 -1
- package/dist/summary/runningSummarizer.d.ts +5 -4
- package/dist/summary/runningSummarizer.d.ts.map +1 -1
- package/dist/summary/runningSummarizer.js +47 -32
- package/dist/summary/runningSummarizer.js.map +1 -1
- package/dist/summary/summarizer.d.ts +4 -4
- package/dist/summary/summarizer.d.ts.map +1 -1
- package/dist/summary/summarizer.js +6 -6
- package/dist/summary/summarizer.js.map +1 -1
- package/dist/summary/summarizerClientElection.d.ts +2 -2
- package/dist/summary/summarizerClientElection.d.ts.map +1 -1
- package/dist/summary/summarizerClientElection.js.map +1 -1
- package/dist/summary/summarizerHeuristics.d.ts +3 -3
- package/dist/summary/summarizerHeuristics.d.ts.map +1 -1
- package/dist/summary/summarizerHeuristics.js.map +1 -1
- package/dist/summary/summarizerNode/index.d.ts +3 -3
- package/dist/summary/summarizerNode/index.d.ts.map +1 -1
- package/dist/summary/summarizerNode/index.js +4 -4
- package/dist/summary/summarizerNode/index.js.map +1 -1
- package/dist/summary/summarizerNode/summarizerNode.d.ts +16 -5
- package/dist/summary/summarizerNode/summarizerNode.d.ts.map +1 -1
- package/dist/summary/summarizerNode/summarizerNode.js +40 -10
- package/dist/summary/summarizerNode/summarizerNode.js.map +1 -1
- package/dist/summary/summarizerNode/summarizerNodeUtils.d.ts +9 -1
- package/dist/summary/summarizerNode/summarizerNodeUtils.d.ts.map +1 -1
- package/dist/summary/summarizerNode/summarizerNodeUtils.js.map +1 -1
- package/dist/summary/summarizerNode/summarizerNodeWithGc.d.ts +3 -4
- package/dist/summary/summarizerNode/summarizerNodeWithGc.d.ts.map +1 -1
- package/dist/summary/summarizerNode/summarizerNodeWithGc.js +12 -12
- package/dist/summary/summarizerNode/summarizerNodeWithGc.js.map +1 -1
- package/dist/summary/summarizerTypes.d.ts +9 -20
- package/dist/summary/summarizerTypes.d.ts.map +1 -1
- package/dist/summary/summarizerTypes.js.map +1 -1
- package/dist/summary/summaryFormat.d.ts +15 -2
- package/dist/summary/summaryFormat.d.ts.map +1 -1
- package/dist/summary/summaryFormat.js.map +1 -1
- package/dist/summary/summaryGenerator.d.ts +6 -5
- package/dist/summary/summaryGenerator.d.ts.map +1 -1
- package/dist/summary/summaryGenerator.js +10 -1
- package/dist/summary/summaryGenerator.js.map +1 -1
- package/dist/summary/summaryManager.d.ts +5 -6
- package/dist/summary/summaryManager.d.ts.map +1 -1
- package/dist/summary/summaryManager.js +4 -5
- package/dist/summary/summaryManager.js.map +1 -1
- package/dist/tsdoc-metadata.json +1 -1
- package/lib/{batchTracker.d.mts → batchTracker.d.ts} +2 -3
- package/lib/batchTracker.d.ts.map +1 -0
- package/lib/{batchTracker.mjs → batchTracker.js} +1 -1
- package/lib/batchTracker.js.map +1 -0
- package/lib/{blobManager.d.mts → blobManager.d.ts} +1 -6
- package/lib/blobManager.d.ts.map +1 -0
- package/lib/{blobManager.mjs → blobManager.js} +1 -13
- package/lib/blobManager.js.map +1 -0
- package/lib/channelCollection.d.ts +226 -0
- package/lib/channelCollection.d.ts.map +1 -0
- package/lib/{dataStores.mjs → channelCollection.js} +442 -140
- package/lib/channelCollection.js.map +1 -0
- package/lib/{connectionTelemetry.d.mts → connectionTelemetry.d.ts} +12 -2
- package/lib/connectionTelemetry.d.ts.map +1 -0
- package/lib/{connectionTelemetry.mjs → connectionTelemetry.js} +43 -5
- package/lib/connectionTelemetry.js.map +1 -0
- package/lib/{container-runtime-alpha.d.mts → container-runtime-alpha.d.ts} +128 -48
- package/lib/{container-runtime-beta.d.mts → container-runtime-beta.d.ts} +67 -9
- package/lib/{container-runtime-public.d.mts → container-runtime-public.d.ts} +67 -9
- package/lib/{container-runtime-untrimmed.d.mts → container-runtime-untrimmed.d.ts} +692 -49
- package/lib/{containerHandleContext.d.mts → containerHandleContext.d.ts} +2 -2
- package/lib/containerHandleContext.d.ts.map +1 -0
- package/lib/{containerHandleContext.mjs → containerHandleContext.js} +1 -1
- package/lib/containerHandleContext.js.map +1 -0
- package/lib/{containerRuntime.d.mts → containerRuntime.d.ts} +86 -65
- package/lib/containerRuntime.d.ts.map +1 -0
- package/lib/{containerRuntime.mjs → containerRuntime.js} +444 -303
- package/lib/containerRuntime.js.map +1 -0
- package/lib/{dataStore.d.mts → dataStore.d.ts} +3 -4
- package/lib/dataStore.d.ts.map +1 -0
- package/lib/{dataStore.mjs → dataStore.js} +13 -12
- package/lib/dataStore.js.map +1 -0
- package/lib/{dataStoreContext.d.mts → dataStoreContext.d.ts} +119 -42
- package/lib/dataStoreContext.d.ts.map +1 -0
- package/lib/{dataStoreContext.mjs → dataStoreContext.js} +240 -151
- package/lib/dataStoreContext.js.map +1 -0
- package/lib/{dataStoreContexts.d.mts → dataStoreContexts.d.ts} +3 -2
- package/lib/dataStoreContexts.d.ts.map +1 -0
- package/lib/{dataStoreContexts.mjs → dataStoreContexts.js} +2 -1
- package/lib/dataStoreContexts.js.map +1 -0
- package/lib/{dataStoreRegistry.d.mts → dataStoreRegistry.d.ts} +5 -1
- package/lib/dataStoreRegistry.d.ts.map +1 -0
- package/lib/{dataStoreRegistry.mjs → dataStoreRegistry.js} +5 -1
- package/lib/dataStoreRegistry.js.map +1 -0
- package/{dist/deltaManagerProxyBase.d.ts → lib/deltaManagerSummarizerProxy.d.ts} +16 -7
- package/lib/deltaManagerSummarizerProxy.d.ts.map +1 -0
- package/lib/deltaManagerSummarizerProxy.js +124 -0
- package/lib/deltaManagerSummarizerProxy.js.map +1 -0
- package/lib/{deltaScheduler.d.mts → deltaScheduler.d.ts} +1 -1
- package/lib/deltaScheduler.d.ts.map +1 -0
- package/lib/{deltaScheduler.mjs → deltaScheduler.js} +1 -1
- package/lib/deltaScheduler.js.map +1 -0
- package/lib/{error.d.mts → error.d.ts} +1 -1
- package/lib/error.d.ts.map +1 -0
- package/lib/{error.mjs → error.js} +1 -1
- package/lib/error.js.map +1 -0
- package/lib/gc/{garbageCollection.d.mts → garbageCollection.d.ts} +13 -7
- package/lib/gc/garbageCollection.d.ts.map +1 -0
- package/lib/gc/{garbageCollection.mjs → garbageCollection.js} +79 -41
- package/lib/gc/garbageCollection.js.map +1 -0
- package/lib/gc/{gcConfigs.d.mts → gcConfigs.d.ts} +3 -3
- package/lib/gc/gcConfigs.d.ts.map +1 -0
- package/lib/gc/{gcConfigs.mjs → gcConfigs.js} +14 -7
- package/lib/gc/gcConfigs.js.map +1 -0
- package/lib/gc/{gcDefinitions.d.mts → gcDefinitions.d.ts} +23 -14
- package/lib/gc/gcDefinitions.d.ts.map +1 -0
- package/lib/gc/{gcDefinitions.mjs → gcDefinitions.js} +7 -4
- package/lib/gc/gcDefinitions.js.map +1 -0
- package/lib/gc/{gcHelpers.d.mts → gcHelpers.d.ts} +3 -3
- package/lib/gc/{gcHelpers.d.mts.map → gcHelpers.d.ts.map} +1 -1
- package/lib/gc/{gcHelpers.mjs → gcHelpers.js} +1 -1
- package/lib/gc/gcHelpers.js.map +1 -0
- package/lib/gc/{gcReferenceGraphAlgorithm.d.mts → gcReferenceGraphAlgorithm.d.ts} +2 -2
- package/lib/gc/gcReferenceGraphAlgorithm.d.ts.map +1 -0
- package/lib/gc/{gcReferenceGraphAlgorithm.mjs → gcReferenceGraphAlgorithm.js} +1 -1
- package/lib/gc/gcReferenceGraphAlgorithm.js.map +1 -0
- package/lib/gc/{gcSummaryDefinitions.d.mts → gcSummaryDefinitions.d.ts} +1 -1
- package/lib/gc/gcSummaryDefinitions.d.ts.map +1 -0
- package/lib/gc/{gcSummaryDefinitions.mjs → gcSummaryDefinitions.js} +1 -1
- package/lib/gc/gcSummaryDefinitions.js.map +1 -0
- package/lib/gc/{gcSummaryStateTracker.d.mts → gcSummaryStateTracker.d.ts} +13 -6
- package/lib/gc/gcSummaryStateTracker.d.ts.map +1 -0
- package/lib/gc/{gcSummaryStateTracker.mjs → gcSummaryStateTracker.js} +17 -5
- package/lib/gc/gcSummaryStateTracker.js.map +1 -0
- package/lib/gc/{gcTelemetry.d.mts → gcTelemetry.d.ts} +7 -8
- package/lib/gc/gcTelemetry.d.ts.map +1 -0
- package/lib/gc/{gcTelemetry.mjs → gcTelemetry.js} +5 -3
- package/lib/gc/gcTelemetry.js.map +1 -0
- package/lib/gc/{gcUnreferencedStateTracker.d.mts → gcUnreferencedStateTracker.d.ts} +2 -2
- package/lib/gc/gcUnreferencedStateTracker.d.ts.map +1 -0
- package/lib/gc/{gcUnreferencedStateTracker.mjs → gcUnreferencedStateTracker.js} +2 -2
- package/lib/gc/gcUnreferencedStateTracker.js.map +1 -0
- package/lib/gc/index.d.ts +13 -0
- package/lib/gc/index.d.ts.map +1 -0
- package/lib/gc/{index.mjs → index.js} +8 -8
- package/lib/gc/index.js.map +1 -0
- package/lib/{index.d.mts → index.d.ts} +12 -22
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +15 -0
- package/lib/index.js.map +1 -0
- package/lib/{messageTypes.d.mts → messageTypes.d.ts} +4 -4
- package/lib/messageTypes.d.ts.map +1 -0
- package/lib/{messageTypes.mjs → messageTypes.js} +1 -1
- package/lib/messageTypes.js.map +1 -0
- package/lib/{metadata.d.mts → metadata.d.ts} +1 -1
- package/lib/metadata.d.ts.map +1 -0
- package/lib/{metadata.mjs → metadata.js} +1 -1
- package/lib/metadata.js.map +1 -0
- package/lib/opLifecycle/{batchManager.d.mts → batchManager.d.ts} +3 -3
- package/lib/opLifecycle/batchManager.d.ts.map +1 -0
- package/lib/opLifecycle/{batchManager.mjs → batchManager.js} +1 -1
- package/lib/opLifecycle/batchManager.js.map +1 -0
- package/lib/opLifecycle/{definitions.d.mts → definitions.d.ts} +3 -3
- package/lib/opLifecycle/definitions.d.ts.map +1 -0
- package/lib/opLifecycle/{definitions.mjs → definitions.js} +1 -1
- package/lib/opLifecycle/definitions.js.map +1 -0
- package/lib/opLifecycle/index.d.ts +13 -0
- package/lib/opLifecycle/index.d.ts.map +1 -0
- package/lib/opLifecycle/index.js +12 -0
- package/lib/opLifecycle/index.js.map +1 -0
- package/lib/opLifecycle/{opCompressor.d.mts → opCompressor.d.ts} +2 -2
- package/lib/opLifecycle/opCompressor.d.ts.map +1 -0
- package/lib/opLifecycle/{opCompressor.mjs → opCompressor.js} +3 -3
- package/lib/opLifecycle/opCompressor.js.map +1 -0
- package/lib/opLifecycle/{opDecompressor.d.mts → opDecompressor.d.ts} +2 -2
- package/lib/opLifecycle/opDecompressor.d.ts.map +1 -0
- package/lib/opLifecycle/{opDecompressor.mjs → opDecompressor.js} +2 -2
- package/lib/opLifecycle/opDecompressor.js.map +1 -0
- package/lib/opLifecycle/{opGroupingManager.d.mts → opGroupingManager.d.ts} +2 -2
- package/lib/opLifecycle/opGroupingManager.d.ts.map +1 -0
- package/lib/opLifecycle/{opGroupingManager.mjs → opGroupingManager.js} +2 -11
- package/lib/opLifecycle/opGroupingManager.js.map +1 -0
- package/lib/opLifecycle/{opSplitter.d.mts → opSplitter.d.ts} +2 -2
- package/lib/opLifecycle/opSplitter.d.ts.map +1 -0
- package/lib/opLifecycle/{opSplitter.mjs → opSplitter.js} +3 -3
- package/lib/opLifecycle/opSplitter.js.map +1 -0
- package/lib/opLifecycle/{outbox.d.mts → outbox.d.ts} +8 -8
- package/lib/opLifecycle/outbox.d.ts.map +1 -0
- package/lib/opLifecycle/{outbox.mjs → outbox.js} +24 -10
- package/lib/opLifecycle/outbox.js.map +1 -0
- package/lib/opLifecycle/{remoteMessageProcessor.d.mts → remoteMessageProcessor.d.ts} +5 -5
- package/lib/opLifecycle/remoteMessageProcessor.d.ts.map +1 -0
- package/lib/opLifecycle/{remoteMessageProcessor.mjs → remoteMessageProcessor.js} +7 -4
- package/lib/opLifecycle/remoteMessageProcessor.js.map +1 -0
- package/lib/{opProperties.d.mts → opProperties.d.ts} +1 -1
- package/lib/opProperties.d.ts.map +1 -0
- package/lib/{opProperties.mjs → opProperties.js} +1 -1
- package/lib/opProperties.js.map +1 -0
- package/lib/{packageVersion.d.mts → packageVersion.d.ts} +2 -2
- package/lib/packageVersion.d.ts.map +1 -0
- package/lib/{packageVersion.mjs → packageVersion.js} +2 -2
- package/lib/packageVersion.js.map +1 -0
- package/lib/{pendingStateManager.d.mts → pendingStateManager.d.ts} +3 -2
- package/lib/pendingStateManager.d.ts.map +1 -0
- package/lib/{pendingStateManager.mjs → pendingStateManager.js} +18 -10
- package/lib/pendingStateManager.js.map +1 -0
- package/lib/{scheduleManager.d.mts → scheduleManager.d.ts} +6 -3
- package/lib/scheduleManager.d.ts.map +1 -0
- package/lib/{scheduleManager.mjs → scheduleManager.js} +7 -3
- package/lib/scheduleManager.js.map +1 -0
- package/lib/{storageServiceWithAttachBlobs.d.mts → storageServiceWithAttachBlobs.d.ts} +1 -1
- package/lib/storageServiceWithAttachBlobs.d.ts.map +1 -0
- package/lib/{storageServiceWithAttachBlobs.mjs → storageServiceWithAttachBlobs.js} +1 -1
- package/lib/storageServiceWithAttachBlobs.js.map +1 -0
- package/lib/summary/{index.d.mts → index.d.ts} +13 -13
- package/lib/summary/index.d.ts.map +1 -0
- package/lib/summary/{index.mjs → index.js} +12 -12
- package/lib/summary/index.js.map +1 -0
- package/lib/summary/{orderedClientElection.d.mts → orderedClientElection.d.ts} +5 -1
- package/lib/summary/orderedClientElection.d.ts.map +1 -0
- package/lib/summary/{orderedClientElection.mjs → orderedClientElection.js} +6 -2
- package/lib/summary/orderedClientElection.js.map +1 -0
- package/lib/summary/{runWhileConnectedCoordinator.d.mts → runWhileConnectedCoordinator.d.ts} +2 -2
- package/lib/summary/runWhileConnectedCoordinator.d.ts.map +1 -0
- package/lib/summary/{runWhileConnectedCoordinator.mjs → runWhileConnectedCoordinator.js} +1 -1
- package/lib/summary/runWhileConnectedCoordinator.js.map +1 -0
- package/lib/summary/{runningSummarizer.d.mts → runningSummarizer.d.ts} +6 -5
- package/lib/summary/runningSummarizer.d.ts.map +1 -0
- package/lib/summary/{runningSummarizer.mjs → runningSummarizer.js} +41 -26
- package/lib/summary/runningSummarizer.js.map +1 -0
- package/lib/summary/{summarizer.d.mts → summarizer.d.ts} +5 -5
- package/lib/summary/summarizer.d.ts.map +1 -0
- package/lib/summary/{summarizer.mjs → summarizer.js} +4 -4
- package/lib/summary/summarizer.js.map +1 -0
- package/lib/summary/{summarizerClientElection.d.mts → summarizerClientElection.d.ts} +3 -3
- package/lib/summary/summarizerClientElection.d.ts.map +1 -0
- package/lib/summary/{summarizerClientElection.mjs → summarizerClientElection.js} +1 -1
- package/lib/summary/summarizerClientElection.js.map +1 -0
- package/lib/summary/{summarizerHeuristics.d.mts → summarizerHeuristics.d.ts} +4 -4
- package/lib/summary/summarizerHeuristics.d.ts.map +1 -0
- package/lib/summary/{summarizerHeuristics.mjs → summarizerHeuristics.js} +1 -1
- package/lib/summary/summarizerHeuristics.js.map +1 -0
- package/lib/summary/summarizerNode/{index.d.mts → index.d.ts} +4 -4
- package/lib/summary/summarizerNode/index.d.ts.map +1 -0
- package/lib/summary/summarizerNode/index.js +7 -0
- package/lib/summary/summarizerNode/index.js.map +1 -0
- package/lib/summary/summarizerNode/{summarizerNode.d.mts → summarizerNode.d.ts} +17 -6
- package/lib/summary/summarizerNode/summarizerNode.d.ts.map +1 -0
- package/lib/summary/summarizerNode/{summarizerNode.mjs → summarizerNode.js} +34 -4
- package/lib/summary/summarizerNode/summarizerNode.js.map +1 -0
- package/lib/summary/summarizerNode/{summarizerNodeUtils.d.mts → summarizerNodeUtils.d.ts} +10 -2
- package/lib/summary/summarizerNode/summarizerNodeUtils.d.ts.map +1 -0
- package/lib/summary/summarizerNode/{summarizerNodeUtils.mjs → summarizerNodeUtils.js} +1 -1
- package/lib/summary/summarizerNode/summarizerNodeUtils.js.map +1 -0
- package/lib/summary/summarizerNode/{summarizerNodeWithGc.d.mts → summarizerNodeWithGc.d.ts} +4 -5
- package/lib/summary/summarizerNode/summarizerNodeWithGc.d.ts.map +1 -0
- package/lib/summary/summarizerNode/{summarizerNodeWithGc.mjs → summarizerNodeWithGc.js} +7 -7
- package/lib/summary/summarizerNode/summarizerNodeWithGc.js.map +1 -0
- package/lib/summary/{summarizerTypes.d.mts → summarizerTypes.d.ts} +10 -21
- package/lib/summary/summarizerTypes.d.ts.map +1 -0
- package/lib/summary/{summarizerTypes.mjs → summarizerTypes.js} +1 -1
- package/lib/summary/summarizerTypes.js.map +1 -0
- package/lib/summary/{summaryCollection.d.mts → summaryCollection.d.ts} +1 -1
- package/lib/summary/summaryCollection.d.ts.map +1 -0
- package/lib/summary/{summaryCollection.mjs → summaryCollection.js} +1 -1
- package/lib/summary/summaryCollection.js.map +1 -0
- package/lib/summary/{summaryFormat.d.mts → summaryFormat.d.ts} +16 -3
- package/lib/summary/summaryFormat.d.ts.map +1 -0
- package/lib/summary/{summaryFormat.mjs → summaryFormat.js} +1 -1
- package/lib/summary/summaryFormat.js.map +1 -0
- package/lib/summary/{summaryGenerator.d.mts → summaryGenerator.d.ts} +7 -6
- package/lib/summary/summaryGenerator.d.ts.map +1 -0
- package/lib/summary/{summaryGenerator.mjs → summaryGenerator.js} +11 -2
- package/lib/summary/summaryGenerator.js.map +1 -0
- package/lib/summary/{summaryManager.d.mts → summaryManager.d.ts} +6 -7
- package/lib/summary/summaryManager.d.ts.map +1 -0
- package/lib/summary/{summaryManager.mjs → summaryManager.js} +4 -5
- package/lib/summary/summaryManager.js.map +1 -0
- package/lib/test/batchTracker.spec.js +88 -0
- package/lib/test/batchTracker.spec.js.map +1 -0
- package/lib/test/blobManager.spec.js +835 -0
- package/lib/test/blobManager.spec.js.map +1 -0
- package/lib/test/channelCollection.spec.js +138 -0
- package/lib/test/channelCollection.spec.js.map +1 -0
- package/lib/test/containerRuntime.spec.js +1748 -0
- package/lib/test/containerRuntime.spec.js.map +1 -0
- package/lib/test/dataStoreContext.spec.js +771 -0
- package/lib/test/dataStoreContext.spec.js.map +1 -0
- package/lib/test/dataStoreCreation.spec.js +303 -0
- package/lib/test/dataStoreCreation.spec.js.map +1 -0
- package/lib/test/dataStoreRegistry.spec.js +26 -0
- package/lib/test/dataStoreRegistry.spec.js.map +1 -0
- package/lib/test/fuzz/fuzzUtils.js +66 -0
- package/lib/test/fuzz/fuzzUtils.js.map +1 -0
- package/lib/test/fuzz/summarizer.fuzz.spec.js +31 -0
- package/lib/test/fuzz/summarizer.fuzz.spec.js.map +1 -0
- package/lib/test/fuzz/summarizerFuzzMocks.js +162 -0
- package/lib/test/fuzz/summarizerFuzzMocks.js.map +1 -0
- package/lib/test/fuzz/summarizerFuzzSuite.js +106 -0
- package/lib/test/fuzz/summarizerFuzzSuite.js.map +1 -0
- package/lib/test/gc/garbageCollection.spec.js +1464 -0
- package/lib/test/gc/garbageCollection.spec.js.map +1 -0
- package/lib/test/gc/gcConfigs.spec.js +689 -0
- package/lib/test/gc/gcConfigs.spec.js.map +1 -0
- package/lib/test/gc/gcHelpers.spec.js +110 -0
- package/lib/test/gc/gcHelpers.spec.js.map +1 -0
- package/lib/test/gc/gcReferenceGraphAlgorithm.spec.js +68 -0
- package/lib/test/gc/gcReferenceGraphAlgorithm.spec.js.map +1 -0
- package/lib/test/gc/gcStats.spec.js +390 -0
- package/lib/test/gc/gcStats.spec.js.map +1 -0
- package/lib/test/gc/gcSummaryStateTracker.spec.js +228 -0
- package/lib/test/gc/gcSummaryStateTracker.spec.js.map +1 -0
- package/lib/test/gc/gcTelemetry.spec.js +530 -0
- package/lib/test/gc/gcTelemetry.spec.js.map +1 -0
- package/lib/test/gc/gcUnitTestHelpers.js +29 -0
- package/lib/test/gc/gcUnitTestHelpers.js.map +1 -0
- package/lib/test/gc/gcUnreferencedStateTracker.spec.js +192 -0
- package/lib/test/gc/gcUnreferencedStateTracker.spec.js.map +1 -0
- package/lib/test/getPendingBlobs.spec.js +193 -0
- package/lib/test/getPendingBlobs.spec.js.map +1 -0
- package/lib/test/hardwareStats.spec.js +93 -0
- package/lib/test/hardwareStats.spec.js.map +1 -0
- package/lib/test/index.js +6 -0
- package/lib/test/index.js.map +1 -0
- package/lib/test/opLifecycle/OpGroupingManager.spec.js +225 -0
- package/lib/test/opLifecycle/OpGroupingManager.spec.js.map +1 -0
- package/lib/test/opLifecycle/batchManager.spec.js +189 -0
- package/lib/test/opLifecycle/batchManager.spec.js.map +1 -0
- package/lib/test/opLifecycle/opCompressor.spec.js +74 -0
- package/lib/test/opLifecycle/opCompressor.spec.js.map +1 -0
- package/lib/test/opLifecycle/opDecompressor.spec.js +218 -0
- package/lib/test/opLifecycle/opDecompressor.spec.js.map +1 -0
- package/lib/test/opLifecycle/opSplitter.spec.js +272 -0
- package/lib/test/opLifecycle/opSplitter.spec.js.map +1 -0
- package/lib/test/opLifecycle/outbox.spec.js +675 -0
- package/lib/test/opLifecycle/outbox.spec.js.map +1 -0
- package/lib/test/opLifecycle/remoteMessageProcessor.spec.js +196 -0
- package/lib/test/opLifecycle/remoteMessageProcessor.spec.js.map +1 -0
- package/lib/test/pendingStateManager.spec.js +329 -0
- package/lib/test/pendingStateManager.spec.js.map +1 -0
- package/lib/test/scheduleManager.spec.js +270 -0
- package/lib/test/scheduleManager.spec.js.map +1 -0
- package/lib/test/summarizerNode.spec.js +326 -0
- package/lib/test/summarizerNode.spec.js.map +1 -0
- package/lib/test/summarizerNodeWithGc.spec.js +318 -0
- package/lib/test/summarizerNodeWithGc.spec.js.map +1 -0
- package/lib/test/summary/orderedClientElection.spec.js +535 -0
- package/lib/test/summary/orderedClientElection.spec.js.map +1 -0
- package/lib/test/summary/runningSummarizer.spec.js +1349 -0
- package/lib/test/summary/runningSummarizer.spec.js.map +1 -0
- package/lib/test/summary/summarizer.spec.js +29 -0
- package/lib/test/summary/summarizer.spec.js.map +1 -0
- package/lib/test/summary/summarizerClientElection.spec.js +436 -0
- package/lib/test/summary/summarizerClientElection.spec.js.map +1 -0
- package/lib/test/summary/summarizerHeuristics.spec.js +289 -0
- package/lib/test/summary/summarizerHeuristics.spec.js.map +1 -0
- package/lib/test/summary/summaryCollection.spec.js +200 -0
- package/lib/test/summary/summaryCollection.spec.js.map +1 -0
- package/lib/test/summary/summaryManager.spec.js +430 -0
- package/lib/test/summary/summaryManager.spec.js.map +1 -0
- package/lib/test/summary/testQuorumClients.js +34 -0
- package/lib/test/summary/testQuorumClients.js.map +1 -0
- package/lib/test/throttler.spec.js +175 -0
- package/lib/test/throttler.spec.js.map +1 -0
- package/lib/test/types/validateContainerRuntimePrevious.generated.js +180 -0
- package/lib/test/types/validateContainerRuntimePrevious.generated.js.map +1 -0
- package/lib/{throttler.d.mts → throttler.d.ts} +1 -1
- package/lib/throttler.d.ts.map +1 -0
- package/lib/{throttler.mjs → throttler.js} +1 -1
- package/lib/throttler.js.map +1 -0
- package/package.json +101 -88
- package/src/batchTracker.ts +1 -1
- package/src/blobManager.ts +1 -15
- package/src/{dataStores.ts → channelCollection.ts} +629 -178
- package/src/connectionTelemetry.ts +42 -3
- package/src/containerHandleContext.ts +1 -1
- package/src/containerRuntime.ts +626 -430
- package/src/dataStore.ts +16 -15
- package/src/dataStoreContext.ts +376 -216
- package/src/dataStoreContexts.ts +2 -1
- package/src/dataStoreRegistry.ts +1 -0
- package/src/deltaManagerSummarizerProxy.ts +132 -7
- package/src/gc/garbageCollection.ts +84 -44
- package/src/gc/gcConfigs.ts +17 -7
- package/src/gc/gcDefinitions.ts +23 -13
- package/src/gc/gcHelpers.ts +2 -2
- package/src/gc/gcReferenceGraphAlgorithm.ts +1 -1
- package/src/gc/gcSummaryStateTracker.ts +19 -7
- package/src/gc/gcTelemetry.ts +9 -7
- package/src/gc/gcUnreferencedStateTracker.ts +1 -1
- package/src/gc/index.ts +10 -9
- package/src/index.ts +28 -27
- package/src/messageTypes.ts +3 -3
- package/src/opLifecycle/README.md +2 -4
- package/src/opLifecycle/batchManager.ts +2 -2
- package/src/opLifecycle/definitions.ts +2 -2
- package/src/opLifecycle/index.ts +8 -8
- package/src/opLifecycle/opCompressor.ts +3 -3
- package/src/opLifecycle/opDecompressor.ts +3 -3
- package/src/opLifecycle/opGroupingManager.ts +3 -12
- package/src/opLifecycle/opSplitter.ts +3 -3
- package/src/opLifecycle/outbox.ts +43 -16
- package/src/opLifecycle/remoteMessageProcessor.ts +10 -6
- package/src/packageVersion.ts +1 -1
- package/src/pendingStateManager.ts +19 -13
- package/src/scheduleManager.ts +5 -4
- package/src/summary/index.ts +13 -12
- package/src/summary/orderedClientElection.ts +2 -1
- package/src/summary/runWhileConnectedCoordinator.ts +1 -1
- package/src/summary/runningSummarizer.ts +52 -32
- package/src/summary/summarizer.ts +7 -7
- package/src/summary/summarizerClientElection.ts +2 -2
- package/src/summary/summarizerHeuristics.ts +3 -3
- package/src/summary/summarizerNode/index.ts +6 -3
- package/src/summary/summarizerNode/summarizerNode.ts +50 -5
- package/src/summary/summarizerNode/summarizerNodeUtils.ts +14 -1
- package/src/summary/summarizerNode/summarizerNodeWithGc.ts +11 -11
- package/src/summary/summarizerTypes.ts +11 -23
- package/src/summary/summaryFormat.ts +16 -2
- package/src/summary/summaryGenerator.ts +16 -4
- package/src/summary/summaryManager.ts +6 -7
- package/tsconfig.cjs.json +7 -0
- package/tsconfig.json +2 -5
- package/dist/dataStores.d.ts +0 -151
- package/dist/dataStores.d.ts.map +0 -1
- package/dist/dataStores.js.map +0 -1
- package/dist/deltaManagerProxyBase.d.ts.map +0 -1
- package/dist/deltaManagerProxyBase.js +0 -77
- package/dist/deltaManagerProxyBase.js.map +0 -1
- package/lib/batchTracker.d.mts.map +0 -1
- package/lib/batchTracker.mjs.map +0 -1
- package/lib/blobManager.d.mts.map +0 -1
- package/lib/blobManager.mjs.map +0 -1
- package/lib/connectionTelemetry.d.mts.map +0 -1
- package/lib/connectionTelemetry.mjs.map +0 -1
- package/lib/containerHandleContext.d.mts.map +0 -1
- package/lib/containerHandleContext.mjs.map +0 -1
- package/lib/containerRuntime.d.mts.map +0 -1
- package/lib/containerRuntime.mjs.map +0 -1
- package/lib/dataStore.d.mts.map +0 -1
- package/lib/dataStore.mjs.map +0 -1
- package/lib/dataStoreContext.d.mts.map +0 -1
- package/lib/dataStoreContext.mjs.map +0 -1
- package/lib/dataStoreContexts.d.mts.map +0 -1
- package/lib/dataStoreContexts.mjs.map +0 -1
- package/lib/dataStoreRegistry.d.mts.map +0 -1
- package/lib/dataStoreRegistry.mjs.map +0 -1
- package/lib/dataStores.d.mts +0 -151
- package/lib/dataStores.d.mts.map +0 -1
- package/lib/dataStores.mjs.map +0 -1
- package/lib/deltaManagerProxyBase.d.mts +0 -35
- package/lib/deltaManagerProxyBase.d.mts.map +0 -1
- package/lib/deltaManagerProxyBase.mjs +0 -73
- package/lib/deltaManagerProxyBase.mjs.map +0 -1
- package/lib/deltaManagerSummarizerProxy.d.mts +0 -19
- package/lib/deltaManagerSummarizerProxy.d.mts.map +0 -1
- package/lib/deltaManagerSummarizerProxy.mjs +0 -38
- package/lib/deltaManagerSummarizerProxy.mjs.map +0 -1
- package/lib/deltaScheduler.d.mts.map +0 -1
- package/lib/deltaScheduler.mjs.map +0 -1
- package/lib/error.d.mts.map +0 -1
- package/lib/error.mjs.map +0 -1
- package/lib/gc/garbageCollection.d.mts.map +0 -1
- package/lib/gc/garbageCollection.mjs.map +0 -1
- package/lib/gc/gcConfigs.d.mts.map +0 -1
- package/lib/gc/gcConfigs.mjs.map +0 -1
- package/lib/gc/gcDefinitions.d.mts.map +0 -1
- package/lib/gc/gcDefinitions.mjs.map +0 -1
- package/lib/gc/gcHelpers.mjs.map +0 -1
- package/lib/gc/gcReferenceGraphAlgorithm.d.mts.map +0 -1
- package/lib/gc/gcReferenceGraphAlgorithm.mjs.map +0 -1
- package/lib/gc/gcSummaryDefinitions.d.mts.map +0 -1
- package/lib/gc/gcSummaryDefinitions.mjs.map +0 -1
- package/lib/gc/gcSummaryStateTracker.d.mts.map +0 -1
- package/lib/gc/gcSummaryStateTracker.mjs.map +0 -1
- package/lib/gc/gcTelemetry.d.mts.map +0 -1
- package/lib/gc/gcTelemetry.mjs.map +0 -1
- package/lib/gc/gcUnreferencedStateTracker.d.mts.map +0 -1
- package/lib/gc/gcUnreferencedStateTracker.mjs.map +0 -1
- package/lib/gc/index.d.mts +0 -13
- package/lib/gc/index.d.mts.map +0 -1
- package/lib/gc/index.mjs.map +0 -1
- package/lib/index.d.mts.map +0 -1
- package/lib/index.mjs +0 -25
- package/lib/index.mjs.map +0 -1
- package/lib/messageTypes.d.mts.map +0 -1
- package/lib/messageTypes.mjs.map +0 -1
- package/lib/metadata.d.mts.map +0 -1
- package/lib/metadata.mjs.map +0 -1
- package/lib/opLifecycle/batchManager.d.mts.map +0 -1
- package/lib/opLifecycle/batchManager.mjs.map +0 -1
- package/lib/opLifecycle/definitions.d.mts.map +0 -1
- package/lib/opLifecycle/definitions.mjs.map +0 -1
- package/lib/opLifecycle/index.d.mts +0 -13
- package/lib/opLifecycle/index.d.mts.map +0 -1
- package/lib/opLifecycle/index.mjs +0 -12
- package/lib/opLifecycle/index.mjs.map +0 -1
- package/lib/opLifecycle/opCompressor.d.mts.map +0 -1
- package/lib/opLifecycle/opCompressor.mjs.map +0 -1
- package/lib/opLifecycle/opDecompressor.d.mts.map +0 -1
- package/lib/opLifecycle/opDecompressor.mjs.map +0 -1
- package/lib/opLifecycle/opGroupingManager.d.mts.map +0 -1
- package/lib/opLifecycle/opGroupingManager.mjs.map +0 -1
- package/lib/opLifecycle/opSplitter.d.mts.map +0 -1
- package/lib/opLifecycle/opSplitter.mjs.map +0 -1
- package/lib/opLifecycle/outbox.d.mts.map +0 -1
- package/lib/opLifecycle/outbox.mjs.map +0 -1
- package/lib/opLifecycle/remoteMessageProcessor.d.mts.map +0 -1
- package/lib/opLifecycle/remoteMessageProcessor.mjs.map +0 -1
- package/lib/opProperties.d.mts.map +0 -1
- package/lib/opProperties.mjs.map +0 -1
- package/lib/packageVersion.d.mts.map +0 -1
- package/lib/packageVersion.mjs.map +0 -1
- package/lib/pendingStateManager.d.mts.map +0 -1
- package/lib/pendingStateManager.mjs.map +0 -1
- package/lib/scheduleManager.d.mts.map +0 -1
- package/lib/scheduleManager.mjs.map +0 -1
- package/lib/storageServiceWithAttachBlobs.d.mts.map +0 -1
- package/lib/storageServiceWithAttachBlobs.mjs.map +0 -1
- package/lib/summary/index.d.mts.map +0 -1
- package/lib/summary/index.mjs.map +0 -1
- package/lib/summary/orderedClientElection.d.mts.map +0 -1
- package/lib/summary/orderedClientElection.mjs.map +0 -1
- package/lib/summary/runWhileConnectedCoordinator.d.mts.map +0 -1
- package/lib/summary/runWhileConnectedCoordinator.mjs.map +0 -1
- package/lib/summary/runningSummarizer.d.mts.map +0 -1
- package/lib/summary/runningSummarizer.mjs.map +0 -1
- package/lib/summary/summarizer.d.mts.map +0 -1
- package/lib/summary/summarizer.mjs.map +0 -1
- package/lib/summary/summarizerClientElection.d.mts.map +0 -1
- package/lib/summary/summarizerClientElection.mjs.map +0 -1
- package/lib/summary/summarizerHeuristics.d.mts.map +0 -1
- package/lib/summary/summarizerHeuristics.mjs.map +0 -1
- package/lib/summary/summarizerNode/index.d.mts.map +0 -1
- package/lib/summary/summarizerNode/index.mjs +0 -7
- package/lib/summary/summarizerNode/index.mjs.map +0 -1
- package/lib/summary/summarizerNode/summarizerNode.d.mts.map +0 -1
- package/lib/summary/summarizerNode/summarizerNode.mjs.map +0 -1
- package/lib/summary/summarizerNode/summarizerNodeUtils.d.mts.map +0 -1
- package/lib/summary/summarizerNode/summarizerNodeUtils.mjs.map +0 -1
- package/lib/summary/summarizerNode/summarizerNodeWithGc.d.mts.map +0 -1
- package/lib/summary/summarizerNode/summarizerNodeWithGc.mjs.map +0 -1
- package/lib/summary/summarizerTypes.d.mts.map +0 -1
- package/lib/summary/summarizerTypes.mjs.map +0 -1
- package/lib/summary/summaryCollection.d.mts.map +0 -1
- package/lib/summary/summaryCollection.mjs.map +0 -1
- package/lib/summary/summaryFormat.d.mts.map +0 -1
- package/lib/summary/summaryFormat.mjs.map +0 -1
- package/lib/summary/summaryGenerator.d.mts.map +0 -1
- package/lib/summary/summaryGenerator.mjs.map +0 -1
- package/lib/summary/summaryManager.d.mts.map +0 -1
- package/lib/summary/summaryManager.mjs.map +0 -1
- package/lib/throttler.d.mts.map +0 -1
- package/lib/throttler.mjs.map +0 -1
- package/src/deltaManagerProxyBase.ts +0 -111
|
@@ -1,14 +1,16 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { AliasResult } from '@fluidframework/runtime-definitions';
|
|
2
2
|
import { AttachState } from '@fluidframework/container-definitions';
|
|
3
3
|
import { ContainerWarning } from '@fluidframework/container-definitions';
|
|
4
|
+
import { CreateChildSummarizerNodeFn } from '@fluidframework/runtime-definitions';
|
|
5
|
+
import { CreateChildSummarizerNodeParam } from '@fluidframework/runtime-definitions';
|
|
4
6
|
import { FluidDataStoreRegistryEntry } from '@fluidframework/runtime-definitions';
|
|
5
7
|
import { FluidObject } from '@fluidframework/core-interfaces';
|
|
6
8
|
import { FlushMode } from '@fluidframework/runtime-definitions';
|
|
7
|
-
import { generateStableId } from '@fluidframework/id-compressor';
|
|
8
9
|
import { IAudience } from '@fluidframework/container-definitions';
|
|
9
10
|
import { IClientDetails } from '@fluidframework/protocol-definitions';
|
|
10
11
|
import { IContainerContext } from '@fluidframework/container-definitions';
|
|
11
12
|
import { IContainerRuntime } from '@fluidframework/container-runtime-definitions';
|
|
13
|
+
import { IContainerRuntimeBase } from '@fluidframework/runtime-definitions';
|
|
12
14
|
import { IContainerRuntimeEvents } from '@fluidframework/container-runtime-definitions';
|
|
13
15
|
import { ICriticalContainerError } from '@fluidframework/container-definitions';
|
|
14
16
|
import { IDataStore } from '@fluidframework/runtime-definitions';
|
|
@@ -19,15 +21,20 @@ import { IDocumentStorageService } from '@fluidframework/driver-definitions';
|
|
|
19
21
|
import { IEnvelope } from '@fluidframework/runtime-definitions';
|
|
20
22
|
import { IEvent } from '@fluidframework/core-interfaces';
|
|
21
23
|
import { IEventProvider } from '@fluidframework/core-interfaces';
|
|
24
|
+
import { IFluidDataStoreChannel } from '@fluidframework/runtime-definitions';
|
|
25
|
+
import { IFluidDataStoreContext } from '@fluidframework/runtime-definitions';
|
|
22
26
|
import { IFluidDataStoreContextDetached } from '@fluidframework/runtime-definitions';
|
|
27
|
+
import { IFluidDataStoreFactory } from '@fluidframework/runtime-definitions';
|
|
23
28
|
import { IFluidDataStoreRegistry } from '@fluidframework/runtime-definitions';
|
|
24
29
|
import { IFluidHandle } from '@fluidframework/core-interfaces';
|
|
25
30
|
import { IFluidHandleContext } from '@fluidframework/core-interfaces';
|
|
31
|
+
import { IFluidParentContext } from '@fluidframework/runtime-definitions';
|
|
26
32
|
import { IGarbageCollectionData } from '@fluidframework/runtime-definitions';
|
|
33
|
+
import { IGarbageCollectionDetailsBase } from '@fluidframework/runtime-definitions';
|
|
27
34
|
import { IGetPendingLocalStateProps } from '@fluidframework/container-definitions';
|
|
28
35
|
import type { IIdCompressor } from '@fluidframework/id-compressor';
|
|
29
36
|
import type { IIdCompressorCore } from '@fluidframework/id-compressor';
|
|
30
|
-
import {
|
|
37
|
+
import { IInboundSignalMessage } from '@fluidframework/runtime-definitions';
|
|
31
38
|
import { IProvideFluidHandleContext } from '@fluidframework/core-interfaces';
|
|
32
39
|
import { IQuorumClients } from '@fluidframework/protocol-definitions';
|
|
33
40
|
import { IRequest } from '@fluidframework/core-interfaces';
|
|
@@ -35,17 +42,22 @@ import { IResponse } from '@fluidframework/core-interfaces';
|
|
|
35
42
|
import { IRuntime } from '@fluidframework/container-definitions';
|
|
36
43
|
import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
|
|
37
44
|
import { ISignalMessage } from '@fluidframework/protocol-definitions';
|
|
38
|
-
import {
|
|
45
|
+
import { ISnapshotTree } from '@fluidframework/protocol-definitions';
|
|
46
|
+
import { ISummarizeResult } from '@fluidframework/runtime-definitions';
|
|
47
|
+
import { ISummarizerNodeWithGC } from '@fluidframework/runtime-definitions';
|
|
39
48
|
import { ISummaryAck } from '@fluidframework/protocol-definitions';
|
|
40
49
|
import { ISummaryContent } from '@fluidframework/protocol-definitions';
|
|
41
50
|
import { ISummaryNack } from '@fluidframework/protocol-definitions';
|
|
42
51
|
import { ISummaryStats } from '@fluidframework/runtime-definitions';
|
|
43
52
|
import { ISummaryTree } from '@fluidframework/protocol-definitions';
|
|
44
53
|
import { ISummaryTreeWithStats } from '@fluidframework/runtime-definitions';
|
|
54
|
+
import { ITelemetryBaseLogger } from '@fluidframework/core-interfaces';
|
|
45
55
|
import { ITelemetryContext } from '@fluidframework/runtime-definitions';
|
|
46
56
|
import { ITelemetryLoggerExt } from '@fluidframework/telemetry-utils';
|
|
47
57
|
import { MessageType } from '@fluidframework/protocol-definitions';
|
|
58
|
+
import { MonitoringContext } from '@fluidframework/telemetry-utils';
|
|
48
59
|
import { NamedFluidDataStoreRegistryEntries } from '@fluidframework/runtime-definitions';
|
|
60
|
+
import { SummarizeInternalFn } from '@fluidframework/runtime-definitions';
|
|
49
61
|
import { TypedEventEmitter } from '@fluid-internal/client-utils';
|
|
50
62
|
|
|
51
63
|
/**
|
|
@@ -67,7 +79,179 @@ export declare const AllowInactiveRequestHeaderKey = "allowInactive";
|
|
|
67
79
|
*/
|
|
68
80
|
export declare const AllowTombstoneRequestHeaderKey = "allowTombstone";
|
|
69
81
|
|
|
70
|
-
|
|
82
|
+
/**
|
|
83
|
+
* This class encapsulates data store handling. Currently it is only used by the container runtime,
|
|
84
|
+
* but eventually could be hosted on any channel once we formalize the channel api boundary.
|
|
85
|
+
* @internal
|
|
86
|
+
*/
|
|
87
|
+
export declare class ChannelCollection implements IFluidDataStoreChannel, IDisposable {
|
|
88
|
+
protected readonly baseSnapshot: ISnapshotTree | undefined;
|
|
89
|
+
readonly parentContext: IFluidParentContext;
|
|
90
|
+
private readonly gcNodeUpdated;
|
|
91
|
+
private readonly isDataStoreDeleted;
|
|
92
|
+
private readonly aliasMap;
|
|
93
|
+
private readonly pendingAttach;
|
|
94
|
+
readonly attachOpFiredForDataStore: Set<string>;
|
|
95
|
+
protected readonly mc: MonitoringContext;
|
|
96
|
+
private readonly disposeOnce;
|
|
97
|
+
readonly entryPoint: IFluidHandle<FluidObject>;
|
|
98
|
+
readonly containerLoadStats: {
|
|
99
|
+
readonly containerLoadDataStoreCount: number;
|
|
100
|
+
readonly referencedDataStoreCount: number;
|
|
101
|
+
};
|
|
102
|
+
private dataStoresSinceLastGC;
|
|
103
|
+
private readonly containerRuntimeHandle;
|
|
104
|
+
private readonly pendingAliasMap;
|
|
105
|
+
protected readonly contexts: DataStoreContexts;
|
|
106
|
+
constructor(baseSnapshot: ISnapshotTree | undefined, parentContext: IFluidParentContext, baseLogger: ITelemetryBaseLogger, gcNodeUpdated: (nodePath: string, reason: "Loaded" | "Changed", timestampMs?: number, packagePath?: readonly string[], request?: IRequest, headerData?: RuntimeHeaderData) => void, isDataStoreDeleted: (nodePath: string) => boolean, aliasMap: Map<string, string>, provideEntryPoint: (runtime: ChannelCollection) => Promise<FluidObject>);
|
|
107
|
+
get aliases(): ReadonlyMap<string, string>;
|
|
108
|
+
get pendingAliases(): Map<string, Promise<AliasResult>>;
|
|
109
|
+
waitIfPendingAlias(maybeAlias: string): Promise<AliasResult>;
|
|
110
|
+
/** For sampling. Only log once per container */
|
|
111
|
+
private shouldSendAttachLog;
|
|
112
|
+
protected wrapContextForInnerChannel(id: string): IFluidParentContext;
|
|
113
|
+
/**
|
|
114
|
+
* IFluidDataStoreChannel.makeVisibleAndAttachGraph implementation
|
|
115
|
+
* Not clear when it would be called and what it should do.
|
|
116
|
+
* Currently this API is called by context only for root data stores.
|
|
117
|
+
*/
|
|
118
|
+
makeVisibleAndAttachGraph(): void;
|
|
119
|
+
private processAttachMessage;
|
|
120
|
+
private processAliasMessage;
|
|
121
|
+
processAliasMessageCore(internalId: string, alias: string): boolean;
|
|
122
|
+
private alreadyProcessed;
|
|
123
|
+
/** Package up the context's attach summary etc into an IAttachMessage */
|
|
124
|
+
private generateAttachMessage;
|
|
125
|
+
/**
|
|
126
|
+
* Make the data store locally visible in the container graph by moving the data store context from unbound to
|
|
127
|
+
* bound list and submitting the attach message. This data store can now be reached from the root.
|
|
128
|
+
* @param id - The id of the data store context to make visible.
|
|
129
|
+
*/
|
|
130
|
+
private makeDataStoreLocallyVisible;
|
|
131
|
+
protected submitAttachChannelOp(localContext: LocalFluidDataStoreContext): void;
|
|
132
|
+
/**
|
|
133
|
+
* Generate compact internal DataStore ID.
|
|
134
|
+
*
|
|
135
|
+
* A note about namespace and name collisions:
|
|
136
|
+
* This code assumes that that's the only way to generate internal IDs, and that it's Ok for this namespace to overlap with
|
|
137
|
+
* user-provided alias names namespace.
|
|
138
|
+
* There are two scenarios where it could cause trouble:
|
|
139
|
+
* 1) Old files, where (already removed) CreateRoot*DataStore*() API was used, and thus internal name of data store
|
|
140
|
+
* was provided by user. Such files may experience name collision with future data stores that receive a name generated
|
|
141
|
+
* by this function.
|
|
142
|
+
* 2) Much less likely, but if it happen that internal ID (generated by this function) is exactly the same as alias name
|
|
143
|
+
* that user might use in the future, them ContainerRuntime.getAliasedDataStoreEntryPoint() or
|
|
144
|
+
* ContainerRuntime.getDataStoreFromRequest() could return a data store with internalID matching user request, even though
|
|
145
|
+
* user expected some other data store (that would receive alias later).
|
|
146
|
+
* Please note that above mentioned functions have the implementation they have (allowing #2) due to #1.
|
|
147
|
+
*/
|
|
148
|
+
protected createDataStoreId(): string;
|
|
149
|
+
createDetachedDataStore(pkg: Readonly<string[]>, loadingGroupId?: string): IFluidDataStoreContextDetached;
|
|
150
|
+
createDataStoreContext(pkg: Readonly<string[]>, props?: any, loadingGroupId?: string): IFluidDataStoreContextInternal;
|
|
151
|
+
protected createContext<T extends LocalFluidDataStoreContext>(id: string, pkg: Readonly<string[]>, contextCtor: new (props: ILocalDetachedFluidDataStoreContextProps) => T, createProps?: any, loadingGroupId?: string): T;
|
|
152
|
+
get disposed(): boolean;
|
|
153
|
+
readonly dispose: () => void;
|
|
154
|
+
reSubmit(type: string, content: any, localOpMetadata: unknown): void;
|
|
155
|
+
protected reSubmitChannelOp(type: string, content: any, localOpMetadata: unknown): void;
|
|
156
|
+
rollback(type: string, content: any, localOpMetadata: unknown): void;
|
|
157
|
+
applyStashedOp(content: unknown): Promise<unknown>;
|
|
158
|
+
protected applyStashedChannelChannelOp(envelope: IEnvelope): Promise<unknown>;
|
|
159
|
+
private applyStashedAttachOp;
|
|
160
|
+
process(message: ISequencedDocumentMessage, local: boolean, localMessageMetadata: unknown, addedOutboundReference?: (fromNodePath: string, toNodePath: string) => void): void;
|
|
161
|
+
protected processChannelOp(address: string, message: ISequencedDocumentMessage, local: boolean, localMessageMetadata: unknown): void;
|
|
162
|
+
getDataStore(id: string, requestHeaderData: RuntimeHeaderData): Promise<IFluidDataStoreContextInternal>;
|
|
163
|
+
/**
|
|
164
|
+
* Returns the data store requested with the given id if available. Otherwise, returns undefined.
|
|
165
|
+
*/
|
|
166
|
+
getDataStoreIfAvailable(id: string, requestHeaderData: RuntimeHeaderData): Promise<IFluidDataStoreContextInternal | undefined>;
|
|
167
|
+
/**
|
|
168
|
+
* Checks if the data store has been deleted by GC. If so, log an error.
|
|
169
|
+
* @param id - The data store's id.
|
|
170
|
+
* @param context - The data store context.
|
|
171
|
+
* @param callSite - The function name this is called from.
|
|
172
|
+
* @param requestHeaderData - The request header information to log if the data store is deleted.
|
|
173
|
+
* @returns true if the data store is deleted. Otherwise, returns false.
|
|
174
|
+
*/
|
|
175
|
+
private checkAndLogIfDeleted;
|
|
176
|
+
processSignal(messageArg: IInboundSignalMessage, local: boolean): void;
|
|
177
|
+
setConnectionState(connected: boolean, clientId?: string): void;
|
|
178
|
+
setAttachState(attachState: AttachState.Attaching | AttachState.Attached): void;
|
|
179
|
+
get size(): number;
|
|
180
|
+
summarize(fullTree: boolean, trackState: boolean, telemetryContext?: ITelemetryContext): Promise<ISummaryTreeWithStats>;
|
|
181
|
+
/**
|
|
182
|
+
* Create a summary. Used when attaching or serializing a detached container.
|
|
183
|
+
*/
|
|
184
|
+
getAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;
|
|
185
|
+
/**
|
|
186
|
+
* Before GC runs, called by the garbage collector to update any pending GC state.
|
|
187
|
+
* The garbage collector needs to know all outbound references that are added. Since root data stores are not
|
|
188
|
+
* explicitly marked as referenced, notify GC of new root data stores that were added since the last GC run.
|
|
189
|
+
*/
|
|
190
|
+
updateStateBeforeGC(): Promise<void>;
|
|
191
|
+
/**
|
|
192
|
+
* Generates data used for garbage collection. It does the following:
|
|
193
|
+
*
|
|
194
|
+
* 1. Calls into each child data store context to get its GC data.
|
|
195
|
+
*
|
|
196
|
+
* 2. Prefixes the child context's id to the GC nodes in the child's GC data. This makes sure that the node can be
|
|
197
|
+
* identified as belonging to the child.
|
|
198
|
+
*
|
|
199
|
+
* 3. Adds a GC node for this channel to the nodes received from the children. All these nodes together represent
|
|
200
|
+
* the GC data of this channel.
|
|
201
|
+
*
|
|
202
|
+
* @param fullGC - true to bypass optimizations and force full generation of GC data.
|
|
203
|
+
*/
|
|
204
|
+
getGCData(fullGC?: boolean): Promise<IGarbageCollectionData>;
|
|
205
|
+
/**
|
|
206
|
+
* After GC has run, called to notify this Container's data stores of routes that are used in it.
|
|
207
|
+
* @param usedRoutes - The routes that are used in all data stores in this Container.
|
|
208
|
+
*/
|
|
209
|
+
updateUsedRoutes(usedRoutes: readonly string[]): void;
|
|
210
|
+
deleteChild(dataStoreId: string): void;
|
|
211
|
+
/**
|
|
212
|
+
* Delete data stores and its objects that are sweep ready.
|
|
213
|
+
* @param sweepReadyDataStoreRoutes - The routes of data stores and its objects that are sweep ready and should
|
|
214
|
+
* be deleted.
|
|
215
|
+
* @returns The routes of data stores and its objects that were deleted.
|
|
216
|
+
*/
|
|
217
|
+
deleteSweepReadyNodes(sweepReadyDataStoreRoutes: readonly string[]): readonly string[];
|
|
218
|
+
/**
|
|
219
|
+
* This is called to update objects whose routes are tombstones.
|
|
220
|
+
*
|
|
221
|
+
* A Tombstoned object has been unreferenced long enough that GC knows it won't be referenced again.
|
|
222
|
+
* Tombstoned objects are eventually deleted by GC.
|
|
223
|
+
*
|
|
224
|
+
* @param tombstonedRoutes - The routes that are tombstones in all data stores in this Container.
|
|
225
|
+
*/
|
|
226
|
+
updateTombstonedRoutes(tombstonedRoutes: readonly string[]): void;
|
|
227
|
+
/**
|
|
228
|
+
* Returns the outbound routes of this channel. Only root data stores are considered referenced and their paths are
|
|
229
|
+
* part of outbound routes.
|
|
230
|
+
*/
|
|
231
|
+
private getOutboundRoutes;
|
|
232
|
+
/**
|
|
233
|
+
* Called by GC to retrieve the package path of a data store node with the given path.
|
|
234
|
+
*/
|
|
235
|
+
getDataStorePackagePath(nodePath: string): Promise<readonly string[] | undefined>;
|
|
236
|
+
/**
|
|
237
|
+
* Called by GC to determine if a node is for a data store or for an object within a data store (for e.g. DDS).
|
|
238
|
+
* @returns the GC node type if the node belongs to a data store or object within data store, undefined otherwise.
|
|
239
|
+
*/
|
|
240
|
+
getGCNodeType(nodePath: string): GCNodeType | undefined;
|
|
241
|
+
internalId(maybeAlias: string): string;
|
|
242
|
+
request(request: IRequest): Promise<IResponse>;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
/** @internal */
|
|
246
|
+
export declare class ChannelCollectionFactory<T extends ChannelCollection = ChannelCollection> implements IFluidDataStoreFactory {
|
|
247
|
+
private readonly provideEntryPoint;
|
|
248
|
+
private readonly ctor;
|
|
249
|
+
readonly type = "ChannelCollectionChannel";
|
|
250
|
+
IFluidDataStoreRegistry: IFluidDataStoreRegistry;
|
|
251
|
+
constructor(registryEntries: NamedFluidDataStoreRegistryEntries, provideEntryPoint: (runtime: IFluidDataStoreChannel) => Promise<FluidObject>, ctor: (...args: ConstructorParameters<typeof ChannelCollection>) => T);
|
|
252
|
+
get IFluidDataStoreFactory(): this;
|
|
253
|
+
instantiateDataStore(context: IFluidDataStoreContext, _existing: boolean): Promise<IFluidDataStoreChannel>;
|
|
254
|
+
}
|
|
71
255
|
|
|
72
256
|
/**
|
|
73
257
|
* How should an older client handle an unrecognized remote op type?
|
|
@@ -118,10 +302,13 @@ export declare enum ContainerMessageType {
|
|
|
118
302
|
*/
|
|
119
303
|
export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntimeEvents & ISummarizerEvents> implements IContainerRuntime, IRuntime, ISummarizerRuntime, ISummarizerInternalsProvider, IProvideFluidHandleContext {
|
|
120
304
|
private readonly registry;
|
|
305
|
+
private readonly metadata;
|
|
121
306
|
private readonly runtimeOptions;
|
|
122
307
|
private readonly containerScope;
|
|
123
308
|
readonly logger: ITelemetryLoggerExt;
|
|
124
309
|
private readonly _storage;
|
|
310
|
+
private readonly createIdCompressor;
|
|
311
|
+
private readonly idCompressorMode;
|
|
125
312
|
private readonly requestHandler?;
|
|
126
313
|
private readonly summaryConfiguration;
|
|
127
314
|
/**
|
|
@@ -150,12 +337,13 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
150
337
|
requestHandler?: (request: IRequest, runtime: IContainerRuntime) => Promise<IResponse>;
|
|
151
338
|
provideEntryPoint: (containerRuntime: IContainerRuntime) => Promise<FluidObject>;
|
|
152
339
|
}): Promise<ContainerRuntime>;
|
|
153
|
-
readonly options:
|
|
340
|
+
readonly options: Record<string | number, any>;
|
|
154
341
|
private imminentClosure;
|
|
155
342
|
private readonly _getClientId;
|
|
156
343
|
get clientId(): string | undefined;
|
|
157
344
|
readonly clientDetails: IClientDetails;
|
|
158
345
|
get storage(): IDocumentStorageService;
|
|
346
|
+
get containerRuntime(): this;
|
|
159
347
|
private readonly submitFn;
|
|
160
348
|
/**
|
|
161
349
|
* Although current IContainerContext guarantees submitBatchFn, it is not available on older loaders.
|
|
@@ -170,7 +358,26 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
170
358
|
get IFluidDataStoreRegistry(): IFluidDataStoreRegistry;
|
|
171
359
|
private readonly _getAttachState;
|
|
172
360
|
get attachState(): AttachState;
|
|
173
|
-
|
|
361
|
+
private _idCompressor;
|
|
362
|
+
private pendingIdCompressorOps;
|
|
363
|
+
private readonly skipSavedCompressorOps;
|
|
364
|
+
/**
|
|
365
|
+
* See IContainerRuntimeBase.idCompressor() for details.
|
|
366
|
+
*/
|
|
367
|
+
get idCompressor(): (IIdCompressor & IIdCompressorCore) | undefined;
|
|
368
|
+
/**
|
|
369
|
+
* True if we have ID compressor loading in-flight (async operation). Useful only for
|
|
370
|
+
* this.idCompressorMode === "delayed" mode
|
|
371
|
+
*/
|
|
372
|
+
protected compressorLoadInitiated: boolean;
|
|
373
|
+
/**
|
|
374
|
+
* See IContainerRuntimeBase.generateDocumentUniqueId() for details.
|
|
375
|
+
*/
|
|
376
|
+
generateDocumentUniqueId(): string | (number & {
|
|
377
|
+
readonly SessionUnique: "cea55054-6b82-4cbf-ad19-1fa645ea3b3e";
|
|
378
|
+
} & {
|
|
379
|
+
readonly OpNormalized: "9209432d-a959-4df7-b2ad-767ead4dbcae";
|
|
380
|
+
});
|
|
174
381
|
get IFluidHandleContext(): IFluidHandleContext;
|
|
175
382
|
private readonly handleContext;
|
|
176
383
|
/**
|
|
@@ -253,15 +460,13 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
253
460
|
private readonly pendingStateManager;
|
|
254
461
|
private readonly outbox;
|
|
255
462
|
private readonly garbageCollector;
|
|
256
|
-
private readonly
|
|
463
|
+
private readonly channelCollection;
|
|
257
464
|
private readonly remoteMessageProcessor;
|
|
258
465
|
/** The last message processed at the time of the last summary. */
|
|
259
466
|
private messageAtLastSummary;
|
|
260
467
|
private get summarizer();
|
|
261
468
|
private readonly summariesDisabled;
|
|
262
469
|
private isSummariesDisabled;
|
|
263
|
-
private readonly heuristicsDisabled;
|
|
264
|
-
private isHeuristicsDisabled;
|
|
265
470
|
private readonly maxOpsSinceLastSummary;
|
|
266
471
|
private getMaxOpsSinceLastSummary;
|
|
267
472
|
private readonly initialSummarizerDelayMs;
|
|
@@ -281,10 +486,6 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
281
486
|
* ! Note: should not be used for anything other than telemetry and is not considered a stable GUID
|
|
282
487
|
*/
|
|
283
488
|
private readonly telemetryDocumentId;
|
|
284
|
-
/**
|
|
285
|
-
* If true, the runtime has access to an IdCompressor
|
|
286
|
-
*/
|
|
287
|
-
private readonly idCompressorEnabled;
|
|
288
489
|
/**
|
|
289
490
|
* Whether this client is the summarizer client itself (type is summarizerClientType)
|
|
290
491
|
*/
|
|
@@ -293,13 +494,41 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
293
494
|
* The id of the version used to initially load this runtime, or undefined if it's newly created.
|
|
294
495
|
*/
|
|
295
496
|
private readonly loadedFromVersionId;
|
|
497
|
+
/**
|
|
498
|
+
* It a cache for holding mapping for loading groupIds with its snapshot from the service. Add expiry policy of 1 minute.
|
|
499
|
+
* Starting with 1 min and based on recorded usage we can tweak it later on.
|
|
500
|
+
*/
|
|
501
|
+
private readonly snapshotCacheForLoadingGroupIds;
|
|
296
502
|
/***/
|
|
297
|
-
protected constructor(context: IContainerContext, registry: IFluidDataStoreRegistry, metadata: IContainerRuntimeMetadata | undefined, electedSummarizerData: ISerializedElection | undefined, chunks: [string, string[]][], dataStoreAliasMap: [string, string][], runtimeOptions: Readonly<Required<IContainerRuntimeOptions>>, containerScope: FluidObject, logger: ITelemetryLoggerExt, existing: boolean, blobManagerSnapshot: IBlobManagerLoadInfo, _storage: IDocumentStorageService,
|
|
503
|
+
protected constructor(context: IContainerContext, registry: IFluidDataStoreRegistry, metadata: IContainerRuntimeMetadata | undefined, electedSummarizerData: ISerializedElection | undefined, chunks: [string, string[]][], dataStoreAliasMap: [string, string][], runtimeOptions: Readonly<Required<IContainerRuntimeOptions>>, containerScope: FluidObject, logger: ITelemetryLoggerExt, existing: boolean, blobManagerSnapshot: IBlobManagerLoadInfo, _storage: IDocumentStorageService, createIdCompressor: () => Promise<IIdCompressor & IIdCompressorCore>, idCompressorMode: IdCompressorMode, provideEntryPoint: (containerRuntime: IContainerRuntime) => Promise<FluidObject>, requestHandler?: ((request: IRequest, runtime: IContainerRuntime) => Promise<IResponse>) | undefined, summaryConfiguration?: ISummaryConfiguration);
|
|
504
|
+
getCreateChildSummarizerNodeFn(id: string, createParam: CreateChildSummarizerNodeParam): (summarizeInternal: SummarizeInternalFn, getGCDataFn: (fullGC?: boolean) => Promise<IGarbageCollectionData>) => ISummarizerNodeWithGC;
|
|
505
|
+
deleteChildSummarizerNode(id: string): void;
|
|
506
|
+
makeLocallyVisible(): void;
|
|
507
|
+
setChannelDirty(address: string): void;
|
|
298
508
|
/**
|
|
299
509
|
* Initializes the state from the base snapshot this container runtime loaded from.
|
|
300
510
|
*/
|
|
301
511
|
private initializeBaseState;
|
|
302
512
|
dispose(error?: Error): void;
|
|
513
|
+
/**
|
|
514
|
+
* Api to fetch the snapshot from the service for a loadingGroupIds.
|
|
515
|
+
* @param loadingGroupIds - LoadingGroupId for which the snapshot is asked for.
|
|
516
|
+
* @param pathParts - Parts of the path, which we want to extract from the snapshot tree.
|
|
517
|
+
* @returns - snapshotTree and the sequence number of the snapshot.
|
|
518
|
+
*/
|
|
519
|
+
getSnapshotForLoadingGroupId(loadingGroupIds: string[], pathParts: string[]): Promise<{
|
|
520
|
+
snapshotTree: ISnapshotTree;
|
|
521
|
+
sequenceNumber: number;
|
|
522
|
+
}>;
|
|
523
|
+
/**
|
|
524
|
+
* Api to find a snapshot tree inside a bigger snapshot tree based on the path in the pathParts array.
|
|
525
|
+
* @param snapshotTree - snapshot tree to look into.
|
|
526
|
+
* @param pathParts - Part of the path, which we want to extract from the snapshot tree.
|
|
527
|
+
* @param hasIsolatedChannels - whether the channels are present inside ".channels" subtree. Older
|
|
528
|
+
* snapshots will not have trees inside ".channels", so check that.
|
|
529
|
+
* @returns - requested snapshot tree based on the path parts.
|
|
530
|
+
*/
|
|
531
|
+
private getSnapshotTreeForPath;
|
|
303
532
|
/**
|
|
304
533
|
* Notifies this object about the request made to the container.
|
|
305
534
|
* @param request - Request made to the handler.
|
|
@@ -317,7 +546,6 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
317
546
|
getEntryPoint(): Promise<FluidObject>;
|
|
318
547
|
private readonly entryPoint;
|
|
319
548
|
private internalId;
|
|
320
|
-
private getDataStoreFromRequest;
|
|
321
549
|
/** Adds the container's metadata to the given summary tree. */
|
|
322
550
|
private addMetadataToSummary;
|
|
323
551
|
protected addContainerStateToSummary(summaryTree: ISummaryTreeWithStats, fullTree: boolean, trackState: boolean, telemetryContext?: ITelemetryContext): void;
|
|
@@ -367,13 +595,12 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
367
595
|
* Returns undefined if no data store has been assigned the given alias.
|
|
368
596
|
*/
|
|
369
597
|
getAliasedDataStoreEntryPoint(alias: string): Promise<IFluidHandle<FluidObject> | undefined>;
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
createDataStore(pkg: string | string[], groupId?: string): Promise<IDataStore>;
|
|
598
|
+
createDetachedDataStore(pkg: Readonly<string[]>, loadingGroupId?: string): IFluidDataStoreContextDetached;
|
|
599
|
+
createDataStore(pkg: Readonly<string | string[]>, loadingGroupId?: string): Promise<IDataStore>;
|
|
373
600
|
/**
|
|
374
601
|
* @deprecated 0.16 Issue #1537, #3631
|
|
375
602
|
*/
|
|
376
|
-
_createDataStoreWithProps(pkg: string | string[]
|
|
603
|
+
_createDataStoreWithProps(pkg: Readonly<string | string[]>, props?: any): Promise<IDataStore>;
|
|
377
604
|
private canSendOps;
|
|
378
605
|
/**
|
|
379
606
|
* Are we in the middle of batching ops together?
|
|
@@ -397,13 +624,6 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
397
624
|
* @param targetClientId - When specified, the signal is only sent to the provided client id.
|
|
398
625
|
*/
|
|
399
626
|
submitSignal(type: string, content: any, targetClientId?: string): void;
|
|
400
|
-
/**
|
|
401
|
-
* Submits the signal to be sent to other clients.
|
|
402
|
-
* @param type - Type of the signal.
|
|
403
|
-
* @param content - Content of the signal.
|
|
404
|
-
* @param targetClientId - When specified, the signal is only sent to the provided client id.
|
|
405
|
-
*/
|
|
406
|
-
submitDataStoreSignal(address: string, type: string, content: any, targetClientId?: string): void;
|
|
407
627
|
setAttachState(attachState: AttachState.Attaching | AttachState.Attached): void;
|
|
408
628
|
/**
|
|
409
629
|
* Create a summary. Used when attaching or serializing a detached container.
|
|
@@ -453,15 +673,6 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
453
673
|
* @see IGarbageCollectionRuntime.updateUsedRoutes
|
|
454
674
|
*/
|
|
455
675
|
updateUsedRoutes(usedRoutes: readonly string[]): void;
|
|
456
|
-
/**
|
|
457
|
-
* This is called to update objects whose routes are unused.
|
|
458
|
-
* @param unusedRoutes - Data store and attachment blob routes that are unused in this Container.
|
|
459
|
-
*/
|
|
460
|
-
updateUnusedRoutes(unusedRoutes: readonly string[]): void;
|
|
461
|
-
/**
|
|
462
|
-
* @deprecated Replaced by deleteSweepReadyNodes.
|
|
463
|
-
*/
|
|
464
|
-
deleteUnusedNodes(unusedRoutes: readonly string[]): string[];
|
|
465
676
|
/**
|
|
466
677
|
* After GC has run and identified nodes that are sweep ready, this is called to delete the sweep ready nodes.
|
|
467
678
|
* @param sweepReadyRoutes - The routes of nodes that are sweep ready and should be deleted.
|
|
@@ -520,7 +731,11 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
520
731
|
* @param srcHandle - The handle of the node that added the reference.
|
|
521
732
|
* @param outboundHandle - The handle of the outbound node that is referenced.
|
|
522
733
|
*/
|
|
523
|
-
addedGCOutboundReference(srcHandle:
|
|
734
|
+
addedGCOutboundReference(srcHandle: {
|
|
735
|
+
absolutePath: string;
|
|
736
|
+
}, outboundHandle: {
|
|
737
|
+
absolutePath: string;
|
|
738
|
+
}): void;
|
|
524
739
|
/**
|
|
525
740
|
* Generates the summary tree, uploads it to storage, and then submits the summarize op.
|
|
526
741
|
* This is intended to be called by the summarizer, since it is the implementation of
|
|
@@ -544,10 +759,9 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
544
759
|
private get pendingMessagesCount();
|
|
545
760
|
private hasPendingMessages;
|
|
546
761
|
private updateDocumentDirtyState;
|
|
547
|
-
|
|
548
|
-
submitDataStoreAliasOp(contents: any, localOpMetadata: unknown): void;
|
|
762
|
+
submitMessage(type: ContainerMessageType.FluidDataStoreOp | ContainerMessageType.Alias | ContainerMessageType.Attach, contents: any, localOpMetadata?: unknown): void;
|
|
549
763
|
uploadBlob(blob: ArrayBufferLike, signal?: AbortSignal): Promise<IFluidHandle<ArrayBufferLike>>;
|
|
550
|
-
private
|
|
764
|
+
private submitIdAllocationOpIfNeeded;
|
|
551
765
|
private submit;
|
|
552
766
|
private scheduleFlush;
|
|
553
767
|
private submitSummaryMessage;
|
|
@@ -584,7 +798,7 @@ export declare class ContainerRuntime extends TypedEventEmitter<IContainerRuntim
|
|
|
584
798
|
* overridden via options.
|
|
585
799
|
*/
|
|
586
800
|
private fetchLatestSnapshotFromStorage;
|
|
587
|
-
getPendingLocalState(props?: IGetPendingLocalStateProps):
|
|
801
|
+
getPendingLocalState(props?: IGetPendingLocalStateProps): unknown;
|
|
588
802
|
summarizeOnDemand(options: IOnDemandSummarizeOptions): ISummarizeResults;
|
|
589
803
|
enqueueSummarize(options: IEnqueueSummarizeOptions): EnqueueSummarizeResult;
|
|
590
804
|
/**
|
|
@@ -615,6 +829,65 @@ export declare interface ContainerRuntimeMessage {
|
|
|
615
829
|
compatDetails?: IContainerRuntimeMessageCompatDetails;
|
|
616
830
|
}
|
|
617
831
|
|
|
832
|
+
/** @internal */
|
|
833
|
+
export declare class DataStoreContexts implements Iterable<[string, FluidDataStoreContext]>, IDisposable {
|
|
834
|
+
private readonly notBoundContexts;
|
|
835
|
+
/** Attached and loaded context proxies */
|
|
836
|
+
private readonly _contexts;
|
|
837
|
+
/**
|
|
838
|
+
* List of pending context waiting either to be bound or to arrive from another client.
|
|
839
|
+
* This covers the case where a local context has been created but not yet bound,
|
|
840
|
+
* or the case where a client knows a store will exist and is waiting on its creation,
|
|
841
|
+
* so that a caller may await the deferred's promise until such a time as the context is fully ready.
|
|
842
|
+
* This is a superset of _contexts, since contexts remain here once the Deferred resolves.
|
|
843
|
+
*/
|
|
844
|
+
private readonly deferredContexts;
|
|
845
|
+
private readonly disposeOnce;
|
|
846
|
+
private readonly _logger;
|
|
847
|
+
constructor(baseLogger: ITelemetryBaseLogger);
|
|
848
|
+
[Symbol.iterator](): Iterator<[string, FluidDataStoreContext]>;
|
|
849
|
+
get size(): number;
|
|
850
|
+
get disposed(): boolean;
|
|
851
|
+
readonly dispose: () => void;
|
|
852
|
+
notBoundLength(): number;
|
|
853
|
+
isNotBound(id: string): boolean;
|
|
854
|
+
has(id: string): boolean;
|
|
855
|
+
get(id: string): FluidDataStoreContext | undefined;
|
|
856
|
+
delete(id: string): boolean;
|
|
857
|
+
/**
|
|
858
|
+
* Return the unbound local context with the given id,
|
|
859
|
+
* or undefined if it's not found or not unbound.
|
|
860
|
+
*/
|
|
861
|
+
getUnbound(id: string): LocalFluidDataStoreContext | undefined;
|
|
862
|
+
/**
|
|
863
|
+
* Add the given context, marking it as to-be-bound
|
|
864
|
+
*/
|
|
865
|
+
addUnbound(context: LocalFluidDataStoreContext): void;
|
|
866
|
+
/**
|
|
867
|
+
* Get the context with the given id, once it exists locally and is attached.
|
|
868
|
+
* e.g. If created locally, it must be bound, or if created remotely then it's fine as soon as it's sync'd in.
|
|
869
|
+
* @param id - The id of the context to get
|
|
870
|
+
* @param wait - If false, return undefined if the context isn't present and ready now. Otherwise, wait for it.
|
|
871
|
+
*/
|
|
872
|
+
getBoundOrRemoted(id: string, wait: boolean): Promise<FluidDataStoreContext | undefined>;
|
|
873
|
+
private ensureDeferred;
|
|
874
|
+
/**
|
|
875
|
+
* Update this context as bound
|
|
876
|
+
*/
|
|
877
|
+
bind(id: string): void;
|
|
878
|
+
/**
|
|
879
|
+
* Triggers the deferred to resolve, indicating the context is not local-only
|
|
880
|
+
* @param id - The id of the context to resolve to
|
|
881
|
+
*/
|
|
882
|
+
private resolveDeferred;
|
|
883
|
+
/**
|
|
884
|
+
* Add the given context, marking it as not local-only.
|
|
885
|
+
* This could be because it's a local context that's been bound, or because it's a remote context.
|
|
886
|
+
* @param context - The context to add
|
|
887
|
+
*/
|
|
888
|
+
addBoundOrRemoted(context: FluidDataStoreContext): void;
|
|
889
|
+
}
|
|
890
|
+
|
|
618
891
|
/**
|
|
619
892
|
* @alpha
|
|
620
893
|
*/
|
|
@@ -625,7 +898,7 @@ export declare const DefaultSummaryConfiguration: ISummaryConfiguration;
|
|
|
625
898
|
*
|
|
626
899
|
* @internal
|
|
627
900
|
*/
|
|
628
|
-
export declare function detectOutboundReferences(
|
|
901
|
+
export declare function detectOutboundReferences(address: string, contents: unknown, addedOutboundReference: (fromNodePath: string, toNodePath: string) => void): void;
|
|
629
902
|
|
|
630
903
|
/**
|
|
631
904
|
* @alpha
|
|
@@ -654,6 +927,246 @@ export declare type EnqueueSummarizeResult = (ISummarizeResults & {
|
|
|
654
927
|
readonly overridden?: undefined;
|
|
655
928
|
};
|
|
656
929
|
|
|
930
|
+
/**
|
|
931
|
+
* Represents the context for the store. This context is passed to the store runtime.
|
|
932
|
+
* @internal
|
|
933
|
+
*/
|
|
934
|
+
export declare abstract class FluidDataStoreContext extends TypedEventEmitter<IFluidDataStoreContextEvents> implements IFluidDataStoreContextInternal, IFluidParentContext, IDisposable {
|
|
935
|
+
private readonly existing;
|
|
936
|
+
readonly isLocalDataStore: boolean;
|
|
937
|
+
private readonly makeLocallyVisibleFn;
|
|
938
|
+
get packagePath(): readonly string[];
|
|
939
|
+
get options(): Record<string | number, any>;
|
|
940
|
+
get clientId(): string | undefined;
|
|
941
|
+
get clientDetails(): IClientDetails;
|
|
942
|
+
get logger(): ITelemetryBaseLogger;
|
|
943
|
+
get deltaManager(): IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>;
|
|
944
|
+
get connected(): boolean;
|
|
945
|
+
get IFluidHandleContext(): IFluidHandleContext;
|
|
946
|
+
get containerRuntime(): IContainerRuntimeBase;
|
|
947
|
+
ensureNoDataModelChanges<T>(callback: () => T): T;
|
|
948
|
+
get isLoaded(): boolean;
|
|
949
|
+
get baseSnapshot(): ISnapshotTree | undefined;
|
|
950
|
+
get idCompressor(): IIdCompressor | undefined;
|
|
951
|
+
private _disposed;
|
|
952
|
+
get disposed(): boolean;
|
|
953
|
+
/**
|
|
954
|
+
* A Tombstoned object has been unreferenced long enough that GC knows it won't be referenced again.
|
|
955
|
+
* Tombstoned objects are eventually deleted by GC.
|
|
956
|
+
*/
|
|
957
|
+
private _tombstoned;
|
|
958
|
+
get tombstoned(): boolean;
|
|
959
|
+
/** If true, throw an error when a tombstone data store is used. */
|
|
960
|
+
readonly gcThrowOnTombstoneUsage: boolean;
|
|
961
|
+
readonly gcTombstoneEnforcementAllowed: boolean;
|
|
962
|
+
/** If true, this means that this data store context and its children have been removed from the runtime */
|
|
963
|
+
protected deleted: boolean;
|
|
964
|
+
get attachState(): AttachState;
|
|
965
|
+
get IFluidDataStoreRegistry(): IFluidDataStoreRegistry | undefined;
|
|
966
|
+
private baseSnapshotSequenceNumber;
|
|
967
|
+
/**
|
|
968
|
+
* A datastore is considered as root if it
|
|
969
|
+
* 1. is root in memory - see isInMemoryRoot
|
|
970
|
+
* 2. is root as part of the base snapshot that the datastore loaded from
|
|
971
|
+
* @returns whether a datastore is root
|
|
972
|
+
*/
|
|
973
|
+
isRoot(): Promise<boolean>;
|
|
974
|
+
/**
|
|
975
|
+
* There are 3 states where isInMemoryRoot needs to be true
|
|
976
|
+
* 1. when a datastore becomes aliased. This can happen for both remote and local datastores
|
|
977
|
+
* 2. when a datastore is created locally as root
|
|
978
|
+
* 3. when a datastore is created locally as root and is rehydrated
|
|
979
|
+
* @returns whether a datastore is root in memory
|
|
980
|
+
*/
|
|
981
|
+
protected isInMemoryRoot(): boolean;
|
|
982
|
+
protected registry: IFluidDataStoreRegistry | undefined;
|
|
983
|
+
protected detachedRuntimeCreation: boolean;
|
|
984
|
+
protected channel: IFluidDataStoreChannel | undefined;
|
|
985
|
+
private loaded;
|
|
986
|
+
protected pending: ISequencedDocumentMessage[] | undefined;
|
|
987
|
+
protected channelP: Promise<IFluidDataStoreChannel> | undefined;
|
|
988
|
+
protected _baseSnapshot: ISnapshotTree | undefined;
|
|
989
|
+
protected _attachState: AttachState;
|
|
990
|
+
private _isInMemoryRoot;
|
|
991
|
+
protected readonly summarizerNode: ISummarizerNodeWithGC;
|
|
992
|
+
protected readonly mc: MonitoringContext;
|
|
993
|
+
private readonly thresholdOpsCounter;
|
|
994
|
+
private static readonly pendingOpsCountThreshold;
|
|
995
|
+
/**
|
|
996
|
+
* If the summarizer makes local changes, a telemetry event is logged. This has the potential to be very noisy.
|
|
997
|
+
* So, adding a count of how many telemetry events are logged per data store context. This can be
|
|
998
|
+
* controlled via feature flags.
|
|
999
|
+
*/
|
|
1000
|
+
private localChangesTelemetryCount;
|
|
1001
|
+
private lastUsedRoutes;
|
|
1002
|
+
readonly id: string;
|
|
1003
|
+
private readonly _containerRuntime;
|
|
1004
|
+
private readonly parentContext;
|
|
1005
|
+
readonly storage: IDocumentStorageService;
|
|
1006
|
+
readonly scope: FluidObject;
|
|
1007
|
+
readonly loadingGroupId: string | undefined;
|
|
1008
|
+
protected pkg?: readonly string[];
|
|
1009
|
+
constructor(props: IFluidDataStoreContextProps, existing: boolean, isLocalDataStore: boolean, makeLocallyVisibleFn: () => void);
|
|
1010
|
+
dispose(): void;
|
|
1011
|
+
/**
|
|
1012
|
+
* When delete is called, that means that the data store is permanently removed from the runtime, and will not show up in future summaries
|
|
1013
|
+
* This function is called to prevent ops from being generated from this data store once it has been deleted. Furthermore, this data store
|
|
1014
|
+
* should not receive any ops/signals.
|
|
1015
|
+
*/
|
|
1016
|
+
delete(): void;
|
|
1017
|
+
setTombstone(tombstone: boolean): void;
|
|
1018
|
+
abstract setAttachState(attachState: AttachState.Attaching | AttachState.Attached): void;
|
|
1019
|
+
private rejectDeferredRealize;
|
|
1020
|
+
realize(): Promise<IFluidDataStoreChannel>;
|
|
1021
|
+
protected factoryFromPackagePath(): Promise<IFluidDataStoreFactory>;
|
|
1022
|
+
private realizeCore;
|
|
1023
|
+
/**
|
|
1024
|
+
* Notifies this object about changes in the connection state.
|
|
1025
|
+
* @param value - New connection state.
|
|
1026
|
+
* @param clientId - ID of the client. Its old ID when in disconnected state and
|
|
1027
|
+
* its new client ID when we are connecting or connected.
|
|
1028
|
+
*/
|
|
1029
|
+
setConnectionState(connected: boolean, clientId?: string): void;
|
|
1030
|
+
process(message: ISequencedDocumentMessage, local: boolean, localOpMetadata: unknown): void;
|
|
1031
|
+
processSignal(message: IInboundSignalMessage, local: boolean): void;
|
|
1032
|
+
getQuorum(): IQuorumClients;
|
|
1033
|
+
getAudience(): IAudience;
|
|
1034
|
+
/**
|
|
1035
|
+
* Returns a summary at the current sequence number.
|
|
1036
|
+
* @param fullTree - true to bypass optimizations and force a full summary tree
|
|
1037
|
+
* @param trackState - This tells whether we should track state from this summary.
|
|
1038
|
+
* @param telemetryContext - summary data passed through the layers for telemetry purposes
|
|
1039
|
+
*/
|
|
1040
|
+
summarize(fullTree?: boolean, trackState?: boolean, telemetryContext?: ITelemetryContext): Promise<ISummarizeResult>;
|
|
1041
|
+
private summarizeInternal;
|
|
1042
|
+
/**
|
|
1043
|
+
* Returns the data used for garbage collection. This includes a list of GC nodes that represent this data store
|
|
1044
|
+
* including any of its child channel contexts. Each node has a set of outbound routes to other GC nodes in the
|
|
1045
|
+
* document.
|
|
1046
|
+
* If there is no new data in this data store since the last summary, previous GC data is used.
|
|
1047
|
+
* If there is new data, the GC data is generated again (by calling getGCDataInternal).
|
|
1048
|
+
* @param fullGC - true to bypass optimizations and force full generation of GC data.
|
|
1049
|
+
*/
|
|
1050
|
+
getGCData(fullGC?: boolean): Promise<IGarbageCollectionData>;
|
|
1051
|
+
/**
|
|
1052
|
+
* Generates data used for garbage collection. This is called when there is new data since last summary. It
|
|
1053
|
+
* realizes the data store and calls into each channel context to get its GC data.
|
|
1054
|
+
* @param fullGC - true to bypass optimizations and force full generation of GC data.
|
|
1055
|
+
*/
|
|
1056
|
+
private getGCDataInternal;
|
|
1057
|
+
/**
|
|
1058
|
+
* After GC has run, called to notify the data store of routes used in it. These are used for the following:
|
|
1059
|
+
*
|
|
1060
|
+
* 1. To identify if this data store is being referenced in the document or not.
|
|
1061
|
+
*
|
|
1062
|
+
* 2. To determine if it needs to re-summarize in case used routes changed since last summary.
|
|
1063
|
+
*
|
|
1064
|
+
* 3. These are added to the summary generated by the data store.
|
|
1065
|
+
*
|
|
1066
|
+
* 4. To notify child contexts of their used routes. This is done immediately if the data store is loaded.
|
|
1067
|
+
* Else, it is done when realizing the data store.
|
|
1068
|
+
*
|
|
1069
|
+
* 5. To update the timestamp when this data store or any children are marked as unreferenced.
|
|
1070
|
+
*
|
|
1071
|
+
* @param usedRoutes - The routes that are used in this data store.
|
|
1072
|
+
*/
|
|
1073
|
+
updateUsedRoutes(usedRoutes: string[]): void;
|
|
1074
|
+
/**
|
|
1075
|
+
* @deprecated There is no replacement for this, its functionality is no longer needed at this layer.
|
|
1076
|
+
* It will be removed in a future release, sometime after 2.0.0-internal.8.0.0
|
|
1077
|
+
*
|
|
1078
|
+
* Similar capability is exposed with from/to string paths instead of handles via @see addedGCOutboundRoute
|
|
1079
|
+
*
|
|
1080
|
+
* Called when a new outbound reference is added to another node. This is used by garbage collection to identify
|
|
1081
|
+
* all references added in the system.
|
|
1082
|
+
* @param srcHandle - The handle of the node that added the reference.
|
|
1083
|
+
* @param outboundHandle - The handle of the outbound node that is referenced.
|
|
1084
|
+
*/
|
|
1085
|
+
addedGCOutboundReference(srcHandle: IFluidHandle, outboundHandle: IFluidHandle): void;
|
|
1086
|
+
/**
|
|
1087
|
+
* (Same as @see addedGCOutboundReference, but with string paths instead of handles)
|
|
1088
|
+
*
|
|
1089
|
+
* Called when a new outbound reference is added to another node. This is used by garbage collection to identify
|
|
1090
|
+
* all references added in the system.
|
|
1091
|
+
*
|
|
1092
|
+
* @param fromPath - The absolute path of the node that added the reference.
|
|
1093
|
+
* @param toPath - The absolute path of the outbound node that is referenced.
|
|
1094
|
+
*/
|
|
1095
|
+
addedGCOutboundRoute(fromPath: string, toPath: string): void;
|
|
1096
|
+
/**
|
|
1097
|
+
* Updates the used routes of the channel and its child contexts. The channel must be loaded before calling this.
|
|
1098
|
+
* It is called in these two scenarios:
|
|
1099
|
+
* 1. When the used routes of the data store is updated and the data store is loaded.
|
|
1100
|
+
* 2. When the data store is realized. This updates the channel's used routes as per last GC run.
|
|
1101
|
+
*/
|
|
1102
|
+
private updateChannelUsedRoutes;
|
|
1103
|
+
/**
|
|
1104
|
+
* @deprecated 0.18.Should call request on the runtime directly
|
|
1105
|
+
*/
|
|
1106
|
+
request(request: IRequest): Promise<IResponse>;
|
|
1107
|
+
submitMessage(type: string, content: any, localOpMetadata: unknown): void;
|
|
1108
|
+
/**
|
|
1109
|
+
* This is called from a SharedSummaryBlock that does not generate ops but only wants to be part of the summary.
|
|
1110
|
+
* It indicates that there is data in the object that needs to be summarized.
|
|
1111
|
+
* We will update the latestSequenceNumber of the summary tracker of this
|
|
1112
|
+
* store and of the object's channel.
|
|
1113
|
+
*
|
|
1114
|
+
* @param address - The address of the channel that is dirty.
|
|
1115
|
+
*
|
|
1116
|
+
*/
|
|
1117
|
+
setChannelDirty(address: string): void;
|
|
1118
|
+
/**
|
|
1119
|
+
* Submits the signal to be sent to other clients.
|
|
1120
|
+
* @param type - Type of the signal.
|
|
1121
|
+
* @param content - Content of the signal.
|
|
1122
|
+
* @param targetClientId - When specified, the signal is only sent to the provided client id.
|
|
1123
|
+
*/
|
|
1124
|
+
submitSignal(type: string, content: any, targetClientId?: string): void;
|
|
1125
|
+
/**
|
|
1126
|
+
* This is called by the data store channel when it becomes locally visible indicating that it is ready to become
|
|
1127
|
+
* globally visible now.
|
|
1128
|
+
*/
|
|
1129
|
+
makeLocallyVisible(): void;
|
|
1130
|
+
protected processPendingOps(channel: IFluidDataStoreChannel): void;
|
|
1131
|
+
protected completeBindingRuntime(channel: IFluidDataStoreChannel): void;
|
|
1132
|
+
protected bindRuntime(channel: IFluidDataStoreChannel, existing: boolean): Promise<void>;
|
|
1133
|
+
getAbsoluteUrl(relativeUrl: string): Promise<string | undefined>;
|
|
1134
|
+
/**
|
|
1135
|
+
* Get the data required when attaching this context's DataStore.
|
|
1136
|
+
* Used for both Container Attach and DataStore Attach.
|
|
1137
|
+
*
|
|
1138
|
+
* @returns the summary, type, and GC Data for this context's DataStore.
|
|
1139
|
+
*/
|
|
1140
|
+
abstract getAttachData(includeGCData: boolean, telemetryContext?: ITelemetryContext): {
|
|
1141
|
+
attachSummary: ISummaryTreeWithStats;
|
|
1142
|
+
type: string;
|
|
1143
|
+
};
|
|
1144
|
+
abstract getInitialSnapshotDetails(): Promise<ISnapshotDetails>;
|
|
1145
|
+
/**
|
|
1146
|
+
* @deprecated Sets the datastore as root, for aliasing purposes: #7948
|
|
1147
|
+
* This method should not be used outside of the aliasing context.
|
|
1148
|
+
* It will be removed, as the source of truth for this flag will be the aliasing blob.
|
|
1149
|
+
*/
|
|
1150
|
+
setInMemoryRoot(): void;
|
|
1151
|
+
/**
|
|
1152
|
+
* @deprecated The functionality to get base GC details has been moved to summarizer node.
|
|
1153
|
+
*/
|
|
1154
|
+
getBaseGCDetails(): Promise<IGarbageCollectionDetailsBase>;
|
|
1155
|
+
reSubmit(type: string, contents: any, localOpMetadata: unknown): void;
|
|
1156
|
+
rollback(type: string, contents: any, localOpMetadata: unknown): void;
|
|
1157
|
+
applyStashedOp(contents: any): Promise<unknown>;
|
|
1158
|
+
private verifyNotClosed;
|
|
1159
|
+
/**
|
|
1160
|
+
* Summarizer client should not have local changes. These changes can become part of the summary and can break
|
|
1161
|
+
* eventual consistency. For example, the next summary (say at ref seq# 100) may contain these changes whereas
|
|
1162
|
+
* other clients that are up-to-date till seq# 100 may not have them yet.
|
|
1163
|
+
*/
|
|
1164
|
+
protected identifyLocalChangeInSummarizer(eventName: string, type?: string): void;
|
|
1165
|
+
getCreateChildSummarizerNodeFn(id: string, createParam: CreateChildSummarizerNodeParam): (summarizeInternal: SummarizeInternalFn, getGCDataFn: (fullGC?: boolean) => Promise<IGarbageCollectionData>) => ISummarizerNodeWithGC;
|
|
1166
|
+
deleteChildSummarizerNode(id: string): void;
|
|
1167
|
+
uploadBlob(blob: ArrayBufferLike, signal?: AbortSignal): Promise<IFluidHandle<ArrayBufferLike>>;
|
|
1168
|
+
}
|
|
1169
|
+
|
|
657
1170
|
/**
|
|
658
1171
|
* @internal
|
|
659
1172
|
*/
|
|
@@ -706,8 +1219,6 @@ export declare type GCNodeType = (typeof GCNodeType)[keyof typeof GCNodeType];
|
|
|
706
1219
|
*/
|
|
707
1220
|
export declare type GCVersion = number;
|
|
708
1221
|
|
|
709
|
-
export { generateStableId }
|
|
710
|
-
|
|
711
1222
|
/**
|
|
712
1223
|
* A single summary which has already been acked by the server.
|
|
713
1224
|
* @alpha
|
|
@@ -850,7 +1361,7 @@ export declare interface IContainerRuntimeMetadata extends ICreateContainerMetad
|
|
|
850
1361
|
/** GUID to identify a document in telemetry */
|
|
851
1362
|
readonly telemetryDocumentId?: string;
|
|
852
1363
|
/** True if the runtime IdCompressor is enabled */
|
|
853
|
-
readonly
|
|
1364
|
+
readonly idCompressorMode?: IdCompressorMode;
|
|
854
1365
|
}
|
|
855
1366
|
|
|
856
1367
|
/**
|
|
@@ -909,7 +1420,7 @@ export declare interface IContainerRuntimeOptions {
|
|
|
909
1420
|
* Enable the IdCompressor in the runtime.
|
|
910
1421
|
* @experimental Not ready for use.
|
|
911
1422
|
*/
|
|
912
|
-
readonly enableRuntimeIdCompressor?:
|
|
1423
|
+
readonly enableRuntimeIdCompressor?: IdCompressorMode;
|
|
913
1424
|
/**
|
|
914
1425
|
* If enabled, the runtime will block all attempts to send an op inside the
|
|
915
1426
|
* {@link ContainerRuntime#ensureNoDataModelChanges} callback. The callback is used by
|
|
@@ -943,6 +1454,20 @@ export declare interface ICreateContainerMetadata {
|
|
|
943
1454
|
createContainerTimestamp?: number;
|
|
944
1455
|
}
|
|
945
1456
|
|
|
1457
|
+
/**
|
|
1458
|
+
* ID Compressor mode.
|
|
1459
|
+
* "on" - compressor is On. It's loaded as part of container load. This mode is sticky - once on, compressor is On for all
|
|
1460
|
+
* sessions for a given document. This results in IContainerRuntime.idCompressor to be always available.
|
|
1461
|
+
* "delayed" - ID compressor bundle is loaded only on establishing of first delta connection, i.e. it does not impact boot of cotnainer.
|
|
1462
|
+
* In such mode IContainerRuntime.idCompressor is not made available (unless previous sessions of same document had it "On").
|
|
1463
|
+
* The only thing that is available is IContainerRuntime.generateDocumentUniqueId() that provides opportunistically short IDs.
|
|
1464
|
+
* "off" - ID compressor is not laoded (unless it is "on" due to previous session for same document having it "on").
|
|
1465
|
+
* While IContainerRuntime.generateDocumentUniqueId() is available, it will produce long IDs that are do not compress well.
|
|
1466
|
+
*
|
|
1467
|
+
* @alpha
|
|
1468
|
+
*/
|
|
1469
|
+
export declare type IdCompressorMode = "on" | "delayed" | "off";
|
|
1470
|
+
|
|
946
1471
|
/**
|
|
947
1472
|
* Options to use when enqueueing a summarize attempt.
|
|
948
1473
|
* @alpha
|
|
@@ -959,6 +1484,41 @@ export declare interface IEnqueueSummarizeOptions extends IOnDemandSummarizeOpti
|
|
|
959
1484
|
readonly override?: boolean;
|
|
960
1485
|
}
|
|
961
1486
|
|
|
1487
|
+
/** @internal */
|
|
1488
|
+
export declare interface IFluidDataStoreContextEvents extends IEvent {
|
|
1489
|
+
(event: "attaching" | "attached", listener: () => void): any;
|
|
1490
|
+
}
|
|
1491
|
+
|
|
1492
|
+
/**
|
|
1493
|
+
* This is interface that every context should implement.
|
|
1494
|
+
* This interface is used for context's parent - ChannelCollection.
|
|
1495
|
+
* It should not be exposed to any other users of context.
|
|
1496
|
+
* @internal
|
|
1497
|
+
*/
|
|
1498
|
+
export declare interface IFluidDataStoreContextInternal extends IFluidDataStoreContext {
|
|
1499
|
+
getAttachData(includeGCData: boolean, telemetryContext?: ITelemetryContext): {
|
|
1500
|
+
attachSummary: ISummaryTreeWithStats;
|
|
1501
|
+
type: string;
|
|
1502
|
+
};
|
|
1503
|
+
getInitialSnapshotDetails(): Promise<ISnapshotDetails>;
|
|
1504
|
+
realize(): Promise<IFluidDataStoreChannel>;
|
|
1505
|
+
isRoot(): Promise<boolean>;
|
|
1506
|
+
}
|
|
1507
|
+
|
|
1508
|
+
/**
|
|
1509
|
+
* Properties necessary for creating a FluidDataStoreContext
|
|
1510
|
+
* @internal
|
|
1511
|
+
*/
|
|
1512
|
+
export declare interface IFluidDataStoreContextProps {
|
|
1513
|
+
readonly id: string;
|
|
1514
|
+
readonly parentContext: IFluidParentContext;
|
|
1515
|
+
readonly storage: IDocumentStorageService;
|
|
1516
|
+
readonly scope: FluidObject;
|
|
1517
|
+
readonly createSummarizerNodeFn: CreateChildSummarizerNodeFn;
|
|
1518
|
+
readonly pkg?: Readonly<string[]>;
|
|
1519
|
+
readonly loadingGroupId?: string;
|
|
1520
|
+
}
|
|
1521
|
+
|
|
962
1522
|
/**
|
|
963
1523
|
* GC-specific metadata to be written into the summary.
|
|
964
1524
|
*
|
|
@@ -1102,6 +1662,28 @@ export declare interface IGenerateSummaryTreeResult extends Omit<IBaseSummarizeR
|
|
|
1102
1662
|
readonly forcedFullTree: boolean;
|
|
1103
1663
|
}
|
|
1104
1664
|
|
|
1665
|
+
/**
|
|
1666
|
+
* Properties necessary for creating a local FluidDataStoreContext
|
|
1667
|
+
* @internal
|
|
1668
|
+
*/
|
|
1669
|
+
export declare interface ILocalDetachedFluidDataStoreContextProps extends ILocalFluidDataStoreContextProps {
|
|
1670
|
+
readonly channelToDataStoreFn: (channel: IFluidDataStoreChannel) => IDataStore;
|
|
1671
|
+
}
|
|
1672
|
+
|
|
1673
|
+
/**
|
|
1674
|
+
* Properties necessary for creating a local FluidDataStoreContext
|
|
1675
|
+
* @internal
|
|
1676
|
+
*/
|
|
1677
|
+
export declare interface ILocalFluidDataStoreContextProps extends IFluidDataStoreContextProps {
|
|
1678
|
+
readonly pkg: Readonly<string[]> | undefined;
|
|
1679
|
+
readonly snapshotTree: ISnapshotTree | undefined;
|
|
1680
|
+
readonly makeLocallyVisibleFn: () => void;
|
|
1681
|
+
/**
|
|
1682
|
+
* @deprecated 0.16 Issue #1635, #3631
|
|
1683
|
+
*/
|
|
1684
|
+
readonly createProps?: any;
|
|
1685
|
+
}
|
|
1686
|
+
|
|
1105
1687
|
/**
|
|
1106
1688
|
* The statistics of the system state after a garbage collection mark phase run.
|
|
1107
1689
|
* @alpha
|
|
@@ -1194,14 +1776,20 @@ export declare interface ISerializedElection {
|
|
|
1194
1776
|
readonly electedParentId: string | undefined;
|
|
1195
1777
|
}
|
|
1196
1778
|
|
|
1779
|
+
/** @internal */
|
|
1780
|
+
export declare interface ISnapshotDetails {
|
|
1781
|
+
pkg: readonly string[];
|
|
1782
|
+
isRootDataStore: boolean;
|
|
1783
|
+
snapshot?: ISnapshotTree;
|
|
1784
|
+
sequenceNumber?: number;
|
|
1785
|
+
}
|
|
1786
|
+
|
|
1197
1787
|
/**
|
|
1198
1788
|
* @deprecated please use version in driver-utils
|
|
1199
1789
|
* @internal
|
|
1200
1790
|
*/
|
|
1201
1791
|
export declare function isRuntimeMessage(message: ISequencedDocumentMessage): boolean;
|
|
1202
1792
|
|
|
1203
|
-
export { isStableId }
|
|
1204
|
-
|
|
1205
1793
|
/**
|
|
1206
1794
|
* Results of submitSummary after submitting the summarize op.
|
|
1207
1795
|
* @alpha
|
|
@@ -1224,6 +1812,8 @@ export declare interface ISubmitSummaryOptions extends ISummarizeOptions {
|
|
|
1224
1812
|
readonly cancellationToken: ISummaryCancellationToken;
|
|
1225
1813
|
/** Summarization may be attempted multiple times. This tells whether this is the final summarization attempt. */
|
|
1226
1814
|
readonly finalAttempt?: boolean;
|
|
1815
|
+
/** The sequence number of the latest summary used to validate if summary state is correct before summarizing */
|
|
1816
|
+
readonly latestSummaryRefSeqNum: number;
|
|
1227
1817
|
}
|
|
1228
1818
|
|
|
1229
1819
|
/**
|
|
@@ -1262,7 +1852,7 @@ export declare interface ISummarizer extends IEventProvider<ISummarizerEvents> {
|
|
|
1262
1852
|
readonly ISummarizer?: ISummarizer;
|
|
1263
1853
|
stop(reason: SummarizerStopReason): void;
|
|
1264
1854
|
close(): void;
|
|
1265
|
-
run(onBehalfOf: string
|
|
1855
|
+
run(onBehalfOf: string): Promise<SummarizerStopReason>;
|
|
1266
1856
|
/**
|
|
1267
1857
|
* Attempts to generate a summary on demand. If already running, takes no action.
|
|
1268
1858
|
* @param options - options controlling the summarize attempt
|
|
@@ -1545,6 +2135,48 @@ export declare interface IUploadSummaryResult extends Omit<IGenerateSummaryTreeR
|
|
|
1545
2135
|
readonly uploadDuration: number;
|
|
1546
2136
|
}
|
|
1547
2137
|
|
|
2138
|
+
/**
|
|
2139
|
+
* context implementation for "attached" data store runtime.
|
|
2140
|
+
* Various workflows (snapshot creation, requests) result in .realize() being called
|
|
2141
|
+
* on context, resulting in instantiation and attachment of runtime.
|
|
2142
|
+
* Runtime is created using data store factory that is associated with this context.
|
|
2143
|
+
* @internal
|
|
2144
|
+
*/
|
|
2145
|
+
export declare class LocalFluidDataStoreContext extends LocalFluidDataStoreContextBase {
|
|
2146
|
+
constructor(props: ILocalFluidDataStoreContextProps);
|
|
2147
|
+
}
|
|
2148
|
+
|
|
2149
|
+
/**
|
|
2150
|
+
* Base class for detached & attached context classes
|
|
2151
|
+
* @internal
|
|
2152
|
+
*/
|
|
2153
|
+
export declare class LocalFluidDataStoreContextBase extends FluidDataStoreContext {
|
|
2154
|
+
private readonly snapshotTree;
|
|
2155
|
+
/**
|
|
2156
|
+
* @deprecated 0.16 Issue #1635, #3631
|
|
2157
|
+
*/
|
|
2158
|
+
readonly createProps?: any;
|
|
2159
|
+
constructor(props: ILocalFluidDataStoreContextProps);
|
|
2160
|
+
setAttachState(attachState: AttachState.Attaching | AttachState.Attached): void;
|
|
2161
|
+
/**
|
|
2162
|
+
* @see FluidDataStoreContext.getAttachData
|
|
2163
|
+
*/
|
|
2164
|
+
getAttachData(includeGCData: boolean, telemetryContext?: ITelemetryContext): {
|
|
2165
|
+
attachSummary: ISummaryTreeWithStats;
|
|
2166
|
+
type: string;
|
|
2167
|
+
};
|
|
2168
|
+
private readonly initialSnapshotDetailsP;
|
|
2169
|
+
getInitialSnapshotDetails(): Promise<ISnapshotDetails>;
|
|
2170
|
+
/**
|
|
2171
|
+
* A context should only be marked as deleted when its a remote context.
|
|
2172
|
+
* Session Expiry at the runtime level should have closed the container creating the local data store context
|
|
2173
|
+
* before delete is even possible. Session Expiry is at 30 days, and sweep is done 36+ days later from the time
|
|
2174
|
+
* it was unreferenced. Thus the sweeping container should have loaded from a snapshot and thus creating a remote
|
|
2175
|
+
* context.
|
|
2176
|
+
*/
|
|
2177
|
+
delete(): void;
|
|
2178
|
+
}
|
|
2179
|
+
|
|
1548
2180
|
/**
|
|
1549
2181
|
* Can be useful in testing as well as in places where caller does not use cancellation.
|
|
1550
2182
|
* This object implements ISummaryCancellationToken interface but cancellation is never leveraged.
|
|
@@ -1571,6 +2203,17 @@ export declare interface RecentlyAddedContainerRuntimeMessageDetails {
|
|
|
1571
2203
|
compatDetails: IContainerRuntimeMessageCompatDetails;
|
|
1572
2204
|
}
|
|
1573
2205
|
|
|
2206
|
+
/**
|
|
2207
|
+
* The full set of parsed header data that may be found on Runtime requests
|
|
2208
|
+
* @internal
|
|
2209
|
+
*/
|
|
2210
|
+
export declare interface RuntimeHeaderData {
|
|
2211
|
+
wait?: boolean;
|
|
2212
|
+
viaHandle?: boolean;
|
|
2213
|
+
allowTombstone?: boolean;
|
|
2214
|
+
allowInactive?: boolean;
|
|
2215
|
+
}
|
|
2216
|
+
|
|
1574
2217
|
/**
|
|
1575
2218
|
* Accepted header keys for requests coming to the runtime.
|
|
1576
2219
|
* @internal
|