-
Notifications
You must be signed in to change notification settings - Fork 536
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
Add BREAKING.md updates from recent changes #7314
Merged
skylerjokiel
merged 5 commits into
microsoft:main
from
skylerjokiel:add-breaking-md-changes
Aug 31, 2021
Merged
Changes from 3 commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change | ||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -2,6 +2,11 @@ | |||||||||||||||||||||
- [Property removed from IFluidDataStoreContext](#Property-removed-from-IFluidDataStoreContext) | ||||||||||||||||||||||
- [Changes to IFluidDataStoreFactory](#Changes-to-IFluidDataStoreFactory) | ||||||||||||||||||||||
- [FlushMode enum values renamed](#FlushMode-enum-values-renamed) | ||||||||||||||||||||||
- [name removed from ContainerSchema](#name-removed-from-ContainerSchema) | ||||||||||||||||||||||
- [Anonymous return types for container calls in client packages](#Anonymous-return-types-for-container-calls-in-client-packages) | ||||||||||||||||||||||
- [createContainer and getContainer response objects properties renamed](#createContainer-and-getContainer-response-objects-properties-renamed) | ||||||||||||||||||||||
- [tinylicious and azure clients createContainer now detached](#tinylicious-and-azure-clients-createContainer-now-detached) | ||||||||||||||||||||||
- [container id is returned from new attach() and not exposed on the container](#container-id-is-returned-from-new-attach()-and-not-exposed-on-the-container) | ||||||||||||||||||||||
|
||||||||||||||||||||||
### Property removed from IFluidDataStoreContext | ||||||||||||||||||||||
- the `existing` property from `IFluidDataStoreContext` (and `FluidDataStoreContext`) has been removed. | ||||||||||||||||||||||
|
@@ -14,6 +19,73 @@ | |||||||||||||||||||||
- `FlushMode.Manual` to `FlushMode.TurnBased` | ||||||||||||||||||||||
- `FlushMode.Automatic` to `FlushMode.Immediate` | ||||||||||||||||||||||
|
||||||||||||||||||||||
### `name` removed from ContainerSchema | ||||||||||||||||||||||
The `name` property on the ContainerSchema was used for multi-container scenarios but has not materialized to be a useful schema property. The feedback has been negative to neutral and the goal is to remove it before it becomes formalized. Support for multi-container scenarios, if any is required, will be addressed as a future change. | ||||||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||||||||||
|
||||||||||||||||||||||
### Anonymous return types for container calls in client packages | ||||||||||||||||||||||
`createContainer` and `getContainer` in `@fluidframework/azure-client` and `@fluidframework/tinylicious-client` will no longer return typed objects but instead will return an anonymous type. This provide the flexibility that comes with tuple deconstruction with the strong typing of property names. | ||||||||||||||||||||||
|
||||||||||||||||||||||
```javascript | ||||||||||||||||||||||
// `@fluidframework/azure-client` | ||||||||||||||||||||||
createContainer(containerSchema: ContainerSchema): Promise<{ | ||||||||||||||||||||||
container: FluidContainer; | ||||||||||||||||||||||
services: AzureContainerServices; | ||||||||||||||||||||||
}>; | ||||||||||||||||||||||
getContainer(id: string, containerSchema: ContainerSchema): Promise<{ | ||||||||||||||||||||||
container: FluidContainer; | ||||||||||||||||||||||
services: AzureContainerServices; | ||||||||||||||||||||||
}>; | ||||||||||||||||||||||
|
||||||||||||||||||||||
// `@fluidframework/tinylicious-client` | ||||||||||||||||||||||
createContainer(containerSchema: ContainerSchema): Promise<{ | ||||||||||||||||||||||
container: FluidContainer; | ||||||||||||||||||||||
services: TinyliciousContainerServices; | ||||||||||||||||||||||
}>; | ||||||||||||||||||||||
getContainer(id: string, containerSchema: ContainerSchema): Promise<{ | ||||||||||||||||||||||
container: FluidContainer; | ||||||||||||||||||||||
services: TinyliciousContainerServices; | ||||||||||||||||||||||
}>; | ||||||||||||||||||||||
``` | ||||||||||||||||||||||
|
||||||||||||||||||||||
### createContainer and getContainer response objects properties renamed | ||||||||||||||||||||||
For all `*-client` packages `createContainer` and `getContainer` would return an object with `fluidContainer` and `containerServices`. These have been renamed to the following for brevity. | ||||||||||||||||||||||
|
||||||||||||||||||||||
- fluidContainer => container | ||||||||||||||||||||||
- containerServices => services | ||||||||||||||||||||||
|
||||||||||||||||||||||
```javascript | ||||||||||||||||||||||
// old | ||||||||||||||||||||||
const { fluidContainer, containerServices } = client.getContainer; | ||||||||||||||||||||||
|
||||||||||||||||||||||
// new | ||||||||||||||||||||||
const { container, services } = client.getContainer; | ||||||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
nitty nitty |
||||||||||||||||||||||
``` | ||||||||||||||||||||||
|
||||||||||||||||||||||
### tinylicious and azure clients createContainer now detached | ||||||||||||||||||||||
Creating a new container now requires and explicit attach step. All changes made in between container creation, and attaching, will be persisted as part of creation and guaranteed to always be available to users. This allows developers to initialize `initialObjects` with state before the container is connected to the service. It also enables draft creation modes. | ||||||||||||||||||||||
|
||||||||||||||||||||||
```javascript | ||||||||||||||||||||||
// old | ||||||||||||||||||||||
const { fluidContainer } = client.createContainer(...); | ||||||||||||||||||||||
|
||||||||||||||||||||||
// new | ||||||||||||||||||||||
const { container } = client.createContainer(...); | ||||||||||||||||||||||
const id = container.attach(); | ||||||||||||||||||||||
``` | ||||||||||||||||||||||
|
||||||||||||||||||||||
### container id is returned from new attach() and not exposed on the container | ||||||||||||||||||||||
Because we now have an explicit attach flow the container id is apart of that flow. The id is returned from the `attach()` call. | ||||||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||||||||||||||||||
|
||||||||||||||||||||||
```javascript | ||||||||||||||||||||||
// old | ||||||||||||||||||||||
const { fluidContainer } = client.createContainer(...); | ||||||||||||||||||||||
const containerId = fluidContainer.id; | ||||||||||||||||||||||
|
||||||||||||||||||||||
// new | ||||||||||||||||||||||
const { container } = client.createContainer(...); | ||||||||||||||||||||||
const containerId = container.attach(); | ||||||||||||||||||||||
``` | ||||||||||||||||||||||
|
||||||||||||||||||||||
## 0.46 Breaking changes | ||||||||||||||||||||||
- [@fluid-experimental/fluid-framework package name changed](#fluid-experimentalfluid-framework-package-name-changed) | ||||||||||||||||||||||
- [FrsClient has been renamed to AzureClient and moved out of experimental state](#FrsClient-has-been-renamed-to-AzureClient-and-moved-out-of-experimental-state) | ||||||||||||||||||||||
|
@@ -25,6 +97,7 @@ | |||||||||||||||||||||
### `@fluid-experimental/fluid-framework` package name changed | ||||||||||||||||||||||
The `@fluid-experimental/fluid-framework` package has been renamed to now be `fluid-framework`. The scope has been removed. | ||||||||||||||||||||||
|
||||||||||||||||||||||
|
||||||||||||||||||||||
### FrsClient has been renamed to AzureClient and moved out of experimental state | ||||||||||||||||||||||
The `@fluid-experimental/frs-client` package for connecting with the Azure Fluid Relay service has been renamed to now be `@fluidframework/azure-client`. This also comes with the following name changes for the exported classes and interfaces from the package: | ||||||||||||||||||||||
- `FrsClient` -> `AzureClient` | ||||||||||||||||||||||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: this link doesn't seem to work, probably the
()
needs to be removed?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm interesting. I actually checked this and it works in vscode. Removing them worked too so I did that but yea. Nice catch :)