-
Notifications
You must be signed in to change notification settings - Fork 575
feat(container-loader): add readOnly option to loadFrozenContainerFromPendingState #27211
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
3d57157
2991cf6
8f2774f
e771980
fb6a0fd
f4a202e
a08917f
3e767b8
7c31d95
ff37f19
411863f
d1fd645
7866ef5
cdcf203
849c0ed
ce7f4ed
e93eb26
ac44bd1
ebb5b29
8f15eef
86c509a
2035078
4ddd5c1
a3360ee
102c584
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| --- | ||
| "@fluidframework/container-loader": minor | ||
| "__section": feature | ||
| --- | ||
| Add readOnly option to loadFrozenContainerFromPendingState | ||
|
Check failure on line 5 in .changeset/frozen-container-readonly-option.md
|
||
|
|
||
| `loadFrozenContainerFromPendingState` and `createFrozenDocumentServiceFactory` now accept an optional `readOnly` parameter (default `true`, preserving existing behavior). | ||
|
|
||
| When `readOnly: false`, the frozen container loads as writable so the runtime accepts DDS submissions. The container stays `Connected` against a synthetic `WritableFrozenDeltaStream`: `ConnectionManager.sendMessages` recognizes it as the live connection and short-circuits before the read-mode reconnect branch, dropping outbound messages at the connection-manager layer. Submitted ops accumulate in the runtime's pending-state manager so `getPendingLocalState()` can capture them. | ||
|
Check failure on line 9 in .changeset/frozen-container-readonly-option.md
|
||
|
|
||
| Use `readOnly: false` when the caller wants to load a frozen container, apply additional local changes, and capture the resulting pending state via `getPendingLocalState()`. | ||
|
|
||
| Also: `FrozenDeltaStream.submitSignal` is now a silent no-op for both variants. The pre-existing read-only-variant behavior was a 403 nack on signals; this PR drops it for both variants because (a) for the writable variant a stray signal would close or reconnect the container, and (b) signals are ephemeral and dropping them is the correct behavior with no upstream. `FrozenDeltaStream.submit` continues to nack defensively. | ||
|
Check failure on line 13 in .changeset/frozen-container-readonly-option.md
|
||
Uh oh!
There was an error while loading. Please reload this page.