Contents
- ✨ New Features
- Additional change validation options (#27977)
- 🐛 Bug Fixes
- Improve validation in SharedTree forests (#27920)
- Fix LocalReferenceCollection.walkReferences skipping the starting reference (#27947)
- ⚠️ Deprecations
- Rename minVersionForCollab to oldestSupportedClient (#27806)
✨ New Features
Additional change validation options (#27977)
Adds the following new options to SharedTreeOptions (alpha):
validateCommitsOnFirstSubmission: (default:false) Whentrue, validates that commits being submitted for the first time can be applied without errors to a view.validateRebasedCommitsBeforeResubmission: (default:false) Whentrue, validates that the commits being resubmitted can be applied without errors to a view.
In the event that a commit cannot be applied, SharedTree will throw an error and will enter a "broken" state, preventing the offending commit (and any further commits) from being submitted. This can be enabled (at the cost of performance) to improve safety against document corruption in the event of a bug in the SharedTree code: when the additional validation is enabled, a client will error instead of potentially corrupting the document.
These flags are experimental. We recommend turning them on (first validateRebasedCommitsBeforeResubmission and, if needed, validateCommitsOnFirstSubmission) when trying to mitigate bugs in SharedTree or performing root cause analysis.
We recommend configuring SharedTree with the optimized forest implementation to reduce the performance impact of this validation.
Change details
Commit: d3a9a3e
Affected packages:
- fluid-framework
- @fluidframework/tree
⬆️ Table of contents
🐛 Bug Fixes
Improve validation in SharedTree forests (#27920)
Our ForestType implementations now have better and more consistent validation of changes being applied. This should only impact cases which have hit bugs, resulting in edits which are not valid for the tree they are being applied to. Now the asserts should be more specific, helping to triage such issues. This also reduces the risk of document corruption by catching invalid data earlier and more consistently.
Change details
Commit: 9c67a98
Affected packages:
- @fluidframework/tree
- fluid-framework
⬆️ Table of contents
Fix LocalReferenceCollection.walkReferences skipping the starting reference (#27947)
LocalReferenceCollection.walkReferences compared the wrong objects when locating the before/at/after bucket containing the supplied start reference. It compared list nodes of the outer bucket list against the list node of start itself, which never match, so the walk discarded every bucket at start's offset and began at the next offset instead. As a result, a walk with an explicit start never visited start or any other reference at its offset.
The walk now stops at the bucket containing start and resumes from start within that bucket, so start is visited first in both the forward and backward directions.
Change details
Commit: 20b6449
Affected packages:
- @fluidframework/merge-tree
⬆️ Table of contents
⚠️ Deprecations
Rename minVersionForCollab to oldestSupportedClient (#27806)
The cross-client compatibility parameter has new names:
- The
MinimumVersionForCollabtype is nowOldestSupportedClientVersion. LoadContainerRuntimeParams.minVersionForCollabis nowLoadContainerRuntimeParams.oldestSupportedClient.BaseContainerRuntimeFactoryProps.minVersionForCollabis nowBaseContainerRuntimeFactoryProps.oldestSupportedClient.createTreeContainerRuntimeFactorynow acceptsoldestSupportedClient.minVersionForCollaborationremains available as a deprecated overload.@fluidframework/driver-definitionsnow exports its minor-only version type asOldestSupportedServiceClientVersion, andServiceOptions.oldestSupportedClientis available.AzureClient,OdspClient, andTinyliciousClientmethods now useoldestSupportedClientandOldestSupportedClientVersionin their signatures.
The previous property and type names in @fluidframework/runtime-definitions, @fluidframework/container-runtime, @fluidframework/aqueduct, and @fluidframework/fluid-static are deprecated and will be removed in future releases. Where both old and new property names remain available, specifying both is an error. The alpha MinimumVersionForCollaboration type and ServiceOptions.minVersionForCollaboration property are replaced directly rather than retained as aliases.
// Before
const runtime = await loadContainerRuntime({
context,
registryEntries,
provideEntryPoint,
minVersionForCollab: "2.40.0",
});
// After
const runtime = await loadContainerRuntime({
context,
registryEntries,
provideEntryPoint,
oldestSupportedClient: "2.40.0",
});Telemetry property names are unchanged.
Change details
Commit: 86b9121
Affected packages:
- @fluidframework/runtime-definitions
- @fluidframework/container-runtime
- @fluidframework/aqueduct
- @fluidframework/azure-client
- @fluidframework/datastore
- @fluidframework/driver-definitions
- @fluidframework/fluid-static
- @fluidframework/local-driver
- @fluidframework/odsp-client
- @fluidframework/test-runtime-utils
- @fluidframework/tree
- @fluidframework/tinylicious-client
- fluid-framework
⬆️ Table of contents
🛠️ Start Building Today!
Please continue to engage with us on GitHub Discussion and Issue pages as you adopt Fluid Framework!