@fluidframework/aqueduct 2.53.0 → 2.60.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/api-report/{aqueduct.legacy.alpha.api.md → aqueduct.legacy.beta.api.md} +14 -14
  3. package/dist/container-runtime-factories/baseContainerRuntimeFactory.d.ts +2 -2
  4. package/dist/container-runtime-factories/baseContainerRuntimeFactory.js +1 -1
  5. package/dist/container-runtime-factories/baseContainerRuntimeFactory.js.map +1 -1
  6. package/dist/container-runtime-factories/containerRuntimeFactoryWithDefaultDataStore.d.ts +2 -2
  7. package/dist/container-runtime-factories/containerRuntimeFactoryWithDefaultDataStore.js +1 -1
  8. package/dist/container-runtime-factories/containerRuntimeFactoryWithDefaultDataStore.js.map +1 -1
  9. package/dist/data-object-factories/dataObjectFactory.d.ts +1 -1
  10. package/dist/data-object-factories/dataObjectFactory.js +1 -1
  11. package/dist/data-object-factories/dataObjectFactory.js.map +1 -1
  12. package/dist/data-object-factories/pureDataObjectFactory.d.ts +2 -4
  13. package/dist/data-object-factories/pureDataObjectFactory.d.ts.map +1 -1
  14. package/dist/data-object-factories/pureDataObjectFactory.js +1 -2
  15. package/dist/data-object-factories/pureDataObjectFactory.js.map +1 -1
  16. package/dist/data-object-factories/treeDataObjectFactory.d.ts +1 -1
  17. package/dist/data-object-factories/treeDataObjectFactory.js +1 -1
  18. package/dist/data-object-factories/treeDataObjectFactory.js.map +1 -1
  19. package/dist/data-objects/dataObject.d.ts +1 -1
  20. package/dist/data-objects/dataObject.js +1 -1
  21. package/dist/data-objects/dataObject.js.map +1 -1
  22. package/dist/data-objects/pureDataObject.d.ts +1 -2
  23. package/dist/data-objects/pureDataObject.d.ts.map +1 -1
  24. package/dist/data-objects/pureDataObject.js +1 -2
  25. package/dist/data-objects/pureDataObject.js.map +1 -1
  26. package/dist/data-objects/treeDataObject.d.ts +1 -1
  27. package/dist/data-objects/treeDataObject.js +1 -1
  28. package/dist/data-objects/treeDataObject.js.map +1 -1
  29. package/dist/data-objects/types.d.ts +2 -4
  30. package/dist/data-objects/types.d.ts.map +1 -1
  31. package/dist/data-objects/types.js.map +1 -1
  32. package/lib/container-runtime-factories/baseContainerRuntimeFactory.d.ts +2 -2
  33. package/lib/container-runtime-factories/baseContainerRuntimeFactory.js +1 -1
  34. package/lib/container-runtime-factories/baseContainerRuntimeFactory.js.map +1 -1
  35. package/lib/container-runtime-factories/containerRuntimeFactoryWithDefaultDataStore.d.ts +2 -2
  36. package/lib/container-runtime-factories/containerRuntimeFactoryWithDefaultDataStore.js +1 -1
  37. package/lib/container-runtime-factories/containerRuntimeFactoryWithDefaultDataStore.js.map +1 -1
  38. package/lib/data-object-factories/dataObjectFactory.d.ts +1 -1
  39. package/lib/data-object-factories/dataObjectFactory.js +1 -1
  40. package/lib/data-object-factories/dataObjectFactory.js.map +1 -1
  41. package/lib/data-object-factories/pureDataObjectFactory.d.ts +2 -4
  42. package/lib/data-object-factories/pureDataObjectFactory.d.ts.map +1 -1
  43. package/lib/data-object-factories/pureDataObjectFactory.js +1 -2
  44. package/lib/data-object-factories/pureDataObjectFactory.js.map +1 -1
  45. package/lib/data-object-factories/treeDataObjectFactory.d.ts +1 -1
  46. package/lib/data-object-factories/treeDataObjectFactory.js +1 -1
  47. package/lib/data-object-factories/treeDataObjectFactory.js.map +1 -1
  48. package/lib/data-objects/dataObject.d.ts +1 -1
  49. package/lib/data-objects/dataObject.js +1 -1
  50. package/lib/data-objects/dataObject.js.map +1 -1
  51. package/lib/data-objects/pureDataObject.d.ts +1 -2
  52. package/lib/data-objects/pureDataObject.d.ts.map +1 -1
  53. package/lib/data-objects/pureDataObject.js +1 -2
  54. package/lib/data-objects/pureDataObject.js.map +1 -1
  55. package/lib/data-objects/treeDataObject.d.ts +1 -1
  56. package/lib/data-objects/treeDataObject.js +1 -1
  57. package/lib/data-objects/treeDataObject.js.map +1 -1
  58. package/lib/data-objects/types.d.ts +2 -4
  59. package/lib/data-objects/types.d.ts.map +1 -1
  60. package/lib/data-objects/types.js.map +1 -1
  61. package/package.json +20 -20
  62. package/src/container-runtime-factories/baseContainerRuntimeFactory.ts +2 -2
  63. package/src/container-runtime-factories/containerRuntimeFactoryWithDefaultDataStore.ts +2 -2
  64. package/src/data-object-factories/dataObjectFactory.ts +1 -1
  65. package/src/data-object-factories/pureDataObjectFactory.ts +2 -4
  66. package/src/data-object-factories/treeDataObjectFactory.ts +1 -1
  67. package/src/data-objects/dataObject.ts +1 -1
  68. package/src/data-objects/pureDataObject.ts +1 -2
  69. package/src/data-objects/treeDataObject.ts +1 -1
  70. package/src/data-objects/types.ts +2 -4
package/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # @fluidframework/aqueduct
2
2
 
3
+ ## 2.60.0
4
+
5
+ Dependency updates only.
6
+
3
7
  ## 2.53.0
4
8
 
5
9
  Dependency updates only.
@@ -1,10 +1,10 @@
1
- ## Alpha API Report File for "@fluidframework/aqueduct"
1
+ ## Beta API Report File for "@fluidframework/aqueduct"
2
2
 
3
3
  > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
4
4
 
