Local Web host is removed. Users who are using the local web host can use examples/utils/get-session-storage-container which provides the same functionality with the detached container flow.
- External Component Loader and IComponentDefaultFactoryName removed
- MockFluidDataStoreRuntime api rename
- Local Web Host API change
- Container runtime event changes
- Component is removed from telemetry event names
- IComponentContextLegacy is removed
- IContainerRuntimeBase._createDataStoreWithProps() is removed
- _createDataStore() APIs are removed
- createDataStoreWithRealizationFn() APIs are removed
- getDataStore() APIs is removed
- Package Renames
- IComponent and IComponent Interfaces Removed
- @fluidframework/odsp-utils - Minor renames and signature changes
- LastEditedTrackerComponent renamed to LastEditedTrackerDataObject
- ComponentProvider renamed to FluidObjectProvider in @fluidframework/synthesize
The @fluidframework/external-component-loader package has been removed from the repo. In addition to this, the IFluidExportDefaultFactoryName and the corresponding IProvideFluidExportDefaultFactoryName interfaces have also been dropped.
Runtime Test Utils's MockFluidDataStoreRuntime now has "requestDataStore" instead of "requestComponent"
The renderDefaultComponent function has been updated to be renderDefaultFluidObject
Container runtime now emits the event "fluidDataStoreInstantiated" instead of "componentInstantiated"
The following telemetry event names have been updated to drop references to the term component:
ComponentRuntimeDisposeError -> ChannelDisposeError ComponentContextDisposeError -> FluidDataStoreContextDisposeError SignalComponentNotFound -> SignalFluidDataStoreNotFound
Deprecated in 0.18, removed.
IContainerRuntimeBase._createDataStoreWithProps()
has been removed. Please use IContainerRuntimeBase.createDataStore()
(returns IFluidRouter).
If you need to pass props to data store, either use request() route to pass initial props directly, or to query Fluid object to interact with it (pass props / call methods to configure object).
IFluidDataStoreContext._createDataStore()
& IContainerRuntimeBase._createDataStore()
are removed
Please switch to using one of the following APIs:
IContainerRuntime.createRootDataStore()
- data store created that way is automatically bound to container. It will immediately be visible to remote clients (when/if container is attached). Such data stores are never garbage collected. Note that this API is onIContainerRuntime
interface, which is not directly accessible to data stores. The intention is that only container owners are creating roots.IContainerRuntimeBase.createDataStore()
- creates data store that is not bound to container. In order for this store to be bound to container (and thus be observable on remote clients), ensure that handle to it (or any of its objects / DDS) is stored into any other DDS that is already bound to container. In other words, newly created data store has to be reachable (there has to be a path) from some root data store in container. If, in future, such data store becomes unreachable from one of the roots, it will be garbage collected (implementation pending).
Removed from IFluidDataStoreContext & IContainerRuntime. Consider using (Pure)DataObject(Factory) for your objects - they support passing initial args. Otherwise consider implementing similar flow of exposing interface from your Fluid object that is used to initialize object after creation.
IContainerRuntime.getDataStore() is removed. Only IContainerRuntime.getRootDataStore() is available to retrieve root data stores.
For couple versions we will allow retrieving non-root data stores using this API, but this functionality is temporary and will be removed soon.
You can use handleFromLegacyUri() for creating handles from container-internal URIs (i.e., in format /${dataStoreId}
) and resolving those containers to get to non-root data stores. Please note that this functionality is strictly added for legacy files! In future, not using handles to refer to content (and storing handles in DDSes) will result in such data stores not being reachable from roots, and thus garbage collected (deleted) from file.
As a follow up to the changes in 0.24 we are updating a number of package names
@fluidframework/core-interfaces
is renamed to@fluidframework/core-interfaces
@fluidframework/datastore-definitions
is renamed to@fluidframework/datastore-definitions
@fluidframework/datastore
is renamed to@fluidframework/datastore
@fluidframework/webpack-component-loader
is renamed to@fluidframework/webpack-fluid-loader
In 0.24 IComponent and IComponent interfaces were deprecated, they are being removed in this build. Please move to IFluidObject and IFluidObject interfaces.
To support additional authentication scenarios, the signature and/or name of a few auth-related functions was modified.
It is renamed to LastEditedTrackerDataObject
In the package @fluidframework/synthesize, these types are renamed:
ComponentKey -> FluidObjectKey ComponentSymbolProvider -> FluidObjectProvider AsyncRequiredcomponentProvider -> AsyncRequiredFluidObjectProvider AsyncOptionalComponentProvider -> AsyncOptionalFluidObjectProvider AsyncComponentProvider -> AsyncFluidObjectProvider NonNullableComponent -> NonNullableFluidObject
This release only contains renames. There are no functional changes in this release. You should ensure you have integrated and validated up to release 0.23 before integrating this release.
This is a followup to the forward compat added in release 0.22: Forward Compat For Loader IComponent Interfaces
You should ensure all container and components hosts are running at least 0.22 before integrating this release.
The below json describes all the renames done in this release. If you have a large typescript code base, we have automation that may help. Please contact us if that is the case.
All renames are 1-1, and global case senstive and whole word find replace for all should be safe. For IComponent Interfaces, both the type and property name were re-named.
{
"dataStore":{
"types":{
"IComponentRuntimeChannel":"IFluidDataStoreChannel",
"IComponentAttributes": "IFluidDataStoretAttributes",
"IComponentContext": "IFluidDataStoreContext",
"ComponentContext": "FluidDataStoreContext",
"LocalComponentContext":"LocalFluidDataStoreContext",
"RemotedComponentContext": "RemotedFluidDataStoreContext ",
"IComponentRuntime":"IFluidDataStoreRuntime",
"ComponentRuntime": "FluidDataStoreRuntime",
"MockComponentRuntime": "MockFluidDataStoreRuntime"
},
"methods":{
"createComponent": "_createDataStore",
"createComponentContext": "createDataStoreContext",
"createComponentWithProps": "createDataStoreWithProps",
"_createComponentWithProps": "_createDataStoreWithProps",
"createComponentWithRealizationFn": "createDataStoreWithRealizationFn",
"getComponentRuntime": "getDataStore",
"notifyComponentInstantiated": "notifyDataStoreInstantiated"
}
},
"aquaduct":{
"IComponentInterfaces":{
"IProvideComponentDefaultFactoryName": "IProvideFluidExportDefaultFactoryName",
"IComponentDefaultFactoryName": "IFluidExportDefaultFactoryName"
},
"types":{
"SharedComponentFactory": "PureDataObjectFactory",
"SharedComponent": "PureDataObject",
"PrimedComponentFactory": "DataObjectFactory",
"PrimedComponent": "DataObject",
"ContainerRuntimeFactoryWithDefaultComponent": "ContainerRuntimeFactoryWithDefaultDataStore",
"defaultComponentRuntimeRequestHandler": "defaultRouteRequestHandler"
},
"methods": {
"getComponent": "requestFluidObject",
"asComponent": "asFluidObject",
"createAndAttachComponent": "createAndAttachDataStore",
"getComponentFromDirectory": "getFluidObjectFromDirectory",
"getComponent_UNSAFE": "requestFluidObject_UNSAFE",
"componentInitializingFirstTime": "initializingFirstTime",
"componentInitializingFromExisting": "initializingFromExisting",
"componentHasInitialized": "hasInitialized"
}
},
"fluidObject":{
"IComponentInterfaces":{
"IProvideComponentRouter": "IProvideFluidRouter",
"IComponentRouter": "IFluidRouter",
"IProvideComponentLoadable": "IProvideFluidLoadable",
"IComponentLoadable": "IFluidLoadable",
"IProvideComponentHandle": "IProvideFluidHandle",
"IComponentHandle": "IFluidHandle",
"IProvideComponentHandleContext": "IProvideFluidHandleContext",
"IComponentHandleContext": "IFluidHandleContext",
"IProvideComponentSerializer": "IProvideFluidSerializer",
"IComponentSerializer": "IFluidSerializer",
"IProvideComponentRunnable": "IProvideFluidRunnable",
"IComponentRunnable": "IFluidRunnable",
"IProvideComponentConfiguration": "IProvideFluidConfiguration",
"IComponentConfiguration": "IFluidConfiguration",
"IProvideComponentHTMLView": "IProvideFluidHTMLView",
"IComponentHTMLView": "IFluidHTMLView",
"IComponentHTMLOptions": "IFluidHTMLOptions",
"IProvideComponentMountableView": "IProvideFluidMountableView",
"IComponentMountableViewClass": "IFluidMountableViewClass",
"IComponentMountableView": "IFluidMountableView",
"IProvideComponentLastEditedTracker": "IProvideFluidLastEditedTracker",
"IComponentLastEditedTracker": "IFluidLastEditedTracker",
"IProvideComponentRegistry": "IProvideFluidDataStoreRegistry",
"IComponentRegistry": "IFluidDataStoreRegistry",
"IProvideComponentFactory": "IProvideFluidDataStoreFactory",
"IComponentFactory": "IFluidDataStoreFactory",
"IProvideComponentCollection": "IProvideFluidObjectCollection",
"IComponentCollection": "IFluidObjectCollection",
"IProvideComponentDependencySynthesizer": "IProvideFluidDependencySynthesizer",
"IComponentDependencySynthesizer": "IFluidDependencySynthesizer",
"IProvideComponentTokenProvider": "IProvideFluidTokenProvider",
"IComponentTokenProvider": "IFluidTokenProvider"
},
"types":{
"IComponent": "IFluidObject",
"fluid/component": "fluid/object",
"SharedObjectComponentHandle": "SharedObjectHandle",
"RemoteComponentHandle": "RemoteFluidObjectHandle",
"ComponentHandle": "FluidObjectHandle",
"ComponentSerializer": "FluidSerializer",
"ComponentHandleContext": "FluidHandleContext",
"ComponentRegistryEntry": "FluidDataStoreRegistryEntry",
"NamedComponentRegistryEntry": "NamedFluidDataStoreRegistryEntry",
"NamedComponentRegistryEntries": "NamedFluidDataStoreRegistryEntries",
"ComponentRegistry": "FluidDataStoreRegistry",
"ContainerRuntimeComponentRegistry": "ContainerRuntimeDataStoreRegistry"
},
"methods":{
"instantiateComponent": "instantiateDataStore"
}
}
}
- Removed
collaborating
event on IComponentRuntime - ISharedObjectFactory rename
- LocalSessionStorageDbFactory moved to @fluidframework/local-driver
Component Runtime no longer fires the collaborating event on attaching. Now it fires attaching
event.
ISharedObjectFactory
renamed to IChannelFactory
and moved from @fluidframework/shared-object-base
to @fluidframework/datastore-definitions
Previously, LocalSessionStorageDbFactory
was part of the @fluidframework/webpack-component-loader
package. It has been moved to the @fluidframework/local-driver
package.
- Deprecated
path
fromIComponentHandleContext
- Dynamically loaded components compiled against older versions of runtime
- ContainerRuntime.load Request Handler Changes
- IComponentHTMLVisual removed
- IComponentReactViewable deprecated
- Forward Compat For Loader IComponent Interfaces
- Add Undefined to getAbsoluteUrl return type
- Renamed TestDeltaStorageService, TestDocumentDeltaConnection, TestDocumentService, TestDocumentServiceFactory and TestResolver
- DocumentDeltaEventManager has been renamed and moved to "@fluidframework/test-utils"
isAttached
replaced withattachState
property
Deprecated the path
field from the interface IComponentHandleContext
. This means that IComponentHandle
will not have this going forward as well.
Added an absolutePath
field to IComponentHandleContext
which is the absolute path to reach it from the container runtime.
Components that were compiled against Fluid Framework <= 0.19.x releases will fail to load. A bunch of APIs has been deprecated in 0.20 & 0.21 and back compat support is being removed in 0.22. Some of the key APIs are:
- IComponentRuntime.attach
- ContainerContext.isAttached
- ContainerContext.isLocal Such components needs to be compiled against >= 0.21 runtime and can be used in container that is built using >= 0.21 runtime as well.
ContainerRuntime.load no longer accepts an array of RuntimeRequestHandlers. It has been changed to a single function parameter with a compatible signature:
requestHandler?: (request: IRequest, runtime: IContainerRuntime) => Promise<IResponse>
To continue to use RuntimeRequestHandlers you can used the RuntimeRequestHandlerBuilder
in the package @fluidframework/request-handler
example:
const builder = new RuntimeRequestHandlerBuilder();
builder.pushHandler(...this.requestHandlers);
builder.pushHandler(defaultRouteRequestHandler("defaultComponent"));
builder.pushHandler(deprecated_innerRequestHandler());
const runtime = await ContainerRuntime.load(
context,
this.registryEntries,
async (req,rt) => builder.handleRequest(req, rt),
undefined,
scope);
Additionally the class RequestParser
has been moved to the @fluidframework/runtime-utils
package
This will allow consumers of our ContainerRuntime to substitute other routing frameworks more easily.
The IComponentHTMLVisual
interface was deprecated in 0.21, and is now removed in 0.22. To support multiview scenarios, consider split view/model patterns like those demonstrated in the multiview sample.
The IComponentReactViewable
interface is deprecated and will be removed in an upcoming release. For multiview scenarios, instead use a pattern like the one demonstrated in the sample in /components/experimental/multiview. This sample demonstrates how to create multiple views for a component.
As part of the Fluid Data Library (FDL) and Fluid Component Library (FCL) split we will be renaming a significant number of out interfaces. Some of these interfaces are used across the loader -> runtime boundary. For these interfaces we have introduced the newly renamed interfaces in this release. This will allow Host's to implment forward compatbitiy for these interfaces, so they are not broken when the implementations themselves are renamed.
IComponentLastEditedTracker
will becomeIFluidLastEditedTracker
IComponentHTMLView
will becomeIFluidHTMLView
IComponentMountableViewClass
will becomeIFluidMountableViewClass
IComponentLoadable
will becomeIFluidLoadable
IComponentRunnable
will becomeIFluidRunnable
IComponentConfiguration
will becomeIFluidConfiguration
IComponentRouter
will becomeIFluidRouter
IComponentHandleContext
will becomeIFluidHandleContext
IComponentHandle
will becomeIFluidHandle
IComponentSerializer
will becomeIFluidSerializer
IComponentTokenProvider
will becomeIFluidTokenProvider
IComponent
will also become IFluidObject
, and the mime type for for requests will change from fluid/component
to fluid/object
To ensure forward compatability when accessing the above interfaces outside the context of a container e.g. from the host, you should use the nullish coalesing operator (??).
For example
if (response.status !== 200 ||
!(
response.mimeType === "fluid/component" ||
response.mimeType === "fluid/object"
)) {
return undefined;
}
const fluidObject = response.value as IComponent & IFluidObject;
return fluidObject.IComponentHTMLView ?? fluidObject.IFluidHTMLView.
getAbsoluteUrl on the container runtime and component context now returns string | undefined
. undefined
will be returned if the container or component is not attached. You can determine if a component is attached and get its url with the below snippit:
import { waitForAttach } from "@fluidframework/aqueduct";
protected async hasInitialized() {
waitForAttach(this.runtime)
.then(async () => {
const url = await this.context.getAbsoluteUrl(this.url);
this._absoluteUrl = url;
this.emit("stateChanged");
})
.catch(console.error);
}
Renamed TestDeltaStorageService, TestDocumentDeltaConnection, TestDocumentService, TestDocumentServiceFactory and TestResolver
Renamed the following in "@fluidframework/local-driver" since these are used beyond testing:
TestDeltaStorageService
->LocalDeltaStorageService
TestDocumentDeltaConnection
->LocalDocumentDeltaConnection
TestDocumentService
->LocalDocumentService
TestDocumentServiceFactory
->LocalDocumentServiceFactory
TestResolver
->LocalResolver
DocumentDeltaEventManager
has moved to "@fluidframework/test-utils" and renamed to OpProcessingController
.
The registerDocuments
method has been renamed to addDeltaManagers
and should be called with a list of delta managers. Similarly, all the other methods have been updated to be called with delta managers.
So, the usage has now changed to pass in the deltaManager from the object that was passed earlier. For example:
// Old usage
containerDeltaEventManager = new DocumentDeltaEventManager(deltaConnectionServer);
containerDeltaEventManager.registerDocuments(component1.runtime, component2.runtime);
// New usage
opProcessingController = new OpProcessingController(deltaConnectionServer);
opProcessingController.addDeltaManagers(component1.runtime.deltaManager, component2.runtime.deltaManager);
isAttached
is replaced with attachState
property on IContainerContext
, IContainerRuntime
and IComponentContext
.
isAttached
returned true when the entity was either attaching or attached to the storage.
So if attachState
is AttachState.Attaching
or AttachState.Attached
then isAttached
would have returned true.
Attaching is introduced in regards to Detached container where there is a time where state is neither AttachState.Detached nor AttachState.Attached.
- Removed
@fluidframework/local-test-utils
- IComponentHTMLVisual deprecated
- createValueType removed from SharedMap and SharedDirectory
- Sequence snapshot format change
- isLocal api removed
- register/attach api renames on handles, components and dds
- Error handling changes
Removed this package so classes like TestHost
are no longer supported. Please contact us if there were dependencies on this or if any assistance in required to get rid of it.
The IComponentHTMLVisual
interface is deprecated and will be removed in an upcoming release. For multiview scenarios, instead use a pattern like the one demonstrated in the sample in /components/experimental/multiview. This sample demonstrates how to create multiple views for a component.
The createValueType()
method on SharedMap
and SharedDirectory
was deprecated in 0.20, and is now removed in 0.21. If Counter
functionality is required, the @fluidframework/counter
DDS can be used for counter functionality.
isLocal api is removed from the repo. It is now replaced with isAttached which tells that the entity is attached or getting attached to storage. So its meaning is opposite to isLocal.
Register on dds and attach on data store runtime is renamed to bindToContext(). attach on handles is renamed to attachGraph().
ErrorType enum has been broken into 3 distinct enums / layers:
- ContainerErrorType - errors & warnings raised at loader level
- OdspErrorType and R11sErrorType - errors raised by ODSP and R11S drivers.
- Runtime errors, like
"summarizingError"
,"dataCorruptionError"
. This class of errors it not pre-determined and depends on type of container loaded.
ICriticalContainerError.errorType is now a string, not enum, as loader has no visibility into full set of errors that can be potentially raised. Hosting application may package different drivers and open different types of containers, thus making errors list raised at container level dynamic.
Due to a change in the sequence's snapshot format clients running a version less than 0.19 will not be able to load snapshots generated in 0.21. This will affect all sequence types includes shared string, and sparse matrix. If you need to support pre-0.19 clients please contact us for mitigations.
- Value types deprecated on SharedMap and SharedDirectory
- rename @fluidframework/aqueduct-react to @fluidframework/react-inputs
The Counter
value type and createValueType()
method on SharedMap
and SharedDirectory
are now deprecated and will be removed in an upcoming release. Instead, the @fluidframework/counter
DDS can be used for counter functionality.
aqueduct-react is actually just a react library and renamed it to reflect such.
- Container's "error" event
- IUrlResolver change from requestUrl to getAbsoluteUrl
- Package rename from
@microsoft/fluid-*
to@fluidframework/*
Package with the prefix "@microsoft/fluid-" is renamed to "@fluidframework/" to take advanage a separate namespace for Fluid Framework SDK packages.
"error" event is gone. All critical errors are raised on "closed" event via optiona error object. "warning" event is added to expose warnings. Currently it contains summarizer errors and throttling errors.
As we continue to refine our API around detached containers, and component urls, we've renamed IUrlResolver from requestUrl to getAbsoluteUrl
- App Id removed as a parameter to OdspDocumentServiceFactory
- ConsensusRegisterCollection now supports storing handles
- Summarizing errors on parent container
- [OdspDocumentServiceFactory no longer requires a logger] (#OdspDocumentServiceFactory-no-longer-requires-a-logger)
@microsoft/fluid-odsp-driver
no longer requires consumers to pass in an app id as an input. Consumers should simply remove this parameter from the OdspDocumentServiceFactory/OdspDocumentServiceFactoryWithCodeSplit constructor.
ConsensusRegisterCollection will properly serialize/deserialize handles added as values.
The parent container of the summarizing container will now raise "error" events related to summarization problems. These will be of type ISummarizingError
and will have a description indicating either a problem creating the summarizing container, a problem generating a summary, or a nack or ack wait timeout from the server.
The logger will be passed in on createDocumentService or createContainer, no need to pass in one on construction of OdspDocumentServiceFactory.
For older versions' breaking changes, go here