FluidFramework
FluidFramework copied to clipboard
[Data Virtualization] Add capability to load omitted snaphot in RemoteFluidDataStore (Draft)
Description
This adds capability to load individual datastores with a loadingGroupId if the snapshot content is omitted. 1.) Add function in container Runtime to fetch the snapshot based on loadingGroupid and return the part of that snapshot for the path requested. The group snapshot is cached so that it can used by used by other requests. We use PromiseCache so that we can get the same promise if it is not yet completed. 2.) The above API returns the snapshot when the container has caught up to the snapshot seq number of the snapshot of a loading group. If it is summarizer, then it throws an error as that means summarizer is not up to date. 3.) In datastoreContext, when the snapshot is returned, we only process the ops which are after the snapshot seq number. 4.) Also added various unit tests to cover different scenarios.
This is part of data virtualization effort which is documented here: Design Doc
⯅ @fluid-example/bundle-size-tests: +5.93 KB
| Metric Name | Baseline Size | Compare Size | Size Diff |
|---|---|---|---|
| aqueduct.js | 511.14 KB | 514.05 KB | ⯅ +2.91 KB |
| connectionState.js | 680 Bytes | 680 Bytes | ■ No change |
| containerRuntime.js | 245.01 KB | 247.91 KB | ⯅ +2.9 KB |
| loader.js | 170.65 KB | 170.67 KB | ⯅ +22 Bytes |
| map.js | 46.53 KB | 46.54 KB | ⯅ +11 Bytes |
| matrix.js | 148.68 KB | 148.69 KB | ⯅ +11 Bytes |
| odspDriver.js | 97.34 KB | 97.37 KB | ⯅ +30 Bytes |
| odspPrefetchSnapshot.js | 42.28 KB | 42.3 KB | ⯅ +22 Bytes |
| sharedString.js | 167.42 KB | 167.43 KB | ⯅ +11 Bytes |
| sharedTree.js | 334 KB | 334 KB | ■ No change |
| Total Size | 1.87 MB | 1.87 MB | ⯅ +5.93 KB |
Baseline commit: 27c3ffee85115a614c2eb6c59e604c29f180a363
Generated by :no_entry_sign: dangerJS against 910ea1e8da56533ec4e9c31522efc49f5d124fa3