5
5
  ```ts
6
6
 
7
- // @alpha @legacy
7
+ // @beta @legacy
8
8
  export class BaseContainerRuntimeFactory extends RuntimeFactoryHelper implements IProvideFluidDataStoreRegistry {
9
9
  constructor(props: BaseContainerRuntimeFactoryProps);
10
10
  protected containerHasInitialized(runtime: IContainerRuntime): Promise<void>;
@@ -15,7 +15,7 @@ export class BaseContainerRuntimeFactory extends RuntimeFactoryHelper implements
15
15
  preInitialize(context: IContainerContext, existing: boolean): Promise<IContainerRuntime & IRuntime>;
16
16
  }
17
17
 
18
- // @alpha @legacy
18
+ // @beta @legacy
19
19
  export interface BaseContainerRuntimeFactoryProps {
20
20
  // @deprecated (undocumented)
21
21
  dependencyContainer?: IFluidDependencySynthesizer;
@@ -27,7 +27,7 @@ export interface BaseContainerRuntimeFactoryProps {
27
27
  runtimeOptions?: IContainerRuntimeOptions;
28
28
  }
29
29
 
30
- // @alpha @legacy
30
+ // @beta @legacy
31
31
  export class ContainerRuntimeFactoryWithDefaultDataStore extends BaseContainerRuntimeFactory {
32
32
  constructor(props: ContainerRuntimeFactoryWithDefaultDataStoreProps);
33
33
  protected containerInitializingFirstTime(runtime: IContainerRuntime): Promise<void>;
@@ -37,7 +37,7 @@ export class ContainerRuntimeFactoryWithDefaultDataStore extends BaseContainerRu
37
37
  protected readonly defaultFactory: IFluidDataStoreFactory;
38
38
  }
39
39
 
40
- // @alpha @legacy
40
+ // @beta @legacy
41
41
  export interface ContainerRuntimeFactoryWithDefaultDataStoreProps {
42
42
  // (undocumented)
43
43
  defaultFactory: IFluidDataStoreFactory;
@@ -50,20 +50,20 @@ export interface ContainerRuntimeFactoryWithDefaultDataStoreProps {
50
50
  runtimeOptions?: IContainerRuntimeOptions;
51
51
  }
52
52
 
53
- // @alpha @legacy
53
+ // @beta @legacy
54
54
  export abstract class DataObject<I extends DataObjectTypes = DataObjectTypes> extends PureDataObject<I> {
55
55
  protected getUninitializedErrorString(item: string): string;
56
56
  initializeInternal(existing: boolean): Promise<void>;
57
57
  protected get root(): ISharedDirectory;
58
58
  }
59
59
 
60
- // @alpha @legacy
60
+ // @beta @legacy
61
61
  export class DataObjectFactory<TObj extends DataObject<I>, I extends DataObjectTypes = DataObjectTypes> extends PureDataObjectFactory<TObj, I> {
62
62
  constructor(type: string, ctor: new (props: IDataObjectProps<I>) => TObj, sharedObjects?: readonly IChannelFactory[], optionalProviders?: FluidObjectSymbolProvider<I["OptionalProviders"]>, registryEntries?: NamedFluidDataStoreRegistryEntries, runtimeFactory?: typeof FluidDataStoreRuntime);
63
63
  constructor(props: DataObjectFactoryProps<TObj, I>);
64
64
  }
65
65
 
66
- // @alpha @legacy
66
+ // @beta @legacy
67
67
  export interface DataObjectFactoryProps<TObj extends PureDataObject<I>, I extends DataObjectTypes = DataObjectTypes> {
68
68
  readonly ctor: new (props: IDataObjectProps<I>) => TObj;
69
69
  readonly optionalProviders?: FluidObjectSymbolProvider<I["OptionalProviders"]>;
@@ -74,14 +74,14 @@ export interface DataObjectFactoryProps<TObj extends PureDataObject<I>, I extend
74
74
  readonly type: string;
75
75
  }
76
76
 
77
- // @alpha @legacy
77
+ // @beta @legacy
78
78
  export interface DataObjectTypes {
79
79
  Events?: IEvent;
80
80
  InitialState?: any;
81
81
  OptionalProviders?: FluidObject;
82
82
  }
83
83
 
84
- // @alpha @legacy (undocumented)
84
+ // @beta @legacy (undocumented)
85
85
  export interface IDataObjectProps<I extends DataObjectTypes = DataObjectTypes> {
86
86
  // (undocumented)
87
87
  readonly context: IFluidDataStoreContext;
@@ -93,7 +93,7 @@ export interface IDataObjectProps<I extends DataObjectTypes = DataObjectTypes> {
93
93
  readonly runtime: IFluidDataStoreRuntime;
94
94
  }
95
95
 
96
- // @alpha @legacy
96
+ // @beta @legacy
97
97
  export abstract class PureDataObject<I extends DataObjectTypes = DataObjectTypes> extends TypedEventEmitter<I["Events"] & IEvent> implements IFluidLoadable, IProvideFluidHandle {
98
98
  constructor(props: IDataObjectProps<I>);
99
99
  protected readonly context: IFluidDataStoreContext;
@@ -118,7 +118,7 @@ export abstract class PureDataObject<I extends DataObjectTypes = DataObjectTypes
118
118
  protected readonly runtime: IFluidDataStoreRuntime;
119
119
  }
120
120
 
121
- // @alpha @legacy
121
+ // @beta @legacy
122
122
  export class PureDataObjectFactory<TObj extends PureDataObject<I>, I extends DataObjectTypes = DataObjectTypes> implements IFluidDataStoreFactory, Partial<IProvideFluidDataStoreRegistry> {
123
123
  constructor(type: string, ctor: new (props: IDataObjectProps<I>) => TObj, sharedObjects?: readonly IChannelFactory[], optionalProviders?: FluidObjectSymbolProvider<I["OptionalProviders"]>, registryEntries?: NamedFluidDataStoreRegistryEntries, runtimeClass?: typeof FluidDataStoreRuntime);
124
124
  constructor(props: DataObjectFactoryProps<TObj, I>);
@@ -139,14 +139,14 @@ export class PureDataObjectFactory<TObj extends PureDataObject<I>, I extends Dat
139
139
  readonly type: string;
140
140
  }
141
141
 
142
- // @alpha @legacy
142
+ // @beta @legacy
143
143
  export abstract class TreeDataObject<TDataObjectTypes extends DataObjectTypes = DataObjectTypes> extends PureDataObject<TDataObjectTypes> {
144
144
  // (undocumented)
145
145
  initializeInternal(existing: boolean): Promise<void>;
146
146
  protected get tree(): ITree;
147
147
  }
148
148
 
149
- // @alpha @legacy
149
+ // @beta @legacy
150
150
  export class TreeDataObjectFactory<TDataObject extends TreeDataObject<TDataObjectTypes>, TDataObjectTypes extends DataObjectTypes = DataObjectTypes> extends PureDataObjectFactory<TDataObject, TDataObjectTypes> {
151
151
  constructor(props: DataObjectFactoryProps<TDataObject, TDataObjectTypes>);
152
152
  }
@@ -13,7 +13,7 @@ import { type IFluidDependencySynthesizer } from "@fluidframework/synthesize/int
13
13
  /**
14
14
  * {@link BaseContainerRuntimeFactory} construction properties.
15
15
  * @legacy
16
- * @alpha
16
+ * @beta
17
17
  */
18
18
  export interface BaseContainerRuntimeFactoryProps {
19
19
  /**
@@ -49,7 +49,7 @@ export interface BaseContainerRuntimeFactoryProps {
49
49
  * request handlers, runtimeOptions, and entryPoint initialization function.
50
50
  * It can be subclassed to implement a first-time initialization procedure for the containers it creates.
51
51
  * @legacy
52
- * @alpha
52
+ * @beta
53
53
  */
54
54
  export declare class BaseContainerRuntimeFactory extends RuntimeFactoryHelper implements IProvideFluidDataStoreRegistry {
55
55
  /**
@@ -14,7 +14,7 @@ const internal_4 = require("@fluidframework/synthesize/internal");
14
14
  * request handlers, runtimeOptions, and entryPoint initialization function.
15
15
  * It can be subclassed to implement a first-time initialization procedure for the containers it creates.
16
16
  * @legacy
17
- * @alpha
17
+ * @beta
18
18
  */
19
19
  class BaseContainerRuntimeFactory extends internal_3.RuntimeFactoryHelper {
20
20
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"baseContainerRuntimeFactory.js","sourceRoot":"","sources":["../../src/container-runtime-factories/baseContainerRuntimeFact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ACjC,IAAI,CAAC,mBAAmB,EACxB,KAAK,CAAC,2BAA2B,CACjC,CAAC;YACF,KAAK,CAAC,2BAA2B,GAAG,EAAE,CAAC;QACxC,CAAC;QAED,OAAO,IAAA,+BAAoB,EAAC;YAC3B,OAAO;YACP,QAAQ;YACR,cAAc,EAAE,IAAI,CAAC,cAAc;YACnC,eAAe,EAAE,IAAI,CAAC,eAAe;YACrC,cAAc,EAAE,KAAK;YACrB,gDAAgD;YAChD,cAAc,EAAE,IAAA,qCAA0B,EAAC,GAAG,IAAI,CAAC,eAAe,CAAC;YACnE,iBAAiB,EAAE,IAAI,CAAC,iBAAiB;YACzC,mBAAmB,EAAE,IAAI,CAAC,mBAAmB;SAC7C,CAAC,CAAC;IACJ,CAAC;IAED;;;;OAIG;IACO,KAAK,CAAC,8BAA8B,CAAC,OAA0B,IAAkB,CAAC;IAE5F;;;;OAIG;IACO,KAAK,CAAC,uBAAuB,CAAC,OAA0B,IAAkB,CAAC;CACrF;AA/FD,kEA+FC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type {\n\tIContainerContext,\n\tIRuntime,\n} from \"@fluidframework/container-definitions/internal\";\nimport {\n\tFluidDataStoreRegistry,\n\tloadContainerRuntime,\n\ttype IContainerRuntimeOptions,\n\ttype MinimumVersionForCollab,\n} from \"@fluidframework/container-runtime/internal\";\nimport type { IContainerRuntime } from \"@fluidframework/container-runtime-definitions/internal\";\nimport type { FluidObject } from \"@fluidframework/core-interfaces\";\nimport {\n\t// eslint-disable-next-line import/no-deprecated\n\ttype RuntimeRequestHandler,\n\t// eslint-disable-next-line import/no-deprecated\n\tbuildRuntimeRequestHandler,\n} from \"@fluidframework/request-handler/internal\";\nimport type {\n\tIFluidDataStoreRegistry,\n\tIProvideFluidDataStoreRegistry,\n\tNamedFluidDataStoreRegistryEntries,\n} from \"@fluidframework/runtime-definitions/internal\";\nimport { RuntimeFactoryHelper } from \"@fluidframework/runtime-utils/internal\";\nimport {\n\tDependencyContainer,\n\ttype IFluidDependencySynthesizer,\n\ttype IProvideFluidDependencySynthesizer,\n} from \"@fluidframework/synthesize/internal\";\n\n/**\n * {@link BaseContainerRuntimeFactory} construction properties.\n * @legacy\n * @alpha\n */\nexport interface BaseContainerRuntimeFactoryProps {\n\t/**\n\t * The data store registry for containers produced.\n\t */\n\tregistryEntries: NamedFluidDataStoreRegistryEntries;\n\t/**\n\t * @deprecated Will be removed in a future release.\n\t */\n\tdependencyContainer?: IFluidDependencySynthesizer;\n\t/**\n\t * Request handlers for containers produced.\n\t * @deprecated Will be removed once Loader LTS version is \"2.0.0-internal.7.0.0\". Migrate all usage of IFluidRouter to the \"entryPoint\" pattern. Refer to Removing-IFluidRouter.md\n\t */\n\t// eslint-disable-next-line import/no-deprecated\n\trequestHandlers?: RuntimeRequestHandler[];\n\t/**\n\t * The runtime options passed to the ContainerRuntime when instantiating it\n\t */\n\truntimeOptions?: IContainerRuntimeOptions;\n\t/**\n\t * Function that will initialize the entryPoint of the ContainerRuntime instances\n\t * created with this factory\n\t */\n\tprovideEntryPoint: (runtime: IContainerRuntime) => Promise<FluidObject>;\n\t/**\n\t * The minVersionForCollab passed to the ContainerRuntime when instantiating it.\n\t * See {@link @fluidframework/container-runtime#LoadContainerRuntimeParams} for more details on this property.\n\t */\n\tminVersionForCollab?: MinimumVersionForCollab | undefined;\n}\n\n/**\n * BaseContainerRuntimeFactory produces container runtimes with the specified data store and service registries,\n * request handlers, runtimeOptions, and entryPoint initialization function.\n * It can be subclassed to implement a first-time initialization procedure for the containers it creates.\n * @legacy\n * @alpha\n */\nexport class BaseContainerRuntimeFactory\n\textends RuntimeFactoryHelper\n\timplements IProvideFluidDataStoreRegistry\n{\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IProvideFluidDataStoreRegistry.IFluidDataStoreRegistry}\n\t */\n\tpublic get IFluidDataStoreRegistry(): IFluidDataStoreRegistry {\n\t\treturn this.registry;\n\t}\n\tprivate readonly registry: IFluidDataStoreRegistry;\n\n\tprivate readonly registryEntries: NamedFluidDataStoreRegistryEntries;\n\tprivate readonly dependencyContainer?: IFluidDependencySynthesizer;\n\tprivate readonly runtimeOptions?: IContainerRuntimeOptions;\n\t// eslint-disable-next-line import/no-deprecated\n\tprivate readonly requestHandlers: RuntimeRequestHandler[];\n\tprivate readonly provideEntryPoint: (runtime: IContainerRuntime) => Promise<FluidObject>;\n\tprivate readonly minVersionForCollab: MinimumVersionForCollab | undefined;\n\n\tpublic constructor(props: BaseContainerRuntimeFactoryProps) {\n\t\tsuper();\n\n\t\tthis.registryEntries = props.registryEntries;\n\t\tthis.dependencyContainer = props.dependencyContainer;\n\t\tthis.runtimeOptions = props.runtimeOptions;\n\t\tthis.provideEntryPoint = props.provideEntryPoint;\n\t\tthis.requestHandlers = props.requestHandlers ?? [];\n\t\tthis.registry = new FluidDataStoreRegistry(this.registryEntries);\n\t\tthis.minVersionForCollab = props.minVersionForCollab;\n\t}\n\n\t/**\n\t * Called the one time the container is created, and not on any subsequent load.\n\t * i.e. only when it's initialized on the client that first created it\n\t * @param runtime - The runtime for the container being initialized\n\t */\n\tpublic async instantiateFirstTime(runtime: IContainerRuntime): Promise<void> {\n\t\tawait this.containerInitializingFirstTime(runtime);\n\t\tawait this.containerHasInitialized(runtime);\n\t}\n\n\t/**\n\t * Called every time the container runtime is loaded for an existing container.\n\t * i.e. every time it's initialized _except_ for when it is first created\n\t * @param runtime - The runtime for the container being initialized\n\t */\n\tpublic async instantiateFromExisting(runtime: IContainerRuntime): Promise<void> {\n\t\tawait this.containerHasInitialized(runtime);\n\t}\n\n\t/**\n\t * Called at the start of initializing a container, to create the container runtime instance.\n\t * @param context - The context for the container being initialized\n\t * @param existing - Whether the container already exists and is being loaded (else it's being created new just now)\n\t */\n\tpublic async preInitialize(\n\t\tcontext: IContainerContext,\n\t\texisting: boolean,\n\t): Promise<IContainerRuntime & IRuntime> {\n\t\tconst scope: Partial<IProvideFluidDependencySynthesizer> = context.scope;\n\t\tif (this.dependencyContainer) {\n\t\t\tconst dc = new DependencyContainer<FluidObject>(\n\t\t\t\tthis.dependencyContainer,\n\t\t\t\tscope.IFluidDependencySynthesizer,\n\t\t\t);\n\t\t\tscope.IFluidDependencySynthesizer = dc;\n\t\t}\n\n\t\treturn loadContainerRuntime({\n\t\t\tcontext,\n\t\t\texisting,\n\t\t\truntimeOptions: this.runtimeOptions,\n\t\t\tregistryEntries: this.registryEntries,\n\t\t\tcontainerScope: scope,\n\t\t\t// eslint-disable-next-line import/no-deprecated\n\t\t\trequestHandler: buildRuntimeRequestHandler(...this.requestHandlers),\n\t\t\tprovideEntryPoint: this.provideEntryPoint,\n\t\t\tminVersionForCollab: this.minVersionForCollab,\n\t\t});\n\t}\n\n\t/**\n\t * Subclasses may override containerInitializingFirstTime to perform any setup steps at the time the container\n\t * is created. This likely includes creating any initial data stores that are expected to be there at the outset.\n\t * @param runtime - The container runtime for the container being initialized\n\t */\n\tprotected async containerInitializingFirstTime(runtime: IContainerRuntime): Promise<void> {}\n\n\t/**\n\t * Subclasses may override containerHasInitialized to perform any steps after the container has initialized.\n\t * This likely includes loading any data stores that are expected to be there at the outset.\n\t * @param runtime - The container runtime for the container being initialized\n\t */\n\tprotected async containerHasInitialized(runtime: IContainerRuntime): Promise<void> {}\n}\n"]}
1
+ {"version":3,"file":"baseContainerRuntimeFactory.js","sourceRoot":"","sources":["../../src/container-runtime-factories/baseContainerRuntimeFactory.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAMH,yEAKoD;AAGpD,uEAKkD;AAMlD,qEAA8E;AAC9E,kEAI6C;AAsC7C;;;;;;GAMG;AACH,MAAa,2BACZ,SAAQ,+BAAoB;IAG5B;;OAEG;IACH,IAAW,uBAAuB;QACjC,OAAO,IAAI,CAAC,QAAQ,CAAC;IACtB,CAAC;IAWD,YAAmB,KAAuC;QACzD,KAAK,EAAE,CAAC;QAER,IAAI,CAAC,eAAe,GAAG,KAAK,CAAC,eAAe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AG,IAAI,CAAC,eAAe,CAAC;YACnE,iBAAiB,EAAE,IAAI,CAAC,iBAAiB;YACzC,mBAAmB,EAAE,IAAI,CAAC,mBAAmB;SAC7C,CAAC,CAAC;IACJ,CAAC;IAED;;;;OAIG;IACO,KAAK,CAAC,8BAA8B,CAAC,OAA0B,IAAkB,CAAC;IAE5F;;;;OAIG;IACO,KAAK,CAAC,uBAAuB,CAAC,OAA0B,IAAkB,CAAC;CACrF;AA/FD,kEA+FC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type {\n\tIContainerContext,\n\tIRuntime,\n} from \"@fluidframework/container-definitions/internal\";\nimport {\n\tFluidDataStoreRegistry,\n\tloadContainerRuntime,\n\ttype IContainerRuntimeOptions,\n\ttype MinimumVersionForCollab,\n} from \"@fluidframework/container-runtime/internal\";\nimport type { IContainerRuntime } from \"@fluidframework/container-runtime-definitions/internal\";\nimport type { FluidObject } from \"@fluidframework/core-interfaces\";\nimport {\n\t// eslint-disable-next-line import/no-deprecated\n\ttype RuntimeRequestHandler,\n\t// eslint-disable-next-line import/no-deprecated\n\tbuildRuntimeRequestHandler,\n} from \"@fluidframework/request-handler/internal\";\nimport type {\n\tIFluidDataStoreRegistry,\n\tIProvideFluidDataStoreRegistry,\n\tNamedFluidDataStoreRegistryEntries,\n} from \"@fluidframework/runtime-definitions/internal\";\nimport { RuntimeFactoryHelper } from \"@fluidframework/runtime-utils/internal\";\nimport {\n\tDependencyContainer,\n\ttype IFluidDependencySynthesizer,\n\ttype IProvideFluidDependencySynthesizer,\n} from \"@fluidframework/synthesize/internal\";\n\n/**\n * {@link BaseContainerRuntimeFactory} construction properties.\n * @legacy\n * @beta\n */\nexport interface BaseContainerRuntimeFactoryProps {\n\t/**\n\t * The data store registry for containers produced.\n\t */\n\tregistryEntries: NamedFluidDataStoreRegistryEntries;\n\t/**\n\t * @deprecated Will be removed in a future release.\n\t */\n\tdependencyContainer?: IFluidDependencySynthesizer;\n\t/**\n\t * Request handlers for containers produced.\n\t * @deprecated Will be removed once Loader LTS version is \"2.0.0-internal.7.0.0\". Migrate all usage of IFluidRouter to the \"entryPoint\" pattern. Refer to Removing-IFluidRouter.md\n\t */\n\t// eslint-disable-next-line import/no-deprecated\n\trequestHandlers?: RuntimeRequestHandler[];\n\t/**\n\t * The runtime options passed to the ContainerRuntime when instantiating it\n\t */\n\truntimeOptions?: IContainerRuntimeOptions;\n\t/**\n\t * Function that will initialize the entryPoint of the ContainerRuntime instances\n\t * created with this factory\n\t */\n\tprovideEntryPoint: (runtime: IContainerRuntime) => Promise<FluidObject>;\n\t/**\n\t * The minVersionForCollab passed to the ContainerRuntime when instantiating it.\n\t * See {@link @fluidframework/container-runtime#LoadContainerRuntimeParams} for more details on this property.\n\t */\n\tminVersionForCollab?: MinimumVersionForCollab | undefined;\n}\n\n/**\n * BaseContainerRuntimeFactory produces container runtimes with the specified data store and service registries,\n * request handlers, runtimeOptions, and entryPoint initialization function.\n * It can be subclassed to implement a first-time initialization procedure for the containers it creates.\n * @legacy\n * @beta\n */\nexport class BaseContainerRuntimeFactory\n\textends RuntimeFactoryHelper\n\timplements IProvideFluidDataStoreRegistry\n{\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IProvideFluidDataStoreRegistry.IFluidDataStoreRegistry}\n\t */\n\tpublic get IFluidDataStoreRegistry(): IFluidDataStoreRegistry {\n\t\treturn this.registry;\n\t}\n\tprivate readonly registry: IFluidDataStoreRegistry;\n\n\tprivate readonly registryEntries: NamedFluidDataStoreRegistryEntries;\n\tprivate readonly dependencyContainer?: IFluidDependencySynthesizer;\n\tprivate readonly runtimeOptions?: IContainerRuntimeOptions;\n\t// eslint-disable-next-line import/no-deprecated\n\tprivate readonly requestHandlers: RuntimeRequestHandler[];\n\tprivate readonly provideEntryPoint: (runtime: IContainerRuntime) => Promise<FluidObject>;\n\tprivate readonly minVersionForCollab: MinimumVersionForCollab | undefined;\n\n\tpublic constructor(props: BaseContainerRuntimeFactoryProps) {\n\t\tsuper();\n\n\t\tthis.registryEntries = props.registryEntries;\n\t\tthis.dependencyContainer = props.dependencyContainer;\n\t\tthis.runtimeOptions = props.runtimeOptions;\n\t\tthis.provideEntryPoint = props.provideEntryPoint;\n\t\tthis.requestHandlers = props.requestHandlers ?? [];\n\t\tthis.registry = new FluidDataStoreRegistry(this.registryEntries);\n\t\tthis.minVersionForCollab = props.minVersionForCollab;\n\t}\n\n\t/**\n\t * Called the one time the container is created, and not on any subsequent load.\n\t * i.e. only when it's initialized on the client that first created it\n\t * @param runtime - The runtime for the container being initialized\n\t */\n\tpublic async instantiateFirstTime(runtime: IContainerRuntime): Promise<void> {\n\t\tawait this.containerInitializingFirstTime(runtime);\n\t\tawait this.containerHasInitialized(runtime);\n\t}\n\n\t/**\n\t * Called every time the container runtime is loaded for an existing container.\n\t * i.e. every time it's initialized _except_ for when it is first created\n\t * @param runtime - The runtime for the container being initialized\n\t */\n\tpublic async instantiateFromExisting(runtime: IContainerRuntime): Promise<void> {\n\t\tawait this.containerHasInitialized(runtime);\n\t}\n\n\t/**\n\t * Called at the start of initializing a container, to create the container runtime instance.\n\t * @param context - The context for the container being initialized\n\t * @param existing - Whether the container already exists and is being loaded (else it's being created new just now)\n\t */\n\tpublic async preInitialize(\n\t\tcontext: IContainerContext,\n\t\texisting: boolean,\n\t): Promise<IContainerRuntime & IRuntime> {\n\t\tconst scope: Partial<IProvideFluidDependencySynthesizer> = context.scope;\n\t\tif (this.dependencyContainer) {\n\t\t\tconst dc = new DependencyContainer<FluidObject>(\n\t\t\t\tthis.dependencyContainer,\n\t\t\t\tscope.IFluidDependencySynthesizer,\n\t\t\t);\n\t\t\tscope.IFluidDependencySynthesizer = dc;\n\t\t}\n\n\t\treturn loadContainerRuntime({\n\t\t\tcontext,\n\t\t\texisting,\n\t\t\truntimeOptions: this.runtimeOptions,\n\t\t\tregistryEntries: this.registryEntries,\n\t\t\tcontainerScope: scope,\n\t\t\t// eslint-disable-next-line import/no-deprecated\n\t\t\trequestHandler: buildRuntimeRequestHandler(...this.requestHandlers),\n\t\t\tprovideEntryPoint: this.provideEntryPoint,\n\t\t\tminVersionForCollab: this.minVersionForCollab,\n\t\t});\n\t}\n\n\t/**\n\t * Subclasses may override containerInitializingFirstTime to perform any setup steps at the time the container\n\t * is created. This likely includes creating any initial data stores that are expected to be there at the outset.\n\t * @param runtime - The container runtime for the container being initialized\n\t */\n\tprotected async containerInitializingFirstTime(runtime: IContainerRuntime): Promise<void> {}\n\n\t/**\n\t * Subclasses may override containerHasInitialized to perform any steps after the container has initialized.\n\t * This likely includes loading any data stores that are expected to be there at the outset.\n\t * @param runtime - The container runtime for the container being initialized\n\t */\n\tprotected async containerHasInitialized(runtime: IContainerRuntime): Promise<void> {}\n}\n"]}
@@ -12,7 +12,7 @@ import { BaseContainerRuntimeFactory } from "./baseContainerRuntimeFactory.js";
12
12
  /**
13
13
  * {@link ContainerRuntimeFactoryWithDefaultDataStore} construction properties.
14
14
  * @legacy
15
- * @alpha
15
+ * @beta
16
16
  */
17
17
  export interface ContainerRuntimeFactoryWithDefaultDataStoreProps {
18
18
  defaultFactory: IFluidDataStoreFactory;
@@ -45,7 +45,7 @@ export interface ContainerRuntimeFactoryWithDefaultDataStoreProps {
45
45
  *
46
46
  * This factory should be exposed as fluidExport off the entry point to your module.
47
47
  * @legacy
48
- * @alpha
48
+ * @beta
49
49
  */
50
50
  export declare class ContainerRuntimeFactoryWithDefaultDataStore extends BaseContainerRuntimeFactory {
51
51
  static readonly defaultDataStoreId = "default";
@@ -21,7 +21,7 @@ async function getDefaultFluidObject(runtime) {
21
21
  *
22
22
  * This factory should be exposed as fluidExport off the entry point to your module.
23
23
  * @legacy
24
- * @alpha
24
+ * @beta
25
25
  */
26
26
  class ContainerRuntimeFactoryWithDefaultDataStore extends baseContainerRuntimeFactory_js_1.BaseContainerRuntimeFactory {
27
27
  constructor(props) {
@@ -1 +1 @@
1
- {"version":3,"file":"containerRuntimeFactoryWithDefaultDataStore.js","sourceRoot":"","sources":["../../src/container-runtime-factories/containerRuntimeFactoryWithDefaultDataStore.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAeH,qEAAuE;AAGvE,qFAA+E;AAE/E,MAAM,kBAAkB,GAAG,SAAS,CAAC;AAErC,KAAK,UAAU,qBAAqB,CAAC,OAA0B;IAC9D,MAAM,UAAU,GAAG,MAAM,OAAO,CAAC,6BAA6B,CAAC,SAAS,CAAC,CAAC;IAC1E,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC9B,MAAM,IAAI,KAAK,CAAC,8BAA8B,CAAC,CAAC;IACjD,CAAC;IACD,OAAO,UAAU,CAAC,GAAG,EAAE,CAAC;AACzB,CAAC;AAkCD;;;;;;;GAOG;AACH,MAAa,2CAA4C,SAAQ,4DAA2B;IAK3F,YAAmB,KAAuD;QACzE,MAAM,eAAe,GAAG,KAAK,CAAC,eAAe,IAAI,EAAE,CAAC;QACpD,MAAM,iBAAiB,GAAG,KAAK,CAAC,iBAAiB,IAAI,qBAAqB,CAAC;QAE3E,MAAM,gBAAgB,GAAG,KAAK,EAC7B,OAAiB,EACjB,OAA0B,EAEO,EAAE;YACnC,MAAM,MAAM,GAAG,wBAAa,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;YAC7C,IAAI,MAAM,CAAC,SAAS,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;gBACnC,wEAAwE;gBACxE,gDAAgD;gBAChD,OAAQ,OAAyD,CAAC,aAAa,CAAC;oBAC/E,GAAG,EAAE,IAAI,kBAAkB,GAAG,MAAM,CAAC,KAAK,EAAE;oBAC5C,OAAO,EAAE,OAAO,CAAC,OAAO;iBACxB,CAAC,CAAC;YACJ,CAAC;YACD,OAAO,SAAS,CAAC,CAAC,kBAAkB;QACrC,CAAC,CAAC;QAEF,KAAK,CAAC;YACL,GAAG,KAAK;YACR,eAAe,EAAE,CAAC,gBAAgB,EAAE,GAAG,eAAe,CAAC;YACvD,iBAAiB;SACjB,CAAC,CAAC;QAEH,IAAI,CAAC,cAAc,GAAG,KAAK,CAAC,cAAc,CAAC;IAC5C,CAAC;IAED;;OAEG;IACO,KAAK,CAAC,8BAA8B,CAAC,OAA0B;QACxE,MAAM,SAAS,GAAG,MAAM,OAAO,CAAC,eAAe,CAAC,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;QAC1E,MAAM,SAAS,CAAC,WAAW,CAAC,kBAAkB,CAAC,CAAC;IACjD,CAAC;;AAzCF,kGA0CC;AAzCuB,8DAAkB,GAAG,kBAAkB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IContainerRuntimeOptions } from \"@fluidframework/container-runtime/internal\";\nimport type {\n\tIContainerRuntime,\n\t// eslint-disable-next-line import/no-deprecated\n\tIContainerRuntimeWithResolveHandle_Deprecated,\n} from \"@fluidframework/container-runtime-definitions/internal\";\nimport type { FluidObject, IRequest, IResponse } from \"@fluidframework/core-interfaces\";\n// eslint-disable-next-line import/no-deprecated\nimport type { RuntimeRequestHandler } from \"@fluidframework/request-handler/internal\";\nimport type {\n\tIFluidDataStoreFactory,\n\tNamedFluidDataStoreRegistryEntries,\n} from \"@fluidframework/runtime-definitions/internal\";\nimport { RequestParser } from \"@fluidframework/runtime-utils/internal\";\nimport type { IFluidDependencySynthesizer } from \"@fluidframework/synthesize/internal\";\n\nimport { BaseContainerRuntimeFactory } from \"./baseContainerRuntimeFactory.js\";\n\nconst defaultDataStoreId = \"default\";\n\nasync function getDefaultFluidObject(runtime: IContainerRuntime): Promise<FluidObject> {\n\tconst entryPoint = await runtime.getAliasedDataStoreEntryPoint(\"default\");\n\tif (entryPoint === undefined) {\n\t\tthrow new Error(\"default dataStore must exist\");\n\t}\n\treturn entryPoint.get();\n}\n\n/**\n * {@link ContainerRuntimeFactoryWithDefaultDataStore} construction properties.\n * @legacy\n * @alpha\n */\nexport interface ContainerRuntimeFactoryWithDefaultDataStoreProps {\n\tdefaultFactory: IFluidDataStoreFactory;\n\t/**\n\t * The data store registry for containers produced.\n\t */\n\tregistryEntries: NamedFluidDataStoreRegistryEntries;\n\t/**\n\t * @deprecated Will be removed in a future release.\n\t */\n\tdependencyContainer?: IFluidDependencySynthesizer;\n\t/**\n\t * Request handlers for containers produced.\n\t * @deprecated Will be removed once Loader LTS version is \"2.0.0-internal.7.0.0\". Migrate all usage of IFluidRouter to the \"entryPoint\" pattern. Refer to Removing-IFluidRouter.md\n\t */\n\t// eslint-disable-next-line import/no-deprecated\n\trequestHandlers?: RuntimeRequestHandler[];\n\t/**\n\t * The runtime options passed to the IContainerRuntime when instantiating it\n\t */\n\truntimeOptions?: IContainerRuntimeOptions;\n\t/**\n\t * Function that will initialize the entryPoint of the IContainerRuntime instances\n\t * created with this factory\n\t */\n\tprovideEntryPoint?: (runtime: IContainerRuntime) => Promise<FluidObject>;\n}\n\n/**\n * A ContainerRuntimeFactory that initializes Containers with a single default data store, which can be requested from\n * the container with an empty URL.\n *\n * This factory should be exposed as fluidExport off the entry point to your module.\n * @legacy\n * @alpha\n */\nexport class ContainerRuntimeFactoryWithDefaultDataStore extends BaseContainerRuntimeFactory {\n\tpublic static readonly defaultDataStoreId = defaultDataStoreId;\n\n\tprotected readonly defaultFactory: IFluidDataStoreFactory;\n\n\tpublic constructor(props: ContainerRuntimeFactoryWithDefaultDataStoreProps) {\n\t\tconst requestHandlers = props.requestHandlers ?? [];\n\t\tconst provideEntryPoint = props.provideEntryPoint ?? getDefaultFluidObject;\n\n\t\tconst getDefaultObject = async (\n\t\t\trequest: IRequest,\n\t\t\truntime: IContainerRuntime,\n\t\t\t// eslint-disable-next-line unicorn/consistent-function-scoping\n\t\t): Promise<IResponse | undefined> => {\n\t\t\tconst parser = RequestParser.create(request);\n\t\t\tif (parser.pathParts.length === 0) {\n\t\t\t\t// This cast is safe as loadContainerRuntime is called in the base class\n\t\t\t\t// eslint-disable-next-line import/no-deprecated\n\t\t\t\treturn (runtime as IContainerRuntimeWithResolveHandle_Deprecated).resolveHandle({\n\t\t\t\t\turl: `/${defaultDataStoreId}${parser.query}`,\n\t\t\t\t\theaders: request.headers,\n\t\t\t\t});\n\t\t\t}\n\t\t\treturn undefined; // continue search\n\t\t};\n\n\t\tsuper({\n\t\t\t...props,\n\t\t\trequestHandlers: [getDefaultObject, ...requestHandlers],\n\t\t\tprovideEntryPoint,\n\t\t});\n\n\t\tthis.defaultFactory = props.defaultFactory;\n\t}\n\n\t/**\n\t * {@inheritDoc BaseContainerRuntimeFactory.containerInitializingFirstTime}\n\t */\n\tprotected async containerInitializingFirstTime(runtime: IContainerRuntime): Promise<void> {\n\t\tconst dataStore = await runtime.createDataStore(this.defaultFactory.type);\n\t\tawait dataStore.trySetAlias(defaultDataStoreId);\n\t}\n}\n"]}
1
+ {"version":3,"file":"containerRuntimeFactoryWithDefaultDataStore.js","sourceRoot":"","sources":["../../src/container-runtime-factories/containerRuntimeFactoryWithDefaultDataStore.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAeH,qEAAuE;AAGvE,qFAA+E;AAE/E,MAAM,kBAAkB,GAAG,SAAS,CAAC;AAErC,KAAK,UAAU,qBAAqB,CAAC,OAA0B;IAC9D,MAAM,UAAU,GAAG,MAAM,OAAO,CAAC,6BAA6B,CAAC,SAAS,CAAC,CAAC;IAC1E,IAAI,UAAU,KAAK,SAAS,EAAE,CAAC;QAC9B,MAAM,IAAI,KAAK,CAAC,8BAA8B,CAAC,CAAC;IACjD,CAAC;IACD,OAAO,UAAU,CAAC,GAAG,EAAE,CAAC;AACzB,CAAC;AAkCD;;;;;;;GAOG;AACH,MAAa,2CAA4C,SAAQ,4DAA2B;IAK3F,YAAmB,KAAuD;QACzE,MAAM,eAAe,GAAG,KAAK,CAAC,eAAe,IAAI,EAAE,CAAC;QACpD,MAAM,iBAAiB,GAAG,KAAK,CAAC,iBAAiB,IAAI,qBAAqB,CAAC;QAE3E,MAAM,gBAAgB,GAAG,KAAK,EAC7B,OAAiB,EACjB,OAA0B,EAEO,EAAE;YACnC,MAAM,MAAM,GAAG,wBAAa,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;YAC7C,IAAI,MAAM,CAAC,SAAS,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;gBACnC,wEAAwE;gBACxE,gDAAgD;gBAChD,OAAQ,OAAyD,CAAC,aAAa,CAAC;oBAC/E,GAAG,EAAE,IAAI,kBAAkB,GAAG,MAAM,CAAC,KAAK,EAAE;oBAC5C,OAAO,EAAE,OAAO,CAAC,OAAO;iBACxB,CAAC,CAAC;YACJ,CAAC;YACD,OAAO,SAAS,CAAC,CAAC,kBAAkB;QACrC,CAAC,CAAC;QAEF,KAAK,CAAC;YACL,GAAG,KAAK;YACR,eAAe,EAAE,CAAC,gBAAgB,EAAE,GAAG,eAAe,CAAC;YACvD,iBAAiB;SACjB,CAAC,CAAC;QAEH,IAAI,CAAC,cAAc,GAAG,KAAK,CAAC,cAAc,CAAC;IAC5C,CAAC;IAED;;OAEG;IACO,KAAK,CAAC,8BAA8B,CAAC,OAA0B;QACxE,MAAM,SAAS,GAAG,MAAM,OAAO,CAAC,eAAe,CAAC,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,CAAC;QAC1E,MAAM,SAAS,CAAC,WAAW,CAAC,kBAAkB,CAAC,CAAC;IACjD,CAAC;;AAzCF,kGA0CC;AAzCuB,8DAAkB,GAAG,kBAAkB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { IContainerRuntimeOptions } from \"@fluidframework/container-runtime/internal\";\nimport type {\n\tIContainerRuntime,\n\t// eslint-disable-next-line import/no-deprecated\n\tIContainerRuntimeWithResolveHandle_Deprecated,\n} from \"@fluidframework/container-runtime-definitions/internal\";\nimport type { FluidObject, IRequest, IResponse } from \"@fluidframework/core-interfaces\";\n// eslint-disable-next-line import/no-deprecated\nimport type { RuntimeRequestHandler } from \"@fluidframework/request-handler/internal\";\nimport type {\n\tIFluidDataStoreFactory,\n\tNamedFluidDataStoreRegistryEntries,\n} from \"@fluidframework/runtime-definitions/internal\";\nimport { RequestParser } from \"@fluidframework/runtime-utils/internal\";\nimport type { IFluidDependencySynthesizer } from \"@fluidframework/synthesize/internal\";\n\nimport { BaseContainerRuntimeFactory } from \"./baseContainerRuntimeFactory.js\";\n\nconst defaultDataStoreId = \"default\";\n\nasync function getDefaultFluidObject(runtime: IContainerRuntime): Promise<FluidObject> {\n\tconst entryPoint = await runtime.getAliasedDataStoreEntryPoint(\"default\");\n\tif (entryPoint === undefined) {\n\t\tthrow new Error(\"default dataStore must exist\");\n\t}\n\treturn entryPoint.get();\n}\n\n/**\n * {@link ContainerRuntimeFactoryWithDefaultDataStore} construction properties.\n * @legacy\n * @beta\n */\nexport interface ContainerRuntimeFactoryWithDefaultDataStoreProps {\n\tdefaultFactory: IFluidDataStoreFactory;\n\t/**\n\t * The data store registry for containers produced.\n\t */\n\tregistryEntries: NamedFluidDataStoreRegistryEntries;\n\t/**\n\t * @deprecated Will be removed in a future release.\n\t */\n\tdependencyContainer?: IFluidDependencySynthesizer;\n\t/**\n\t * Request handlers for containers produced.\n\t * @deprecated Will be removed once Loader LTS version is \"2.0.0-internal.7.0.0\". Migrate all usage of IFluidRouter to the \"entryPoint\" pattern. Refer to Removing-IFluidRouter.md\n\t */\n\t// eslint-disable-next-line import/no-deprecated\n\trequestHandlers?: RuntimeRequestHandler[];\n\t/**\n\t * The runtime options passed to the IContainerRuntime when instantiating it\n\t */\n\truntimeOptions?: IContainerRuntimeOptions;\n\t/**\n\t * Function that will initialize the entryPoint of the IContainerRuntime instances\n\t * created with this factory\n\t */\n\tprovideEntryPoint?: (runtime: IContainerRuntime) => Promise<FluidObject>;\n}\n\n/**\n * A ContainerRuntimeFactory that initializes Containers with a single default data store, which can be requested from\n * the container with an empty URL.\n *\n * This factory should be exposed as fluidExport off the entry point to your module.\n * @legacy\n * @beta\n */\nexport class ContainerRuntimeFactoryWithDefaultDataStore extends BaseContainerRuntimeFactory {\n\tpublic static readonly defaultDataStoreId = defaultDataStoreId;\n\n\tprotected readonly defaultFactory: IFluidDataStoreFactory;\n\n\tpublic constructor(props: ContainerRuntimeFactoryWithDefaultDataStoreProps) {\n\t\tconst requestHandlers = props.requestHandlers ?? [];\n\t\tconst provideEntryPoint = props.provideEntryPoint ?? getDefaultFluidObject;\n\n\t\tconst getDefaultObject = async (\n\t\t\trequest: IRequest,\n\t\t\truntime: IContainerRuntime,\n\t\t\t// eslint-disable-next-line unicorn/consistent-function-scoping\n\t\t): Promise<IResponse | undefined> => {\n\t\t\tconst parser = RequestParser.create(request);\n\t\t\tif (parser.pathParts.length === 0) {\n\t\t\t\t// This cast is safe as loadContainerRuntime is called in the base class\n\t\t\t\t// eslint-disable-next-line import/no-deprecated\n\t\t\t\treturn (runtime as IContainerRuntimeWithResolveHandle_Deprecated).resolveHandle({\n\t\t\t\t\turl: `/${defaultDataStoreId}${parser.query}`,\n\t\t\t\t\theaders: request.headers,\n\t\t\t\t});\n\t\t\t}\n\t\t\treturn undefined; // continue search\n\t\t};\n\n\t\tsuper({\n\t\t\t...props,\n\t\t\trequestHandlers: [getDefaultObject, ...requestHandlers],\n\t\t\tprovideEntryPoint,\n\t\t});\n\n\t\tthis.defaultFactory = props.defaultFactory;\n\t}\n\n\t/**\n\t * {@inheritDoc BaseContainerRuntimeFactory.containerInitializingFirstTime}\n\t */\n\tprotected async containerInitializingFirstTime(runtime: IContainerRuntime): Promise<void> {\n\t\tconst dataStore = await runtime.createDataStore(this.defaultFactory.type);\n\t\tawait dataStore.trySetAlias(defaultDataStoreId);\n\t}\n}\n"]}
@@ -16,7 +16,7 @@ import { PureDataObjectFactory, type DataObjectFactoryProps } from "./pureDataOb
16
16
  * @typeParam TObj - DataObject (concrete type)
17
17
  * @typeParam I - The input types for the DataObject
18
18
  * @legacy
19
- * @alpha
19
+ * @beta
20
20
  */
21
21
  export declare class DataObjectFactory<TObj extends DataObject<I>, I extends DataObjectTypes = DataObjectTypes> extends PureDataObjectFactory<TObj, I> {
22
22
  /**
@@ -15,7 +15,7 @@ const pureDataObjectFactory_js_1 = require("./pureDataObjectFactory.js");
15
15
  * @typeParam TObj - DataObject (concrete type)
16
16
  * @typeParam I - The input types for the DataObject
17
17
  * @legacy
18
- * @alpha
18
+ * @beta
19
19
  */
20
20
  class DataObjectFactory extends pureDataObjectFactory_js_1.PureDataObjectFactory {
21
21
  constructor(propsOrType, maybeCtor, maybeSharedObjects, maybeOptionalProviders, maybeRegistryEntries, maybeRuntimeFactory) {
@@ -1 +1 @@
1
- {"version":3,"file":"dataObjectFactory.js","sourceRoot":"","sources":["../../src/data-object-factories/dataObjectFactory.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH,2DAKsC;AAMtC,yEAGoC;AAEpC;;;;;;;;;GASG;AACH,MAAa,iBAGX,SAAQ,gDAA8B;IAevC,YACC,WAAqD,EACrD,SAAsD,EACtD,kBAA+C,EAC/C,sBAA0E,EAC1E,oBAAyD,EACzD,mBAAkD;QAElD,MAAM,QAAQ,GACb,OAAO,WAAW,KAAK,QAAQ;YAC9B,CAAC,CAAC;gBACA,IAAI,EAAE,WAAW;gBACjB,6DAA6D;gBAC7D,oEAAoE;gBACpE,IAAI,EAAE,SAAU;gBAChB,aAAa,EAAE,kBAAkB;gBACjC,iBAAiB,EAAE,sBAAsB;gBACzC,eAAe,EAAE,oBAAoB;gBACrC,YAAY,EAAE,mBAAmB;aACjC;YACF,CAAC,CAAC,EAAE,GAAG,WAAW,EAAE,CAAC;QAEvB,MAAM,aAAa,GAAG,CAAC,QAAQ,CAAC,aAAa,GAAG,CAAC,GAAG,CAAC,QAAQ,CAAC,aAAa,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;QAErF,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,IAAI,KAAK,2BAAgB,CAAC,IAAI,CAAC,EAAE,CAAC;YAC9E,sCAAsC;YACtC,aAAa,CAAC,IAAI,CAAC,0BAAe,CAAC,UAAU,EAAE,CAAC,CAAC;QAClD,CAAC;QAED,0GAA0G;QAC1G,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,IAAI,KAAK,qBAAU,CAAC,IAAI,CAAC,EAAE,CAAC;YACxE,gCAAgC;YAChC,aAAa,CAAC,IAAI,CAAC,oBAAS,CAAC,UAAU,EAAE,CAAC,CAAC;QAC5C,CAAC;QAED,KAAK,CAAC,QAAQ,CAAC,CAAC;IACjB,CAAC;CACD;AAvDD,8CAuDC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { FluidDataStoreRuntime } from \"@fluidframework/datastore/internal\";\nimport type { IChannelFactory } from \"@fluidframework/datastore-definitions/internal\";\nimport {\n\tSharedMap,\n\tDirectoryFactory,\n\tMapFactory,\n\tSharedDirectory,\n} from \"@fluidframework/map/internal\";\nimport type { NamedFluidDataStoreRegistryEntries } from \"@fluidframework/runtime-definitions/internal\";\nimport type { FluidObjectSymbolProvider } from \"@fluidframework/synthesize/internal\";\n\nimport type { DataObject, DataObjectTypes, IDataObjectProps } from \"../data-objects/index.js\";\n\nimport {\n\tPureDataObjectFactory,\n\ttype DataObjectFactoryProps,\n} from \"./pureDataObjectFactory.js\";\n\n/**\n * DataObjectFactory is the IFluidDataStoreFactory for use with DataObjects.\n * It facilitates DataObject's features (such as its shared directory) by\n * ensuring relevant shared objects etc are available to the factory.\n *\n * @typeParam TObj - DataObject (concrete type)\n * @typeParam I - The input types for the DataObject\n * @legacy\n * @alpha\n */\nexport class DataObjectFactory<\n\tTObj extends DataObject<I>,\n\tI extends DataObjectTypes = DataObjectTypes,\n> extends PureDataObjectFactory<TObj, I> {\n\t/**\n\t * @remarks Use the props object based constructor instead.\n\t * No new features will be added to this constructor,\n\t * and it will eventually be deprecated and removed.\n\t */\n\tpublic constructor(\n\t\ttype: string,\n\t\tctor: new (props: IDataObjectProps<I>) => TObj,\n\t\tsharedObjects?: readonly IChannelFactory[],\n\t\toptionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>,\n\t\tregistryEntries?: NamedFluidDataStoreRegistryEntries,\n\t\truntimeFactory?: typeof FluidDataStoreRuntime,\n\t);\n\tpublic constructor(props: DataObjectFactoryProps<TObj, I>);\n\tpublic constructor(\n\t\tpropsOrType: DataObjectFactoryProps<TObj, I> | string,\n\t\tmaybeCtor?: new (doProps: IDataObjectProps<I>) => TObj,\n\t\tmaybeSharedObjects?: readonly IChannelFactory[],\n\t\tmaybeOptionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>,\n\t\tmaybeRegistryEntries?: NamedFluidDataStoreRegistryEntries,\n\t\tmaybeRuntimeFactory?: typeof FluidDataStoreRuntime,\n\t) {\n\t\tconst newProps =\n\t\t\ttypeof propsOrType === \"string\"\n\t\t\t\t? {\n\t\t\t\t\t\ttype: propsOrType,\n\t\t\t\t\t\t// both the arg and props base constructor require this param\n\t\t\t\t\t\t// eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n\t\t\t\t\t\tctor: maybeCtor!,\n\t\t\t\t\t\tsharedObjects: maybeSharedObjects,\n\t\t\t\t\t\toptionalProviders: maybeOptionalProviders,\n\t\t\t\t\t\tregistryEntries: maybeRegistryEntries,\n\t\t\t\t\t\truntimeClass: maybeRuntimeFactory,\n\t\t\t\t\t}\n\t\t\t\t: { ...propsOrType };\n\n\t\tconst sharedObjects = (newProps.sharedObjects = [...(newProps.sharedObjects ?? [])]);\n\n\t\tif (!sharedObjects.some((factory) => factory.type === DirectoryFactory.Type)) {\n\t\t\t// User did not register for directory\n\t\t\tsharedObjects.push(SharedDirectory.getFactory());\n\t\t}\n\n\t\t// TODO: Remove SharedMap factory when compatibility with SharedMap DataObject is no longer needed in 0.10\n\t\tif (!sharedObjects.some((factory) => factory.type === MapFactory.Type)) {\n\t\t\t// User did not register for map\n\t\t\tsharedObjects.push(SharedMap.getFactory());\n\t\t}\n\n\t\tsuper(newProps);\n\t}\n}\n"]}
1
+ {"version":3,"file":"dataObjectFactory.js","sourceRoot":"","sources":["../../src/data-object-factories/dataObjectFactory.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH,2DAKsC;AAMtC,yEAGoC;AAEpC;;;;;;;;;GASG;AACH,MAAa,iBAGX,SAAQ,gDAA8B;IAevC,YACC,WAAqD,EACrD,SAAsD,EACtD,kBAA+C,EAC/C,sBAA0E,EAC1E,oBAAyD,EACzD,mBAAkD;QAElD,MAAM,QAAQ,GACb,OAAO,WAAW,KAAK,QAAQ;YAC9B,CAAC,CAAC;gBACA,IAAI,EAAE,WAAW;gBACjB,6DAA6D;gBAC7D,oEAAoE;gBACpE,IAAI,EAAE,SAAU;gBAChB,aAAa,EAAE,kBAAkB;gBACjC,iBAAiB,EAAE,sBAAsB;gBACzC,eAAe,EAAE,oBAAoB;gBACrC,YAAY,EAAE,mBAAmB;aACjC;YACF,CAAC,CAAC,EAAE,GAAG,WAAW,EAAE,CAAC;QAEvB,MAAM,aAAa,GAAG,CAAC,QAAQ,CAAC,aAAa,GAAG,CAAC,GAAG,CAAC,QAAQ,CAAC,aAAa,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC;QAErF,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,IAAI,KAAK,2BAAgB,CAAC,IAAI,CAAC,EAAE,CAAC;YAC9E,sCAAsC;YACtC,aAAa,CAAC,IAAI,CAAC,0BAAe,CAAC,UAAU,EAAE,CAAC,CAAC;QAClD,CAAC;QAED,0GAA0G;QAC1G,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,IAAI,KAAK,qBAAU,CAAC,IAAI,CAAC,EAAE,CAAC;YACxE,gCAAgC;YAChC,aAAa,CAAC,IAAI,CAAC,oBAAS,CAAC,UAAU,EAAE,CAAC,CAAC;QAC5C,CAAC;QAED,KAAK,CAAC,QAAQ,CAAC,CAAC;IACjB,CAAC;CACD;AAvDD,8CAuDC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport type { FluidDataStoreRuntime } from \"@fluidframework/datastore/internal\";\nimport type { IChannelFactory } from \"@fluidframework/datastore-definitions/internal\";\nimport {\n\tSharedMap,\n\tDirectoryFactory,\n\tMapFactory,\n\tSharedDirectory,\n} from \"@fluidframework/map/internal\";\nimport type { NamedFluidDataStoreRegistryEntries } from \"@fluidframework/runtime-definitions/internal\";\nimport type { FluidObjectSymbolProvider } from \"@fluidframework/synthesize/internal\";\n\nimport type { DataObject, DataObjectTypes, IDataObjectProps } from \"../data-objects/index.js\";\n\nimport {\n\tPureDataObjectFactory,\n\ttype DataObjectFactoryProps,\n} from \"./pureDataObjectFactory.js\";\n\n/**\n * DataObjectFactory is the IFluidDataStoreFactory for use with DataObjects.\n * It facilitates DataObject's features (such as its shared directory) by\n * ensuring relevant shared objects etc are available to the factory.\n *\n * @typeParam TObj - DataObject (concrete type)\n * @typeParam I - The input types for the DataObject\n * @legacy\n * @beta\n */\nexport class DataObjectFactory<\n\tTObj extends DataObject<I>,\n\tI extends DataObjectTypes = DataObjectTypes,\n> extends PureDataObjectFactory<TObj, I> {\n\t/**\n\t * @remarks Use the props object based constructor instead.\n\t * No new features will be added to this constructor,\n\t * and it will eventually be deprecated and removed.\n\t */\n\tpublic constructor(\n\t\ttype: string,\n\t\tctor: new (props: IDataObjectProps<I>) => TObj,\n\t\tsharedObjects?: readonly IChannelFactory[],\n\t\toptionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>,\n\t\tregistryEntries?: NamedFluidDataStoreRegistryEntries,\n\t\truntimeFactory?: typeof FluidDataStoreRuntime,\n\t);\n\tpublic constructor(props: DataObjectFactoryProps<TObj, I>);\n\tpublic constructor(\n\t\tpropsOrType: DataObjectFactoryProps<TObj, I> | string,\n\t\tmaybeCtor?: new (doProps: IDataObjectProps<I>) => TObj,\n\t\tmaybeSharedObjects?: readonly IChannelFactory[],\n\t\tmaybeOptionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>,\n\t\tmaybeRegistryEntries?: NamedFluidDataStoreRegistryEntries,\n\t\tmaybeRuntimeFactory?: typeof FluidDataStoreRuntime,\n\t) {\n\t\tconst newProps =\n\t\t\ttypeof propsOrType === \"string\"\n\t\t\t\t? {\n\t\t\t\t\t\ttype: propsOrType,\n\t\t\t\t\t\t// both the arg and props base constructor require this param\n\t\t\t\t\t\t// eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n\t\t\t\t\t\tctor: maybeCtor!,\n\t\t\t\t\t\tsharedObjects: maybeSharedObjects,\n\t\t\t\t\t\toptionalProviders: maybeOptionalProviders,\n\t\t\t\t\t\tregistryEntries: maybeRegistryEntries,\n\t\t\t\t\t\truntimeClass: maybeRuntimeFactory,\n\t\t\t\t\t}\n\t\t\t\t: { ...propsOrType };\n\n\t\tconst sharedObjects = (newProps.sharedObjects = [...(newProps.sharedObjects ?? [])]);\n\n\t\tif (!sharedObjects.some((factory) => factory.type === DirectoryFactory.Type)) {\n\t\t\t// User did not register for directory\n\t\t\tsharedObjects.push(SharedDirectory.getFactory());\n\t\t}\n\n\t\t// TODO: Remove SharedMap factory when compatibility with SharedMap DataObject is no longer needed in 0.10\n\t\tif (!sharedObjects.some((factory) => factory.type === MapFactory.Type)) {\n\t\t\t// User did not register for map\n\t\t\tsharedObjects.push(SharedMap.getFactory());\n\t\t}\n\n\t\tsuper(newProps);\n\t}\n}\n"]}
@@ -14,8 +14,7 @@ import type { DataObjectTypes, IDataObjectProps, PureDataObject } from "../data-
14
14
  * registry entries, and the runtime class to use for the data object.
15
15
  * @typeParam TObj - DataObject (concrete type)
16
16
  * @typeParam I - The input types for the DataObject
17
- * @legacy
18
- * @alpha
17
+ * @legacy @beta
19
18
  */
20
19
  export interface DataObjectFactoryProps<TObj extends PureDataObject<I>, I extends DataObjectTypes = DataObjectTypes> {
21
20
  /**
@@ -55,8 +54,7 @@ export interface DataObjectFactoryProps<TObj extends PureDataObject<I>, I extend
55
54
  *
56
55
  * @typeParam TObj - DataObject (concrete type)
57
56
  * @typeParam I - The input types for the DataObject
58
- * @legacy
59
- * @alpha
57
+ * @legacy @beta
60
58
  */
61
59
  export declare class PureDataObjectFactory<TObj extends PureDataObject<I>, I extends DataObjectTypes = DataObjectTypes> implements IFluidDataStoreFactory, Partial<IProvideFluidDataStoreRegistry> {
62
60
  private readonly registry;
@@ -1 +1 @@
1
- {"version":3,"file":"pureDataObjectFactory.d.ts","sourceRoot":"","sources":["../../src/data-object-factories/pureDataObjectFactory.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wDAAwD,CAAC;AAGhG,OAAO,EACN,qBAAqB,EAGrB,MAAM,oCAAoC,CAAC;AAC5C,OAAO,KAAK,EACX,eAAe,EAEf,MAAM,gDAAgD,CAAC;AACxD,OAAO,KAAK,EACX,qBAAqB,EACrB,UAAU,EACV,sBAAsB,EACtB,sBAAsB,EACtB,8BAA8B,EAC9B,sBAAsB,EACtB,uBAAuB,EACvB,uBAAuB,EACvB,8BAA8B,EAC9B,kCAAkC,EAClC,gCAAgC,EAChC,MAAM,8CAA8C,CAAC;AACtD,OAAO,KAAK,EAEX,yBAAyB,EAEzB,MAAM,qCAAqC,CAAC;AAE7C,OAAO,KAAK,EACX,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,MAAM,0BAA0B,CAAC;AAoGlC;;;;;;;;GAQG;AACH,MAAM,WAAW,sBAAsB,CACtC,IAAI,SAAS,cAAc,CAAC,CAAC,CAAC,EAC9B,CAAC,SAAS,eAAe,GAAG,eAAe;IAE3C;;OAEG;IACH,QAAQ,CAAC,IAAI,EAAE,MAAM,C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qB,EACvC,WAAW,EAAE,QAAQ,CAAC,MAAM,EAAE,CAAC,EAC/B,YAAY,CAAC,EAAE,CAAC,CAAC,cAAc,CAAC,EAChC,cAAc,CAAC,EAAE,MAAM,GACrB,OAAO,CAAC,IAAI,CAAC;cAKA,kBAAkB,CACjC,OAAO,EAAE,8BAA8B,EACvC,YAAY,CAAC,EAAE,CAAC,CAAC,cAAc,CAAC,GAC9B,OAAO,CAAC,IAAI,CAAC;CAYhB"}
1
+ {"version":3,"file":"pureDataObjectFactory.d.ts","sourceRoot":"","sources":["../../src/data-object-factories/pureDataObjectFactory.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAGH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,wDAAwD,CAAC;AAGhG,OAAO,EACN,qBAAqB,EAGrB,MAAM,oCAAoC,CAAC;AAC5C,OAAO,KAAK,EACX,eAAe,EAEf,MAAM,gDAAgD,CAAC;AACxD,OAAO,KAAK,EACX,qBAAqB,EACrB,UAAU,EACV,sBAAsB,EACtB,sBAAsB,EACtB,8BAA8B,EAC9B,sBAAsB,EACtB,uBAAuB,EACvB,uBAAuB,EACvB,8BAA8B,EAC9B,kCAAkC,EAClC,gCAAgC,EAChC,MAAM,8CAA8C,CAAC;AACtD,OAAO,KAAK,EAEX,yBAAyB,EAEzB,MAAM,qCAAqC,CAAC;AAE7C,OAAO,KAAK,EACX,eAAe,EACf,gBAAgB,EAChB,cAAc,EACd,MAAM,0BAA0B,CAAC;AAoGlC;;;;;;;GAOG;AACH,MAAM,WAAW,sBAAsB,CACtC,IAAI,SAAS,cAAc,CAAC,CAAC,CAAC,EAC9B,CAAC,SAAS,eAAe,GAAG,eAAe;IAE3C;;OAEG;IACH,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAEtB;;OAEG;IACH,QAAQ,CAAC,IAAI,EAAE,KACd,KAAK,EAAE,gBAAgB,CAAC,CAAC,CAAC,KACtB,IAAI,CAAC;IAEV;;OAEG;IACH,QAAQ,CAA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AAO,CAAC,IAAI,CAAC;cAKA,kBAAkB,CACjC,OAAO,EAAE,8BAA8B,EACvC,YAAY,CAAC,EAAE,CAAC,CAAC,cAAc,CAAC,GAC9B,OAAO,CAAC,IAAI,CAAC;CAYhB"}
@@ -66,8 +66,7 @@ async function createDataObject({ ctor, context, sharedObjectRegistry, optionalP
66
66
  *
67
67
  * @typeParam TObj - DataObject (concrete type)
68
68
  * @typeParam I - The input types for the DataObject
69
- * @legacy
70
- * @alpha
69
+ * @legacy @beta
71
70
  */
72
71
  class PureDataObjectFactory {
73
72
  constructor(propsOrType, maybeCtor, maybeSharedObjects, maybeOptionalProviders, maybeRegistryEntries, maybeRuntimeFactory) {
@@ -1 +1 @@
1
- {"version":3,"file":"pureDataObjectFactory.js","sourceRoot":"","sources":["../../src/data-object-factories/pureDataObjectFactory.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,yEAAoF;AAGpF,kEAA6D;AAC7D,iEAI4C;AAwC5C;;;GAGG;AACH,KAAK,UAAU,gBAAgB,CAG7B,EACD,IAAI,EACJ,OAAO,EACP,oBAAoB,EACpB,iBAAiB,EACjB,eAAe,EACf,QAAQ,EACR,YAAY,EAAE,SAAS,EACvB,QAAQ,GACwB;IAIhC,OAAO;IACP,IAAI,YAAY,GAAG,eAAe,CAAC;IAEnC,mBAAmB;IACnB,YAAY,GAAG,IAAA,8BAAmB,EACjC,KAAK,EAAE,OAAiB,EAAE,UAAiC,EAAE,EAAE;QAC9D,iFAAiF;QACjF,MAAM,UAAU,GAAG,CAAC,MAAM,UAAU,CAAC,UAAU,CAAC,GAAG,EAAE,CAAS,CAAC;QAC/D,IAAA,iBAAM,EACL,UAAU,CAAC,OAAO,KAAK,SAAS,EAChC,KAAK,CAAC,yDAAyD,CAC/D,CAAC;QACF,OAAO,UAAU,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;IACpC,CAAC,EACD,YAAY,CACZ,CAAC;IAEF,gFAAgF;IAChF,+DAA+D;IAC/D,6EAA6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AAW,EAAE,cAAc,CAAC,CAAC;QACtF,OAAO,IAAI,CAAC,kBAAkB,CAAC,OAAO,EAAE,YAAY,CAAC,CAAC;IACvD,CAAC;IAES,KAAK,CAAC,kBAAkB,CACjC,OAAuC,EACvC,YAAgC;QAEhC,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,MAAM,gBAAgB,CAAC;YACpD,GAAG,IAAI,CAAC,WAAW;YACnB,OAAO;YACP,QAAQ,EAAE,KAAK;YACf,YAAY;SACZ,CAAC,CAAC;QAEH,MAAM,OAAO,CAAC,aAAa,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;QAE3C,OAAO,QAAQ,CAAC;IACjB,CAAC;CACD;AAxQD,sDAwQC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { FluidDataStoreRegistry } from \"@fluidframework/container-runtime/internal\";\nimport type { IContainerRuntime } from \"@fluidframework/container-runtime-definitions/internal\";\nimport type { FluidObject, IRequest } from \"@fluidframework/core-interfaces\";\nimport { assert } from \"@fluidframework/core-utils/internal\";\nimport {\n\tFluidDataStoreRuntime,\n\ttype ISharedObjectRegistry,\n\tmixinRequestHandler,\n} from \"@fluidframework/datastore/internal\";\nimport type {\n\tIChannelFactory,\n\tIFluidDataStoreRuntime,\n} from \"@fluidframework/datastore-definitions/internal\";\nimport type {\n\tIContainerRuntimeBase,\n\tIDataStore,\n\tIFluidDataStoreChannel,\n\tIFluidDataStoreContext,\n\tIFluidDataStoreContextDetached,\n\tIFluidDataStoreFactory,\n\tIFluidDataStorePolicies,\n\tIFluidDataStoreRegistry,\n\tIProvideFluidDataStoreRegistry,\n\tNamedFluidDataStoreRegistryEntries,\n\tNamedFluidDataStoreRegistryEntry,\n} from \"@fluidframework/runtime-definitions/internal\";\nimport type {\n\tAsyncFluidObjectProvider,\n\tFluidObjectSymbolProvider,\n\tIFluidDependencySynthesizer,\n} from \"@fluidframework/synthesize/internal\";\n\nimport type {\n\tDataObjectTypes,\n\tIDataObjectProps,\n\tPureDataObject,\n} from \"../data-objects/index.js\";\n\ninterface CreateDataObjectProps<TObj extends PureDataObject, I extends DataObjectTypes> {\n\tctor: new (props: IDataObjectProps<I>) => TObj;\n\tcontext: IFluidDataStoreContext;\n\tsharedObjectRegistry: ISharedObjectRegistry;\n\toptionalProviders: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>;\n\truntimeClassArg: typeof FluidDataStoreRuntime;\n\texisting: boolean;\n\tinitialState?: I[\"InitialState\"];\n\tpolicies?: Partial<IFluidDataStorePolicies>;\n}\n/**\n * Proxy over PureDataObject\n * Does delayed creation & initialization of PureDataObject\n */\nasync function createDataObject<\n\tTObj extends PureDataObject,\n\tI extends DataObjectTypes = DataObjectTypes,\n>({\n\tctor,\n\tcontext,\n\tsharedObjectRegistry,\n\toptionalProviders,\n\truntimeClassArg,\n\texisting,\n\tinitialState: initProps,\n\tpolicies,\n}: CreateDataObjectProps<TObj, I>): Promise<{\n\tinstance: TObj;\n\truntime: FluidDataStoreRuntime;\n}> {\n\t// base\n\tlet runtimeClass = runtimeClassArg;\n\n\t// request mixin in\n\truntimeClass = mixinRequestHandler(\n\t\tasync (request: IRequest, runtimeArg: FluidDataStoreRuntime) => {\n\t\t\t// The provideEntryPoint callback below always returns TObj, so this cast is safe\n\t\t\tconst dataObject = (await runtimeArg.entryPoint.get()) as TObj;\n\t\t\tassert(\n\t\t\t\tdataObject.request !== undefined,\n\t\t\t\t0x795 /* Data store runtime entryPoint does not have request */,\n\t\t\t);\n\t\t\treturn dataObject.request(request);\n\t\t},\n\t\truntimeClass,\n\t);\n\n\t// Create a new runtime for our data store, as if via new FluidDataStoreRuntime,\n\t// but using the runtimeClass that's been augmented with mixins\n\t// The runtime is what Fluid uses to create DDS' and route to your data store\n\tconst runtime: FluidDataStoreRuntime = new runtimeClass(\n\t\t// calls new FluidDataStoreRuntime(...)\n\t\tcontext,\n\t\tsharedObjectRegistry,\n\t\texisting,\n\t\tasync (rt: IFluidDataStoreRuntime) => {\n\t\t\tassert(instance !== undefined, 0x46a /* entryPoint is undefined */);\n\t\t\t// Calling finishInitialization here like PureDataObject.getDataObject did, to keep the same behavior,\n\t\t\t// since accessing the runtime's entryPoint is how we want the data object to be retrieved going forward.\n\t\t\t// Without this I ran into issues with the load-existing flow not working correctly.\n\t\t\tawait instance.finishInitialization(true);\n\t\t\treturn instance;\n\t\t} /* provideEntryPoint */,\n\t\tpolicies,\n\t);\n\n\t// Create object right away.\n\t// This allows object to register various callbacks with runtime before runtime\n\t// becomes globally available. But it's not full initialization - constructor can't\n\t// access DDSes or other services of runtime as objects are not fully initialized.\n\t// In order to use object, we need to go through full initialization by calling finishInitialization().\n\tconst scope: FluidObject<IFluidDependencySynthesizer> = context.scope;\n\tconst providers =\n\t\tscope.IFluidDependencySynthesizer?.synthesize<I[\"OptionalProviders\"]>(\n\t\t\toptionalProviders,\n\t\t\t{},\n\t\t) ??\n\t\t// eslint-disable-next-line @typescript-eslint/consistent-type-assertions\n\t\t({} as AsyncFluidObjectProvider<never>);\n\n\tconst instance = new ctor({ runtime, context, providers, initProps });\n\n\t// if it's a newly created object, we need to wait for it to finish initialization\n\t// as that results in creation of DDSes, before it gets attached, providing atomic\n\t// guarantee of creation.\n\t// WARNING: we can't do the same (yet) for already existing PureDataObject!\n\t// This will result in deadlock, as it tries to resolve internal handles, but any\n\t// handle resolution goes through root (container runtime), which can't route it back\n\t// to this data store, as it's still not initialized and not known to container runtime yet.\n\t// In the future, we should address it by using relative paths for handles and be able to resolve\n\t// local DDSes while data store is not fully initialized.\n\tif (!existing) {\n\t\tawait instance.finishInitialization(existing);\n\t}\n\n\treturn { instance, runtime };\n}\n\n/**\n * Represents the properties required to create a DataObjectFactory.\n * This includes the type identifier, constructor, shared objects, optional providers,\n * registry entries, and the runtime class to use for the data object.\n * @typeParam TObj - DataObject (concrete type)\n * @typeParam I - The input types for the DataObject\n * @legacy\n * @alpha\n */\nexport interface DataObjectFactoryProps<\n\tTObj extends PureDataObject<I>,\n\tI extends DataObjectTypes = DataObjectTypes,\n> {\n\t/**\n\t * The type identifier for the data object factory.\n\t */\n\treadonly type: string;\n\n\t/**\n\t * The constructor for the data object.\n\t */\n\treadonly ctor: new (\n\t\tprops: IDataObjectProps<I>,\n\t) => TObj;\n\n\t/**\n\t * The shared objects (DDSes) to be registered with the data object.\n\t */\n\treadonly sharedObjects?: readonly IChannelFactory[];\n\n\t/**\n\t * Optional providers for dependency injection.\n\t */\n\treadonly optionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>;\n\n\t/**\n\t * Registry entries for named data stores.\n\t */\n\treadonly registryEntries?: NamedFluidDataStoreRegistryEntries;\n\n\t/**\n\t * The runtime class to use for the data object.\n\t */\n\treadonly runtimeClass?: typeof FluidDataStoreRuntime;\n\n\t/**\n\t * Optional policies that can be applied to the DataObject.\n\t * These policies define specific behaviors or constraints for the data object.\n\t */\n\treadonly policies?: Partial<IFluidDataStorePolicies>;\n}\n\n/**\n * PureDataObjectFactory is a bare-bones IFluidDataStoreFactory for use with PureDataObject.\n * Consumers should typically use DataObjectFactory instead unless creating\n * another base data store factory.\n *\n * @typeParam TObj - DataObject (concrete type)\n * @typeParam I - The input types for the DataObject\n * @legacy\n * @alpha\n */\nexport class PureDataObjectFactory<\n\tTObj extends PureDataObject<I>,\n\tI extends DataObjectTypes = DataObjectTypes,\n> implements IFluidDataStoreFactory, Partial<IProvideFluidDataStoreRegistry>\n{\n\tprivate readonly registry: IFluidDataStoreRegistry | undefined;\n\tprivate readonly createProps: Omit<CreateDataObjectProps<TObj, I>, \"existing\" | \"context\">;\n\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IFluidDataStoreFactory.\"type\"}\n\t */\n\tpublic readonly type: string;\n\n\t/**\n\t * @remarks Use the props object based constructor instead.\n\t * No new features will be added to this constructor,\n\t * and it will eventually be deprecated and removed.\n\t */\n\tpublic constructor(\n\t\ttype: string,\n\t\tctor: new (props: IDataObjectProps<I>) => TObj,\n\t\tsharedObjects?: readonly IChannelFactory[],\n\t\toptionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>,\n\t\tregistryEntries?: NamedFluidDataStoreRegistryEntries,\n\t\truntimeClass?: typeof FluidDataStoreRuntime,\n\t);\n\tpublic constructor(props: DataObjectFactoryProps<TObj, I>);\n\tpublic constructor(\n\t\tpropsOrType: DataObjectFactoryProps<TObj, I> | string,\n\t\tmaybeCtor?: new (doProps: IDataObjectProps<I>) => TObj,\n\t\tmaybeSharedObjects?: readonly IChannelFactory[],\n\t\tmaybeOptionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>,\n\t\tmaybeRegistryEntries?: NamedFluidDataStoreRegistryEntries,\n\t\tmaybeRuntimeFactory?: typeof FluidDataStoreRuntime,\n\t) {\n\t\tconst newProps =\n\t\t\ttypeof propsOrType === \"string\"\n\t\t\t\t? {\n\t\t\t\t\t\ttype: propsOrType,\n\t\t\t\t\t\t// both the arg and props base constructor require this param\n\t\t\t\t\t\t// eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n\t\t\t\t\t\tctor: maybeCtor!,\n\t\t\t\t\t\tsharedObjects: maybeSharedObjects,\n\t\t\t\t\t\toptionalProviders: maybeOptionalProviders,\n\t\t\t\t\t\tregistryEntries: maybeRegistryEntries,\n\t\t\t\t\t\truntimeClass: maybeRuntimeFactory,\n\t\t\t\t\t}\n\t\t\t\t: propsOrType;\n\n\t\tif (newProps.type === \"\") {\n\t\t\tthrow new Error(\"undefined type member\");\n\t\t}\n\t\tthis.type = newProps.type;\n\n\t\tthis.createProps = {\n\t\t\tctor: newProps.ctor,\n\t\t\toptionalProviders: newProps.optionalProviders ?? {},\n\t\t\tsharedObjectRegistry: new Map(newProps.sharedObjects?.map((ext) => [ext.type, ext])),\n\t\t\truntimeClassArg: newProps.runtimeClass ?? FluidDataStoreRuntime,\n\t\t\tpolicies: newProps.policies,\n\t\t};\n\n\t\tif (newProps.registryEntries !== undefined) {\n\t\t\tthis.registry = new FluidDataStoreRegistry(newProps.registryEntries);\n\t\t}\n\t}\n\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IProvideFluidDataStoreFactory.IFluidDataStoreFactory}\n\t */\n\tpublic get IFluidDataStoreFactory(): this {\n\t\treturn this;\n\t}\n\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IProvideFluidDataStoreRegistry.IFluidDataStoreRegistry}\n\t */\n\tpublic get IFluidDataStoreRegistry(): IFluidDataStoreRegistry | undefined {\n\t\treturn this.registry;\n\t}\n\n\t/**\n\t * Convenience helper to get the data store's/factory's data store registry entry.\n\t * The return type hides the factory's generics, easing grouping of registry\n\t * entries that differ only in this way into the same array.\n\t * @returns The NamedFluidDataStoreRegistryEntry\n\t */\n\tpublic get registryEntry(): NamedFluidDataStoreRegistryEntry {\n\t\treturn [this.type, Promise.resolve(this)];\n\t}\n\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IFluidDataStoreFactory.instantiateDataStore}\n\t */\n\tpublic async instantiateDataStore(\n\t\tcontext: IFluidDataStoreContext,\n\t\texisting: boolean,\n\t): Promise<IFluidDataStoreChannel> {\n\t\tconst { runtime } = await createDataObject({ ...this.createProps, context, existing });\n\n\t\treturn runtime;\n\t}\n\n\t/**\n\t * Creates a new instance of the object. Uses parent context's registry to build package path to this factory.\n\t * In other words, registry of context passed in has to contain this factory, with the name that matches\n\t * this factory's type.\n\t * It is intended to be used by data store objects that create sub-objects.\n\t * @param context - The context being used to create the runtime\n\t * (the created object will have its own new context created as well)\n\t * @param initialState - The initial state to provide to the created data store.\n\t * @param loadingGroupId - NOT production ready, EXPERIMENTAL, please read {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}. The service needs to support this feature, does not work for most services\n\t * @returns an object created by this factory. Data store and objects created are not attached to container.\n\t * They get attached only when a handle to one of them is attached to already attached objects.\n\t */\n\tpublic async createChildInstance(\n\t\tparentContext: IFluidDataStoreContext,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tloadingGroupId?: string,\n\t): Promise<TObj> {\n\t\treturn this.createNonRootInstanceCore(\n\t\t\tparentContext.containerRuntime,\n\t\t\t[...parentContext.packagePath, this.type],\n\t\t\tinitialState,\n\t\t\tloadingGroupId,\n\t\t);\n\t}\n\n\t/**\n\t * Creates a new instance of the object. Uses peer context's registry and its package path to identify this factory.\n\t * In other words, registry of context passed in has to have this factory.\n\t * Intended to be used by data store objects that need to create peers (similar) instances of existing objects.\n\t * @param context - The component context being used to create the object\n\t * (the created object will have its own new context created as well)\n\t * @param initialState - The initial state to provide to the created component.\n\t * @param loadingGroupId - NOT production ready, EXPERIMENTAL, please read {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}. The service needs to support this feature, does not work for most services\n\t * @returns an object created by this factory. Data store and objects created are not attached to container.\n\t * They get attached only when a handle to one of them is attached to already attached objects.\n\t */\n\tpublic async createPeerInstance(\n\t\tpeerContext: IFluidDataStoreContext,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tloadingGroupId?: string, // DO NOT USE, this is an experimental feature\n\t): Promise<TObj> {\n\t\treturn this.createNonRootInstanceCore(\n\t\t\tpeerContext.containerRuntime,\n\t\t\tpeerContext.packagePath,\n\t\t\tinitialState,\n\t\t\tloadingGroupId,\n\t\t);\n\t}\n\n\t/**\n\t * Creates a new instance of the object. Uses container's registry to find this factory.\n\t * It's expected that only container owners would use this functionality, as only such developers\n\t * have knowledge of entries in container registry.\n\t * The name in this registry for such record should match type of this factory.\n\t * @param runtime - container runtime. It's registry is used to create an object.\n\t * @param initialState - The initial state to provide to the created component.\n\t * @param loadingGroupId - NOT production ready, EXPERIMENTAL, please read {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}. The service needs to support this feature, does not work for most services\n\t * @returns an object created by this factory. Data store and objects created are not attached to container.\n\t * They get attached only when a handle to one of them is attached to already attached objects.\n\t */\n\tpublic async createInstance(\n\t\truntime: IContainerRuntimeBase,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tloadingGroupId?: string,\n\t): Promise<TObj> {\n\t\treturn this.createNonRootInstanceCore(runtime, [this.type], initialState, loadingGroupId);\n\t}\n\n\t/**\n\t * Creates a new instance of the object with a datastore which exposes the aliasing api.\n\t * @param runtime - container runtime. It is the runtime that will be used to create the object. It will produce\n\t * the underlying infrastructure to get the data object to operate.\n\t * @param initialState - The initial state to provide to the created component.\n\t * @param packagePath - The path to the data store factory to use to create the data object.\n\t * @param loadingGroupId - NOT production ready, EXPERIMENTAL, please read {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}. The service needs to support this feature, does not work for most services\n\t * @returns an array containing the object created by this factory and an IDataStore object that enables users to\n\t * alias the data object.\n\t * The data object is attached only when it is attached to the handle graph that connects to an aliased object or\n\t * when the data object is aliased.\n\t */\n\tpublic async createInstanceWithDataStore(\n\t\tcontainerRuntime: IContainerRuntimeBase,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tpackagePath?: Readonly<string[]>,\n\t\tloadingGroupId?: string,\n\t): Promise<[TObj, IDataStore]> {\n\t\tconst context = containerRuntime.createDetachedDataStore(\n\t\t\tpackagePath ?? [this.type],\n\t\t\tloadingGroupId,\n\t\t);\n\t\tconst { instance, runtime } = await createDataObject({\n\t\t\t...this.createProps,\n\t\t\tcontext,\n\t\t\texisting: false,\n\t\t\tinitialState,\n\t\t});\n\t\tconst dataStore = await context.attachRuntime(this, runtime);\n\n\t\treturn [instance, dataStore];\n\t}\n\n\t/**\n\t * Creates a new root instance of the object. Uses container's registry to find this factory.\n\t * It's expected that only container owners would use this functionality, as only such developers\n\t * have knowledge of entries in container registry.\n\t * The name in this registry for such record should match type of this factory.\n\t * @param runtime - container runtime. It's registry is used to create an object.\n\t * @param initialState - The initial state to provide to the created component.\n\t * @returns an object created by this factory. Data store and objects created are not attached to container.\n\t * They get attached only when a handle to one of them is attached to already attached objects.\n\t *\n\t * @deprecated - the issue is that it does not allow the customer to decide the conflict resolution policy when an\n\t * aliasing conflict occurs. Use {@link PureDataObjectFactory.createInstanceWithDataStore} instead.\n\t */\n\tpublic async createRootInstance(\n\t\trootDataStoreId: string,\n\t\truntime: IContainerRuntime,\n\t\tinitialState?: I[\"InitialState\"],\n\t): Promise<TObj> {\n\t\tconst context = runtime.createDetachedDataStore([this.type]);\n\t\tconst { instance, runtime: dataStoreRuntime } = await createDataObject({\n\t\t\t...this.createProps,\n\t\t\tcontext,\n\t\t\texisting: false,\n\t\t\tinitialState,\n\t\t});\n\t\tconst dataStore = await context.attachRuntime(this, dataStoreRuntime);\n\t\tconst result = await dataStore.trySetAlias(rootDataStoreId);\n\t\tif (result !== \"Success\") {\n\t\t\tconst handle = await runtime.getAliasedDataStoreEntryPoint(rootDataStoreId);\n\t\t\tassert(handle !== undefined, 0x8e1 /* Should have retrieved aliased handle */);\n\t\t\treturn (await handle.get()) as TObj;\n\t\t}\n\t\treturn instance;\n\t}\n\n\tprotected async createNonRootInstanceCore(\n\t\tcontainerRuntime: IContainerRuntimeBase,\n\t\tpackagePath: Readonly<string[]>,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tloadingGroupId?: string,\n\t): Promise<TObj> {\n\t\tconst context = containerRuntime.createDetachedDataStore(packagePath, loadingGroupId);\n\t\treturn this.createInstanceCore(context, initialState);\n\t}\n\n\tprotected async createInstanceCore(\n\t\tcontext: IFluidDataStoreContextDetached,\n\t\tinitialState?: I[\"InitialState\"],\n\t): Promise<TObj> {\n\t\tconst { instance, runtime } = await createDataObject({\n\t\t\t...this.createProps,\n\t\t\tcontext,\n\t\t\texisting: false,\n\t\t\tinitialState,\n\t\t});\n\n\t\tawait context.attachRuntime(this, runtime);\n\n\t\treturn instance;\n\t}\n}\n"]}
1
+ {"version":3,"file":"pureDataObjectFactory.js","sourceRoot":"","sources":["../../src/data-object-factories/pureDataObjectFactory.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,yE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AAW;YACnB,OAAO;YACP,QAAQ,EAAE,KAAK;YACf,YAAY;SACZ,CAAC,CAAC;QACH,MAAM,SAAS,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,IAAI,EAAE,gBAAgB,CAAC,CAAC;QACtE,MAAM,MAAM,GAAG,MAAM,SAAS,CAAC,WAAW,CAAC,eAAe,CAAC,CAAC;QAC5D,IAAI,MAAM,KAAK,SAAS,EAAE,CAAC;YAC1B,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,6BAA6B,CAAC,eAAe,CAAC,CAAC;YAC5E,IAAA,iBAAM,EAAC,MAAM,KAAK,SAAS,EAAE,KAAK,CAAC,0CAA0C,CAAC,CAAC;YAC/E,OAAO,CAAC,MAAM,MAAM,CAAC,GAAG,EAAE,CAAS,CAAC;QACrC,CAAC;QACD,OAAO,QAAQ,CAAC;IACjB,CAAC;IAES,KAAK,CAAC,yBAAyB,CACxC,gBAAuC,EACvC,WAA+B,EAC/B,YAAgC,EAChC,cAAuB;QAEvB,MAAM,OAAO,GAAG,gBAAgB,CAAC,uBAAuB,CAAC,WAAW,EAAE,cAAc,CAAC,CAAC;QACtF,OAAO,IAAI,CAAC,kBAAkB,CAAC,OAAO,EAAE,YAAY,CAAC,CAAC;IACvD,CAAC;IAES,KAAK,CAAC,kBAAkB,CACjC,OAAuC,EACvC,YAAgC;QAEhC,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,GAAG,MAAM,gBAAgB,CAAC;YACpD,GAAG,IAAI,CAAC,WAAW;YACnB,OAAO;YACP,QAAQ,EAAE,KAAK;YACf,YAAY;SACZ,CAAC,CAAC;QAEH,MAAM,OAAO,CAAC,aAAa,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;QAE3C,OAAO,QAAQ,CAAC;IACjB,CAAC;CACD;AAxQD,sDAwQC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { FluidDataStoreRegistry } from \"@fluidframework/container-runtime/internal\";\nimport type { IContainerRuntime } from \"@fluidframework/container-runtime-definitions/internal\";\nimport type { FluidObject, IRequest } from \"@fluidframework/core-interfaces\";\nimport { assert } from \"@fluidframework/core-utils/internal\";\nimport {\n\tFluidDataStoreRuntime,\n\ttype ISharedObjectRegistry,\n\tmixinRequestHandler,\n} from \"@fluidframework/datastore/internal\";\nimport type {\n\tIChannelFactory,\n\tIFluidDataStoreRuntime,\n} from \"@fluidframework/datastore-definitions/internal\";\nimport type {\n\tIContainerRuntimeBase,\n\tIDataStore,\n\tIFluidDataStoreChannel,\n\tIFluidDataStoreContext,\n\tIFluidDataStoreContextDetached,\n\tIFluidDataStoreFactory,\n\tIFluidDataStorePolicies,\n\tIFluidDataStoreRegistry,\n\tIProvideFluidDataStoreRegistry,\n\tNamedFluidDataStoreRegistryEntries,\n\tNamedFluidDataStoreRegistryEntry,\n} from \"@fluidframework/runtime-definitions/internal\";\nimport type {\n\tAsyncFluidObjectProvider,\n\tFluidObjectSymbolProvider,\n\tIFluidDependencySynthesizer,\n} from \"@fluidframework/synthesize/internal\";\n\nimport type {\n\tDataObjectTypes,\n\tIDataObjectProps,\n\tPureDataObject,\n} from \"../data-objects/index.js\";\n\ninterface CreateDataObjectProps<TObj extends PureDataObject, I extends DataObjectTypes> {\n\tctor: new (props: IDataObjectProps<I>) => TObj;\n\tcontext: IFluidDataStoreContext;\n\tsharedObjectRegistry: ISharedObjectRegistry;\n\toptionalProviders: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>;\n\truntimeClassArg: typeof FluidDataStoreRuntime;\n\texisting: boolean;\n\tinitialState?: I[\"InitialState\"];\n\tpolicies?: Partial<IFluidDataStorePolicies>;\n}\n/**\n * Proxy over PureDataObject\n * Does delayed creation & initialization of PureDataObject\n */\nasync function createDataObject<\n\tTObj extends PureDataObject,\n\tI extends DataObjectTypes = DataObjectTypes,\n>({\n\tctor,\n\tcontext,\n\tsharedObjectRegistry,\n\toptionalProviders,\n\truntimeClassArg,\n\texisting,\n\tinitialState: initProps,\n\tpolicies,\n}: CreateDataObjectProps<TObj, I>): Promise<{\n\tinstance: TObj;\n\truntime: FluidDataStoreRuntime;\n}> {\n\t// base\n\tlet runtimeClass = runtimeClassArg;\n\n\t// request mixin in\n\truntimeClass = mixinRequestHandler(\n\t\tasync (request: IRequest, runtimeArg: FluidDataStoreRuntime) => {\n\t\t\t// The provideEntryPoint callback below always returns TObj, so this cast is safe\n\t\t\tconst dataObject = (await runtimeArg.entryPoint.get()) as TObj;\n\t\t\tassert(\n\t\t\t\tdataObject.request !== undefined,\n\t\t\t\t0x795 /* Data store runtime entryPoint does not have request */,\n\t\t\t);\n\t\t\treturn dataObject.request(request);\n\t\t},\n\t\truntimeClass,\n\t);\n\n\t// Create a new runtime for our data store, as if via new FluidDataStoreRuntime,\n\t// but using the runtimeClass that's been augmented with mixins\n\t// The runtime is what Fluid uses to create DDS' and route to your data store\n\tconst runtime: FluidDataStoreRuntime = new runtimeClass(\n\t\t// calls new FluidDataStoreRuntime(...)\n\t\tcontext,\n\t\tsharedObjectRegistry,\n\t\texisting,\n\t\tasync (rt: IFluidDataStoreRuntime) => {\n\t\t\tassert(instance !== undefined, 0x46a /* entryPoint is undefined */);\n\t\t\t// Calling finishInitialization here like PureDataObject.getDataObject did, to keep the same behavior,\n\t\t\t// since accessing the runtime's entryPoint is how we want the data object to be retrieved going forward.\n\t\t\t// Without this I ran into issues with the load-existing flow not working correctly.\n\t\t\tawait instance.finishInitialization(true);\n\t\t\treturn instance;\n\t\t} /* provideEntryPoint */,\n\t\tpolicies,\n\t);\n\n\t// Create object right away.\n\t// This allows object to register various callbacks with runtime before runtime\n\t// becomes globally available. But it's not full initialization - constructor can't\n\t// access DDSes or other services of runtime as objects are not fully initialized.\n\t// In order to use object, we need to go through full initialization by calling finishInitialization().\n\tconst scope: FluidObject<IFluidDependencySynthesizer> = context.scope;\n\tconst providers =\n\t\tscope.IFluidDependencySynthesizer?.synthesize<I[\"OptionalProviders\"]>(\n\t\t\toptionalProviders,\n\t\t\t{},\n\t\t) ??\n\t\t// eslint-disable-next-line @typescript-eslint/consistent-type-assertions\n\t\t({} as AsyncFluidObjectProvider<never>);\n\n\tconst instance = new ctor({ runtime, context, providers, initProps });\n\n\t// if it's a newly created object, we need to wait for it to finish initialization\n\t// as that results in creation of DDSes, before it gets attached, providing atomic\n\t// guarantee of creation.\n\t// WARNING: we can't do the same (yet) for already existing PureDataObject!\n\t// This will result in deadlock, as it tries to resolve internal handles, but any\n\t// handle resolution goes through root (container runtime), which can't route it back\n\t// to this data store, as it's still not initialized and not known to container runtime yet.\n\t// In the future, we should address it by using relative paths for handles and be able to resolve\n\t// local DDSes while data store is not fully initialized.\n\tif (!existing) {\n\t\tawait instance.finishInitialization(existing);\n\t}\n\n\treturn { instance, runtime };\n}\n\n/**\n * Represents the properties required to create a DataObjectFactory.\n * This includes the type identifier, constructor, shared objects, optional providers,\n * registry entries, and the runtime class to use for the data object.\n * @typeParam TObj - DataObject (concrete type)\n * @typeParam I - The input types for the DataObject\n * @legacy @beta\n */\nexport interface DataObjectFactoryProps<\n\tTObj extends PureDataObject<I>,\n\tI extends DataObjectTypes = DataObjectTypes,\n> {\n\t/**\n\t * The type identifier for the data object factory.\n\t */\n\treadonly type: string;\n\n\t/**\n\t * The constructor for the data object.\n\t */\n\treadonly ctor: new (\n\t\tprops: IDataObjectProps<I>,\n\t) => TObj;\n\n\t/**\n\t * The shared objects (DDSes) to be registered with the data object.\n\t */\n\treadonly sharedObjects?: readonly IChannelFactory[];\n\n\t/**\n\t * Optional providers for dependency injection.\n\t */\n\treadonly optionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>;\n\n\t/**\n\t * Registry entries for named data stores.\n\t */\n\treadonly registryEntries?: NamedFluidDataStoreRegistryEntries;\n\n\t/**\n\t * The runtime class to use for the data object.\n\t */\n\treadonly runtimeClass?: typeof FluidDataStoreRuntime;\n\n\t/**\n\t * Optional policies that can be applied to the DataObject.\n\t * These policies define specific behaviors or constraints for the data object.\n\t */\n\treadonly policies?: Partial<IFluidDataStorePolicies>;\n}\n\n/**\n * PureDataObjectFactory is a bare-bones IFluidDataStoreFactory for use with PureDataObject.\n * Consumers should typically use DataObjectFactory instead unless creating\n * another base data store factory.\n *\n * @typeParam TObj - DataObject (concrete type)\n * @typeParam I - The input types for the DataObject\n * @legacy @beta\n */\nexport class PureDataObjectFactory<\n\tTObj extends PureDataObject<I>,\n\tI extends DataObjectTypes = DataObjectTypes,\n> implements IFluidDataStoreFactory, Partial<IProvideFluidDataStoreRegistry>\n{\n\tprivate readonly registry: IFluidDataStoreRegistry | undefined;\n\tprivate readonly createProps: Omit<CreateDataObjectProps<TObj, I>, \"existing\" | \"context\">;\n\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IFluidDataStoreFactory.\"type\"}\n\t */\n\tpublic readonly type: string;\n\n\t/**\n\t * @remarks Use the props object based constructor instead.\n\t * No new features will be added to this constructor,\n\t * and it will eventually be deprecated and removed.\n\t */\n\tpublic constructor(\n\t\ttype: string,\n\t\tctor: new (props: IDataObjectProps<I>) => TObj,\n\t\tsharedObjects?: readonly IChannelFactory[],\n\t\toptionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>,\n\t\tregistryEntries?: NamedFluidDataStoreRegistryEntries,\n\t\truntimeClass?: typeof FluidDataStoreRuntime,\n\t);\n\tpublic constructor(props: DataObjectFactoryProps<TObj, I>);\n\tpublic constructor(\n\t\tpropsOrType: DataObjectFactoryProps<TObj, I> | string,\n\t\tmaybeCtor?: new (doProps: IDataObjectProps<I>) => TObj,\n\t\tmaybeSharedObjects?: readonly IChannelFactory[],\n\t\tmaybeOptionalProviders?: FluidObjectSymbolProvider<I[\"OptionalProviders\"]>,\n\t\tmaybeRegistryEntries?: NamedFluidDataStoreRegistryEntries,\n\t\tmaybeRuntimeFactory?: typeof FluidDataStoreRuntime,\n\t) {\n\t\tconst newProps =\n\t\t\ttypeof propsOrType === \"string\"\n\t\t\t\t? {\n\t\t\t\t\t\ttype: propsOrType,\n\t\t\t\t\t\t// both the arg and props base constructor require this param\n\t\t\t\t\t\t// eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n\t\t\t\t\t\tctor: maybeCtor!,\n\t\t\t\t\t\tsharedObjects: maybeSharedObjects,\n\t\t\t\t\t\toptionalProviders: maybeOptionalProviders,\n\t\t\t\t\t\tregistryEntries: maybeRegistryEntries,\n\t\t\t\t\t\truntimeClass: maybeRuntimeFactory,\n\t\t\t\t\t}\n\t\t\t\t: propsOrType;\n\n\t\tif (newProps.type === \"\") {\n\t\t\tthrow new Error(\"undefined type member\");\n\t\t}\n\t\tthis.type = newProps.type;\n\n\t\tthis.createProps = {\n\t\t\tctor: newProps.ctor,\n\t\t\toptionalProviders: newProps.optionalProviders ?? {},\n\t\t\tsharedObjectRegistry: new Map(newProps.sharedObjects?.map((ext) => [ext.type, ext])),\n\t\t\truntimeClassArg: newProps.runtimeClass ?? FluidDataStoreRuntime,\n\t\t\tpolicies: newProps.policies,\n\t\t};\n\n\t\tif (newProps.registryEntries !== undefined) {\n\t\t\tthis.registry = new FluidDataStoreRegistry(newProps.registryEntries);\n\t\t}\n\t}\n\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IProvideFluidDataStoreFactory.IFluidDataStoreFactory}\n\t */\n\tpublic get IFluidDataStoreFactory(): this {\n\t\treturn this;\n\t}\n\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IProvideFluidDataStoreRegistry.IFluidDataStoreRegistry}\n\t */\n\tpublic get IFluidDataStoreRegistry(): IFluidDataStoreRegistry | undefined {\n\t\treturn this.registry;\n\t}\n\n\t/**\n\t * Convenience helper to get the data store's/factory's data store registry entry.\n\t * The return type hides the factory's generics, easing grouping of registry\n\t * entries that differ only in this way into the same array.\n\t * @returns The NamedFluidDataStoreRegistryEntry\n\t */\n\tpublic get registryEntry(): NamedFluidDataStoreRegistryEntry {\n\t\treturn [this.type, Promise.resolve(this)];\n\t}\n\n\t/**\n\t * {@inheritDoc @fluidframework/runtime-definitions#IFluidDataStoreFactory.instantiateDataStore}\n\t */\n\tpublic async instantiateDataStore(\n\t\tcontext: IFluidDataStoreContext,\n\t\texisting: boolean,\n\t): Promise<IFluidDataStoreChannel> {\n\t\tconst { runtime } = await createDataObject({ ...this.createProps, context, existing });\n\n\t\treturn runtime;\n\t}\n\n\t/**\n\t * Creates a new instance of the object. Uses parent context's registry to build package path to this factory.\n\t * In other words, registry of context passed in has to contain this factory, with the name that matches\n\t * this factory's type.\n\t * It is intended to be used by data store objects that create sub-objects.\n\t * @param context - The context being used to create the runtime\n\t * (the created object will have its own new context created as well)\n\t * @param initialState - The initial state to provide to the created data store.\n\t * @param loadingGroupId - NOT production ready, EXPERIMENTAL, please read {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}. The service needs to support this feature, does not work for most services\n\t * @returns an object created by this factory. Data store and objects created are not attached to container.\n\t * They get attached only when a handle to one of them is attached to already attached objects.\n\t */\n\tpublic async createChildInstance(\n\t\tparentContext: IFluidDataStoreContext,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tloadingGroupId?: string,\n\t): Promise<TObj> {\n\t\treturn this.createNonRootInstanceCore(\n\t\t\tparentContext.containerRuntime,\n\t\t\t[...parentContext.packagePath, this.type],\n\t\t\tinitialState,\n\t\t\tloadingGroupId,\n\t\t);\n\t}\n\n\t/**\n\t * Creates a new instance of the object. Uses peer context's registry and its package path to identify this factory.\n\t * In other words, registry of context passed in has to have this factory.\n\t * Intended to be used by data store objects that need to create peers (similar) instances of existing objects.\n\t * @param context - The component context being used to create the object\n\t * (the created object will have its own new context created as well)\n\t * @param initialState - The initial state to provide to the created component.\n\t * @param loadingGroupId - NOT production ready, EXPERIMENTAL, please read {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}. The service needs to support this feature, does not work for most services\n\t * @returns an object created by this factory. Data store and objects created are not attached to container.\n\t * They get attached only when a handle to one of them is attached to already attached objects.\n\t */\n\tpublic async createPeerInstance(\n\t\tpeerContext: IFluidDataStoreContext,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tloadingGroupId?: string, // DO NOT USE, this is an experimental feature\n\t): Promise<TObj> {\n\t\treturn this.createNonRootInstanceCore(\n\t\t\tpeerContext.containerRuntime,\n\t\t\tpeerContext.packagePath,\n\t\t\tinitialState,\n\t\t\tloadingGroupId,\n\t\t);\n\t}\n\n\t/**\n\t * Creates a new instance of the object. Uses container's registry to find this factory.\n\t * It's expected that only container owners would use this functionality, as only such developers\n\t * have knowledge of entries in container registry.\n\t * The name in this registry for such record should match type of this factory.\n\t * @param runtime - container runtime. It's registry is used to create an object.\n\t * @param initialState - The initial state to provide to the created component.\n\t * @param loadingGroupId - NOT production ready, EXPERIMENTAL, please read {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}. The service needs to support this feature, does not work for most services\n\t * @returns an object created by this factory. Data store and objects created are not attached to container.\n\t * They get attached only when a handle to one of them is attached to already attached objects.\n\t */\n\tpublic async createInstance(\n\t\truntime: IContainerRuntimeBase,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tloadingGroupId?: string,\n\t): Promise<TObj> {\n\t\treturn this.createNonRootInstanceCore(runtime, [this.type], initialState, loadingGroupId);\n\t}\n\n\t/**\n\t * Creates a new instance of the object with a datastore which exposes the aliasing api.\n\t * @param runtime - container runtime. It is the runtime that will be used to create the object. It will produce\n\t * the underlying infrastructure to get the data object to operate.\n\t * @param initialState - The initial state to provide to the created component.\n\t * @param packagePath - The path to the data store factory to use to create the data object.\n\t * @param loadingGroupId - NOT production ready, EXPERIMENTAL, please read {@link https://github.com/microsoft/FluidFramework/blob/main/packages/runtime/container-runtime/README.md | README}. The service needs to support this feature, does not work for most services\n\t * @returns an array containing the object created by this factory and an IDataStore object that enables users to\n\t * alias the data object.\n\t * The data object is attached only when it is attached to the handle graph that connects to an aliased object or\n\t * when the data object is aliased.\n\t */\n\tpublic async createInstanceWithDataStore(\n\t\tcontainerRuntime: IContainerRuntimeBase,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tpackagePath?: Readonly<string[]>,\n\t\tloadingGroupId?: string,\n\t): Promise<[TObj, IDataStore]> {\n\t\tconst context = containerRuntime.createDetachedDataStore(\n\t\t\tpackagePath ?? [this.type],\n\t\t\tloadingGroupId,\n\t\t);\n\t\tconst { instance, runtime } = await createDataObject({\n\t\t\t...this.createProps,\n\t\t\tcontext,\n\t\t\texisting: false,\n\t\t\tinitialState,\n\t\t});\n\t\tconst dataStore = await context.attachRuntime(this, runtime);\n\n\t\treturn [instance, dataStore];\n\t}\n\n\t/**\n\t * Creates a new root instance of the object. Uses container's registry to find this factory.\n\t * It's expected that only container owners would use this functionality, as only such developers\n\t * have knowledge of entries in container registry.\n\t * The name in this registry for such record should match type of this factory.\n\t * @param runtime - container runtime. It's registry is used to create an object.\n\t * @param initialState - The initial state to provide to the created component.\n\t * @returns an object created by this factory. Data store and objects created are not attached to container.\n\t * They get attached only when a handle to one of them is attached to already attached objects.\n\t *\n\t * @deprecated - the issue is that it does not allow the customer to decide the conflict resolution policy when an\n\t * aliasing conflict occurs. Use {@link PureDataObjectFactory.createInstanceWithDataStore} instead.\n\t */\n\tpublic async createRootInstance(\n\t\trootDataStoreId: string,\n\t\truntime: IContainerRuntime,\n\t\tinitialState?: I[\"InitialState\"],\n\t): Promise<TObj> {\n\t\tconst context = runtime.createDetachedDataStore([this.type]);\n\t\tconst { instance, runtime: dataStoreRuntime } = await createDataObject({\n\t\t\t...this.createProps,\n\t\t\tcontext,\n\t\t\texisting: false,\n\t\t\tinitialState,\n\t\t});\n\t\tconst dataStore = await context.attachRuntime(this, dataStoreRuntime);\n\t\tconst result = await dataStore.trySetAlias(rootDataStoreId);\n\t\tif (result !== \"Success\") {\n\t\t\tconst handle = await runtime.getAliasedDataStoreEntryPoint(rootDataStoreId);\n\t\t\tassert(handle !== undefined, 0x8e1 /* Should have retrieved aliased handle */);\n\t\t\treturn (await handle.get()) as TObj;\n\t\t}\n\t\treturn instance;\n\t}\n\n\tprotected async createNonRootInstanceCore(\n\t\tcontainerRuntime: IContainerRuntimeBase,\n\t\tpackagePath: Readonly<string[]>,\n\t\tinitialState?: I[\"InitialState\"],\n\t\tloadingGroupId?: string,\n\t): Promise<TObj> {\n\t\tconst context = containerRuntime.createDetachedDataStore(packagePath, loadingGroupId);\n\t\treturn this.createInstanceCore(context, initialState);\n\t}\n\n\tprotected async createInstanceCore(\n\t\tcontext: IFluidDataStoreContextDetached,\n\t\tinitialState?: I[\"InitialState\"],\n\t): Promise<TObj> {\n\t\tconst { instance, runtime } = await createDataObject({\n\t\t\t...this.createProps,\n\t\t\tcontext,\n\t\t\texisting: false,\n\t\t\tinitialState,\n\t\t});\n\n\t\tawait context.attachRuntime(this, runtime);\n\n\t\treturn instance;\n\t}\n}\n"]}
@@ -10,7 +10,7 @@ import { PureDataObjectFactory, type DataObjectFactoryProps } from "./pureDataOb
10
10
  * @typeParam TDataObject - The concrete TreeDataObject implementation.
11
11
  * @typeParam TDataObjectTypes - The input types for the DataObject
12
12
  *
13
- * @legacy @alpha
13
+ * @legacy @beta
14
14
  */
15
15
  export declare class TreeDataObjectFactory<TDataObject extends TreeDataObject<TDataObjectTypes>, TDataObjectTypes extends DataObjectTypes = DataObjectTypes> extends PureDataObjectFactory<TDataObject, TDataObjectTypes> {
16
16
  constructor(props: DataObjectFactoryProps<TDataObject, TDataObjectTypes>);
@@ -13,7 +13,7 @@ const pureDataObjectFactory_js_1 = require("./pureDataObjectFactory.js");
13
13
  * @typeParam TDataObject - The concrete TreeDataObject implementation.
14
14
  * @typeParam TDataObjectTypes - The input types for the DataObject
15
15
  *
16
- * @legacy @alpha
16
+ * @legacy @beta
17
17
  */
18
18
  class TreeDataObjectFactory extends pureDataObjectFactory_js_1.PureDataObjectFactory {
19
19
  constructor(props) {
@@ -1 +1 @@
1
- {"version":3,"file":"treeDataObjectFactory.js","sourceRoot":"","sources":["../../src/data-object-factories/treeDataObjectFactory.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,4DAA2D;AAI3D,yEAGoC;AAEpC;;;;;;;GAOG;AACH,MAAa,qBAGX,SAAQ,gDAAoD;IAC7D,YAAmB,KAA4D;QAC9E,MAAM,QAAQ,GAAG;YAChB,GAAG,KAAK;YACR,aAAa,EAAE,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,EAAE;SAClE,CAAC;QAEF,kFAAkF;QAClF,IACC,CAAC,QAAQ,CAAC,aAAa,CAAC,IAAI,CAC3B,CAAC,YAAY,EAAE,EAAE,CAAC,YAAY,CAAC,IAAI,KAAK,qBAAU,CAAC,UAAU,EAAE,CAAC,IAAI,CACpE,EACA,CAAC;YACF,QAAQ,CAAC,aAAa,CAAC,IAAI,CAAC,qBAAU,CAAC,UAAU,EAAE,CAAC,CAAC;QACtD,CAAC;QAED,KAAK,CAAC,QAAQ,CAAC,CAAC;IACjB,CAAC;CACD;AArBD,sDAqBC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { SharedTree } from \"@fluidframework/tree/internal\";\n\nimport type { DataObjectTypes, TreeDataObject } from \"../data-objects/index.js\";\n\nimport {\n\tPureDataObjectFactory,\n\ttype DataObjectFactoryProps,\n} from \"./pureDataObjectFactory.js\";\n\n/**\n * {@link @fluidframework/runtime-definitions#IFluidDataStoreFactory} for use with {@link TreeDataObject}s.\n *\n * @typeParam TDataObject - The concrete TreeDataObject implementation.\n * @typeParam TDataObjectTypes - The input types for the DataObject\n *\n * @legacy @alpha\n */\nexport class TreeDataObjectFactory<\n\tTDataObject extends TreeDataObject<TDataObjectTypes>,\n\tTDataObjectTypes extends DataObjectTypes = DataObjectTypes,\n> extends PureDataObjectFactory<TDataObject, TDataObjectTypes> {\n\tpublic constructor(props: DataObjectFactoryProps<TDataObject, TDataObjectTypes>) {\n\t\tconst newProps = {\n\t\t\t...props,\n\t\t\tsharedObjects: props.sharedObjects ? [...props.sharedObjects] : [],\n\t\t};\n\n\t\t// If the user did not specify a SharedTree factory, add it to the shared objects.\n\t\tif (\n\t\t\t!newProps.sharedObjects.some(\n\t\t\t\t(sharedObject) => sharedObject.type === SharedTree.getFactory().type,\n\t\t\t)\n\t\t) {\n\t\t\tnewProps.sharedObjects.push(SharedTree.getFactory());\n\t\t}\n\n\t\tsuper(newProps);\n\t}\n}\n"]}
1
+ {"version":3,"file":"treeDataObjectFactory.js","sourceRoot":"","sources":["../../src/data-object-factories/treeDataObjectFactory.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,4DAA2D;AAI3D,yEAGoC;AAEpC;;;;;;;GAOG;AACH,MAAa,qBAGX,SAAQ,gDAAoD;IAC7D,YAAmB,KAA4D;QAC9E,MAAM,QAAQ,GAAG;YAChB,GAAG,KAAK;YACR,aAAa,EAAE,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,GAAG,KAAK,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,EAAE;SAClE,CAAC;QAEF,kFAAkF;QAClF,IACC,CAAC,QAAQ,CAAC,aAAa,CAAC,IAAI,CAC3B,CAAC,YAAY,EAAE,EAAE,CAAC,YAAY,CAAC,IAAI,KAAK,qBAAU,CAAC,UAAU,EAAE,CAAC,IAAI,CACpE,EACA,CAAC;YACF,QAAQ,CAAC,aAAa,CAAC,IAAI,CAAC,qBAAU,CAAC,UAAU,EAAE,CAAC,CAAC;QACtD,CAAC;QAED,KAAK,CAAC,QAAQ,CAAC,CAAC;IACjB,CAAC;CACD;AArBD,sDAqBC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { SharedTree } from \"@fluidframework/tree/internal\";\n\nimport type { DataObjectTypes, TreeDataObject } from \"../data-objects/index.js\";\n\nimport {\n\tPureDataObjectFactory,\n\ttype DataObjectFactoryProps,\n} from \"./pureDataObjectFactory.js\";\n\n/**\n * {@link @fluidframework/runtime-definitions#IFluidDataStoreFactory} for use with {@link TreeDataObject}s.\n *\n * @typeParam TDataObject - The concrete TreeDataObject implementation.\n * @typeParam TDataObjectTypes - The input types for the DataObject\n *\n * @legacy @beta\n */\nexport class TreeDataObjectFactory<\n\tTDataObject extends TreeDataObject<TDataObjectTypes>,\n\tTDataObjectTypes extends DataObjectTypes = DataObjectTypes,\n> extends PureDataObjectFactory<TDataObject, TDataObjectTypes> {\n\tpublic constructor(props: DataObjectFactoryProps<TDataObject, TDataObjectTypes>) {\n\t\tconst newProps = {\n\t\t\t...props,\n\t\t\tsharedObjects: props.sharedObjects ? [...props.sharedObjects] : [],\n\t\t};\n\n\t\t// If the user did not specify a SharedTree factory, add it to the shared objects.\n\t\tif (\n\t\t\t!newProps.sharedObjects.some(\n\t\t\t\t(sharedObject) => sharedObject.type === SharedTree.getFactory().type,\n\t\t\t)\n\t\t) {\n\t\t\tnewProps.sharedObjects.push(SharedTree.getFactory());\n\t\t}\n\n\t\tsuper(newProps);\n\t}\n}\n"]}
@@ -15,7 +15,7 @@ import type { DataObjectTypes } from "./types.js";
15
15
  *
16
16
  * @typeParam I - The optional input types used to strongly type the data object
17
17
  * @legacy
18
- * @alpha
18
+ * @beta
19
19
  */
20
20
  export declare abstract class DataObject<I extends DataObjectTypes = DataObjectTypes> extends PureDataObject<I> {
21
21
  private internalRoot;
@@ -17,7 +17,7 @@ const pureDataObject_js_1 = require("./pureDataObject.js");
17
17
  *
18
18
  * @typeParam I - The optional input types used to strongly type the data object
19
19
  * @legacy
20
- * @alpha
20
+ * @beta
21
21
  */
22
22
  class DataObject extends pureDataObject_js_1.PureDataObject {
23
23
  constructor() {
@@ -1 +1 @@
1
- {"version":3,"file":"dataObject.js","sourceRoot":"","sources":["../../src/data-objects/dataObject.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,2DAIsC;AAEtC,2DAAqD;A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,gCAwDC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport {\n\ttype ISharedDirectory,\n\tMapFactory,\n\tSharedDirectory,\n} from \"@fluidframework/map/internal\";\n\nimport { PureDataObject } from \"./pureDataObject.js\";\nimport type { DataObjectTypes } from \"./types.js\";\n\n/**\n * DataObject is a base data store that is primed with a root directory. It\n * ensures that it is created and ready before you can access it.\n *\n * Having a single root directory allows for easier development. Instead of creating\n * and registering channels with the runtime any new DDS that is set on the root\n * will automatically be registered.\n *\n * @typeParam I - The optional input types used to strongly type the data object\n * @legacy\n * @alpha\n */\nexport abstract class DataObject<\n\tI extends DataObjectTypes = DataObjectTypes,\n> extends PureDataObject<I> {\n\tprivate internalRoot: ISharedDirectory | undefined;\n\tprivate readonly rootDirectoryId = \"root\";\n\n\t/**\n\t * The root directory will either be ready or will return an error. If an error is thrown\n\t * the root has not been correctly created/set.\n\t */\n\tprotected get root(): ISharedDirectory {\n\t\tif (!this.internalRoot) {\n\t\t\tthrow new Error(this.getUninitializedErrorString(`root`));\n\t\t}\n\n\t\treturn this.internalRoot;\n\t}\n\n\t/**\n\t * Initializes internal objects and calls initialization overrides.\n\t * Caller is responsible for ensuring this is only invoked once.\n\t */\n\tpublic override async initializeInternal(existing: boolean): Promise<void> {\n\t\tif (existing) {\n\t\t\t// data store has a root directory so we just need to set it before calling initializingFromExisting\n\t\t\tthis.internalRoot = (await this.runtime.getChannel(\n\t\t\t\tthis.rootDirectoryId,\n\t\t\t)) as ISharedDirectory;\n\n\t\t\t// This will actually be an ISharedMap if the channel was previously created by the older version of\n\t\t\t// DataObject which used a SharedMap. Since SharedMap and SharedDirectory are compatible unless\n\t\t\t// SharedDirectory-only commands are used on SharedMap, this will mostly just work for compatibility.\n\t\t\tif (this.internalRoot.attributes.type === MapFactory.Type) {\n\t\t\t\tthis.runtime.logger.send({\n\t\t\t\t\tcategory: \"generic\",\n\t\t\t\t\teventName: \"MapDataObject\",\n\t\t\t\t\tmessage:\n\t\t\t\t\t\t\"Legacy document, SharedMap is masquerading as SharedDirectory in DataObject\",\n\t\t\t\t});\n\t\t\t}\n\t\t} else {\n\t\t\t// Create a root directory and register it before calling initializingFirstTime\n\t\t\tthis.internalRoot = SharedDirectory.create(this.runtime, this.rootDirectoryId);\n\t\t\tthis.internalRoot.bindToContext();\n\t\t}\n\n\t\tawait super.initializeInternal(existing);\n\t}\n\n\t/**\n\t * Generates an error string indicating an item is uninitialized.\n\t * @param item - The name of the item that was uninitialized.\n\t */\n\tprotected getUninitializedErrorString(item: string): string {\n\t\treturn `${item} must be initialized before being accessed.`;\n\t}\n}\n"]}
1
+ {"version":3,"file":"dataObject.js","sourceRoot":"","sources":["../../src/data-objects/dataObject.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,2DAIsC;AAEtC,2DAAqD;AAGrD;;;;;;;;;;;GAWG;AACH,MAAsB,UAEpB,SAAQ,kCAAiB;IAF3B;;QAIkB,oBAAe,GAAG,MAAM,CAAC;IAoD3C,CAAC;IAlDA;;;OAGG;IACH,IAAc,IAAI;QACjB,IAAI,CAAC,IAAI,CAAC,YAAY,EAAE,CAAC;YACxB,MAAM,IAAI,KAAK,CAAC,IAAI,CAAC,2BAA2B,CAAC,MAAM,CAAC,CAAC,CAAC;QAC3D,CAAC;QAED,OAAO,IAAI,CAAC,YAAY,CAAC;IAC1B,CAAC;IAED;;;OAGG;IACa,KAAK,CAAC,kBAAkB,CAAC,QAAiB;QACzD,IAAI,QAAQ,EAAE,CAAC;YACd,oGAAoG;YACpG,IAAI,CAAC,YAAY,GAAG,CAAC,MAAM,IAAI,CAAC,OAAO,CAAC,UAAU,CACjD,IAAI,CAAC,eAAe,CACpB,CAAqB,CAAC;YAEvB,oGAAoG;YACpG,gGAAgG;YAChG,qGAAqG;YACrG,IAAI,IAAI,CAAC,YAAY,CAAC,UAAU,CAAC,IAAI,KAAK,qBAAU,CAAC,IAAI,EAAE,CAAC;gBAC3D,IAAI,CAAC,OAAO,CAAC,MAAM,CAAC,IAAI,CAAC;oBACxB,QAAQ,EAAE,SAAS;oBACnB,SAAS,EAAE,eAAe;oBAC1B,OAAO,EACN,6EAA6E;iBAC9E,CAAC,CAAC;YACJ,CAAC;QACF,CAAC;aAAM,CAAC;YACP,+EAA+E;YAC/E,IAAI,CAAC,YAAY,GAAG,0BAAe,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,eAAe,CAAC,CAAC;YAC/E,IAAI,CAAC,YAAY,CAAC,aAAa,EAAE,CAAC;QACnC,CAAC;QAED,MAAM,KAAK,CAAC,kBAAkB,CAAC,QAAQ,CAAC,CAAC;IAC1C,CAAC;IAED;;;OAGG;IACO,2BAA2B,CAAC,IAAY;QACjD,OAAO,GAAG,IAAI,6CAA6C,CAAC;IAC7D,CAAC;CACD;AAxDD,gCAwDC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport {\n\ttype ISharedDirectory,\n\tMapFactory,\n\tSharedDirectory,\n} from \"@fluidframework/map/internal\";\n\nimport { PureDataObject } from \"./pureDataObject.js\";\nimport type { DataObjectTypes } from \"./types.js\";\n\n/**\n * DataObject is a base data store that is primed with a root directory. It\n * ensures that it is created and ready before you can access it.\n *\n * Having a single root directory allows for easier development. Instead of creating\n * and registering channels with the runtime any new DDS that is set on the root\n * will automatically be registered.\n *\n * @typeParam I - The optional input types used to strongly type the data object\n * @legacy\n * @beta\n */\nexport abstract class DataObject<\n\tI extends DataObjectTypes = DataObjectTypes,\n> extends PureDataObject<I> {\n\tprivate internalRoot: ISharedDirectory | undefined;\n\tprivate readonly rootDirectoryId = \"root\";\n\n\t/**\n\t * The root directory will either be ready or will return an error. If an error is thrown\n\t * the root has not been correctly created/set.\n\t */\n\tprotected get root(): ISharedDirectory {\n\t\tif (!this.internalRoot) {\n\t\t\tthrow new Error(this.getUninitializedErrorString(`root`));\n\t\t}\n\n\t\treturn this.internalRoot;\n\t}\n\n\t/**\n\t * Initializes internal objects and calls initialization overrides.\n\t * Caller is responsible for ensuring this is only invoked once.\n\t */\n\tpublic override async initializeInternal(existing: boolean): Promise<void> {\n\t\tif (existing) {\n\t\t\t// data store has a root directory so we just need to set it before calling initializingFromExisting\n\t\t\tthis.internalRoot = (await this.runtime.getChannel(\n\t\t\t\tthis.rootDirectoryId,\n\t\t\t)) as ISharedDirectory;\n\n\t\t\t// This will actually be an ISharedMap if the channel was previously created by the older version of\n\t\t\t// DataObject which used a SharedMap. Since SharedMap and SharedDirectory are compatible unless\n\t\t\t// SharedDirectory-only commands are used on SharedMap, this will mostly just work for compatibility.\n\t\t\tif (this.internalRoot.attributes.type === MapFactory.Type) {\n\t\t\t\tthis.runtime.logger.send({\n\t\t\t\t\tcategory: \"generic\",\n\t\t\t\t\teventName: \"MapDataObject\",\n\t\t\t\t\tmessage:\n\t\t\t\t\t\t\"Legacy document, SharedMap is masquerading as SharedDirectory in DataObject\",\n\t\t\t\t});\n\t\t\t}\n\t\t} else {\n\t\t\t// Create a root directory and register it before calling initializingFirstTime\n\t\t\tthis.internalRoot = SharedDirectory.create(this.runtime, this.rootDirectoryId);\n\t\t\tthis.internalRoot.bindToContext();\n\t\t}\n\n\t\tawait super.initializeInternal(existing);\n\t}\n\n\t/**\n\t * Generates an error string indicating an item is uninitialized.\n\t * @param item - The name of the item that was uninitialized.\n\t */\n\tprotected getUninitializedErrorString(item: string): string {\n\t\treturn `${item} must be initialized before being accessed.`;\n\t}\n}\n"]}
@@ -17,8 +17,7 @@ import type { DataObjectTypes, IDataObjectProps } from "./types.js";
17
17
  * you are creating another base data store class.
18
18
  *
19
19
  * @typeParam I - The optional input types used to strongly type the data object
20
- * @legacy
21
- * @alpha
20
+ * @legacy @beta
22
21
  */
23
22
  export declare abstract class PureDataObject<I extends DataObjectTypes = DataObjectTypes> extends TypedEventEmitter<I["Events"] & IEvent> implements IFluidLoadable, IProvideFluidHandle {
24
23
  /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OAAO,GAAG,OAAO,CAAC,IAAI,CAAC;IAKnE;;;;;;OAMG;IACU,kBAAkB,CAAC,QAAQ,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC;IAgBjE;;;OAGG;cACa,aAAa,IAAI,OAAO,CAAC,IAAI,CAAC;IAE9C;;;;;OAKG;cACa,qBAAqB,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC,cAAc,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC;IAE/E;;;OAGG;cACa,wBAAwB,IAAI,OAAO,CAAC,IAAI,CAAC;IAEzD;;OAEG;cACa,cAAc,IAAI,OAAO,CAAC,IAAI,CAAC;CAC/C"}
@@ -16,8 +16,7 @@ const internal_2 = require("@fluidframework/runtime-utils/internal");
16
16
  * you are creating another base data store class.
17
17
  *
18
18
  * @typeParam I - The optional input types used to strongly type the data object
19
- * @legacy
20
- * @alpha
19
+ * @legacy @beta
21
20
  */
22
21
  class PureDataObject extends client_utils_1.TypedEventEmitter {
23
22
  get id() {