@fluidframework/datastore 2.0.0-internal.7.0.0 → 2.0.0-internal.7.2.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.
- package/CHANGELOG.md +8 -0
- package/api-extractor.json +1 -1
- package/api-report/datastore.api.md +171 -0
- package/dist/dataStoreRuntime.d.ts +21 -3
- package/dist/dataStoreRuntime.d.ts.map +1 -1
- package/dist/dataStoreRuntime.js +19 -4
- package/dist/dataStoreRuntime.js.map +1 -1
- package/dist/fluidHandle.d.ts +2 -0
- package/dist/fluidHandle.d.ts.map +1 -1
- package/dist/fluidHandle.js +2 -0
- package/dist/fluidHandle.js.map +1 -1
- package/dist/tsdoc-metadata.json +1 -1
- package/lib/dataStoreRuntime.d.ts +21 -3
- package/lib/dataStoreRuntime.d.ts.map +1 -1
- package/lib/dataStoreRuntime.js +19 -4
- package/lib/dataStoreRuntime.js.map +1 -1
- package/lib/fluidHandle.d.ts +2 -0
- package/lib/fluidHandle.d.ts.map +1 -1
- package/lib/fluidHandle.js +2 -0
- package/lib/fluidHandle.js.map +1 -1
- package/package.json +24 -30
- package/src/dataStoreRuntime.ts +22 -4
- package/src/fluidHandle.ts +2 -0
package/CHANGELOG.md
CHANGED
package/api-extractor.json
CHANGED
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
## API Report File for "@fluidframework/datastore"
|
|
2
|
+
|
|
3
|
+
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
|
|
4
|
+
|
|
5
|
+
```ts
|
|
6
|
+
|
|
7
|
+
import { AttachState } from '@fluidframework/container-definitions';
|
|
8
|
+
import { FluidObject } from '@fluidframework/core-interfaces';
|
|
9
|
+
import { IAudience } from '@fluidframework/container-definitions';
|
|
10
|
+
import { IChannel } from '@fluidframework/datastore-definitions';
|
|
11
|
+
import { IChannelFactory } from '@fluidframework/datastore-definitions';
|
|
12
|
+
import { IClientDetails } from '@fluidframework/protocol-definitions';
|
|
13
|
+
import { IDeltaManager } from '@fluidframework/container-definitions';
|
|
14
|
+
import { IDocumentMessage } from '@fluidframework/protocol-definitions';
|
|
15
|
+
import { IFluidDataStoreChannel } from '@fluidframework/runtime-definitions';
|
|
16
|
+
import { IFluidDataStoreContext } from '@fluidframework/runtime-definitions';
|
|
17
|
+
import { IFluidDataStoreRuntime } from '@fluidframework/datastore-definitions';
|
|
18
|
+
import { IFluidDataStoreRuntimeEvents } from '@fluidframework/datastore-definitions';
|
|
19
|
+
import { IFluidHandle } from '@fluidframework/core-interfaces';
|
|
20
|
+
import { IFluidHandleContext } from '@fluidframework/core-interfaces';
|
|
21
|
+
import { IGarbageCollectionData } from '@fluidframework/runtime-definitions';
|
|
22
|
+
import { IIdCompressor } from '@fluidframework/runtime-definitions';
|
|
23
|
+
import { IInboundSignalMessage } from '@fluidframework/runtime-definitions';
|
|
24
|
+
import { ILoaderOptions } from '@fluidframework/container-definitions';
|
|
25
|
+
import { IQuorumClients } from '@fluidframework/protocol-definitions';
|
|
26
|
+
import { IRequest } from '@fluidframework/core-interfaces';
|
|
27
|
+
import { IResponse } from '@fluidframework/core-interfaces';
|
|
28
|
+
import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
|
|
29
|
+
import { ISummaryTreeWithStats } from '@fluidframework/runtime-definitions';
|
|
30
|
+
import { ITelemetryContext } from '@fluidframework/runtime-definitions';
|
|
31
|
+
import { ITelemetryLoggerExt } from '@fluidframework/telemetry-utils';
|
|
32
|
+
import { TypedEventEmitter } from '@fluid-internal/client-utils';
|
|
33
|
+
import { VisibilityState } from '@fluidframework/runtime-definitions';
|
|
34
|
+
|
|
35
|
+
// @public (undocumented)
|
|
36
|
+
export enum DataStoreMessageType {
|
|
37
|
+
// (undocumented)
|
|
38
|
+
Attach = "attach",
|
|
39
|
+
// (undocumented)
|
|
40
|
+
ChannelOp = "op"
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
// @public
|
|
44
|
+
export class FluidDataStoreRuntime extends TypedEventEmitter<IFluidDataStoreRuntimeEvents> implements IFluidDataStoreChannel, IFluidDataStoreRuntime, IFluidHandleContext {
|
|
45
|
+
constructor(dataStoreContext: IFluidDataStoreContext, sharedObjectRegistry: ISharedObjectRegistry, existing: boolean, provideEntryPoint: (runtime: IFluidDataStoreRuntime) => Promise<FluidObject>);
|
|
46
|
+
// (undocumented)
|
|
47
|
+
get absolutePath(): string;
|
|
48
|
+
// (undocumented)
|
|
49
|
+
applyStashedOp(content: any): Promise<unknown>;
|
|
50
|
+
attachGraph(): void;
|
|
51
|
+
// (undocumented)
|
|
52
|
+
get attachState(): AttachState;
|
|
53
|
+
// (undocumented)
|
|
54
|
+
bind(handle: IFluidHandle): void;
|
|
55
|
+
bindChannel(channel: IChannel): void;
|
|
56
|
+
// (undocumented)
|
|
57
|
+
get channelsRoutingContext(): this;
|
|
58
|
+
// (undocumented)
|
|
59
|
+
get clientDetails(): IClientDetails;
|
|
60
|
+
// (undocumented)
|
|
61
|
+
get clientId(): string | undefined;
|
|
62
|
+
// (undocumented)
|
|
63
|
+
get connected(): boolean;
|
|
64
|
+
// (undocumented)
|
|
65
|
+
createChannel(id: string | undefined, type: string): IChannel;
|
|
66
|
+
// (undocumented)
|
|
67
|
+
readonly deltaManager: IDeltaManager<ISequencedDocumentMessage, IDocumentMessage>;
|
|
68
|
+
// (undocumented)
|
|
69
|
+
dispose(): void;
|
|
70
|
+
// (undocumented)
|
|
71
|
+
get disposed(): boolean;
|
|
72
|
+
ensureNoDataModelChanges<T>(callback: () => T): T;
|
|
73
|
+
// (undocumented)
|
|
74
|
+
readonly entryPoint: IFluidHandle<FluidObject>;
|
|
75
|
+
// (undocumented)
|
|
76
|
+
getAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;
|
|
77
|
+
// (undocumented)
|
|
78
|
+
getAudience(): IAudience;
|
|
79
|
+
// (undocumented)
|
|
80
|
+
getChannel(id: string): Promise<IChannel>;
|
|
81
|
+
getGCData(fullGC?: boolean): Promise<IGarbageCollectionData>;
|
|
82
|
+
// (undocumented)
|
|
83
|
+
getQuorum(): IQuorumClients;
|
|
84
|
+
// (undocumented)
|
|
85
|
+
readonly id: string;
|
|
86
|
+
// (undocumented)
|
|
87
|
+
get idCompressor(): IIdCompressor | undefined;
|
|
88
|
+
// (undocumented)
|
|
89
|
+
get IFluidHandleContext(): this;
|
|
90
|
+
// @deprecated (undocumented)
|
|
91
|
+
get IFluidRouter(): this;
|
|
92
|
+
// (undocumented)
|
|
93
|
+
get isAttached(): boolean;
|
|
94
|
+
// @deprecated (undocumented)
|
|
95
|
+
static load(context: IFluidDataStoreContext, sharedObjectRegistry: ISharedObjectRegistry, existing: boolean): FluidDataStoreRuntime;
|
|
96
|
+
// (undocumented)
|
|
97
|
+
get logger(): ITelemetryLoggerExt;
|
|
98
|
+
makeVisibleAndAttachGraph(): void;
|
|
99
|
+
// (undocumented)
|
|
100
|
+
get objectsRoutingContext(): this;
|
|
101
|
+
// (undocumented)
|
|
102
|
+
readonly options: ILoaderOptions;
|
|
103
|
+
// (undocumented)
|
|
104
|
+
process(message: ISequencedDocumentMessage, local: boolean, localOpMetadata: unknown): void;
|
|
105
|
+
// (undocumented)
|
|
106
|
+
processSignal(message: IInboundSignalMessage, local: boolean): void;
|
|
107
|
+
// (undocumented)
|
|
108
|
+
request(request: IRequest): Promise<IResponse>;
|
|
109
|
+
// (undocumented)
|
|
110
|
+
resolveHandle(request: IRequest): Promise<IResponse>;
|
|
111
|
+
reSubmit(type: DataStoreMessageType, content: any, localOpMetadata: unknown): void;
|
|
112
|
+
rollback?(type: DataStoreMessageType, content: any, localOpMetadata: unknown): void;
|
|
113
|
+
// (undocumented)
|
|
114
|
+
get rootRoutingContext(): this;
|
|
115
|
+
// (undocumented)
|
|
116
|
+
get routeContext(): IFluidHandleContext;
|
|
117
|
+
// (undocumented)
|
|
118
|
+
setConnectionState(connected: boolean, clientId?: string): void;
|
|
119
|
+
// (undocumented)
|
|
120
|
+
submitMessage(type: DataStoreMessageType, content: any, localOpMetadata: unknown): void;
|
|
121
|
+
submitSignal(type: string, content: any, targetClientId?: string): void;
|
|
122
|
+
summarize(fullTree?: boolean, trackState?: boolean, telemetryContext?: ITelemetryContext): Promise<ISummaryTreeWithStats>;
|
|
123
|
+
updateUsedRoutes(usedRoutes: string[]): void;
|
|
124
|
+
// (undocumented)
|
|
125
|
+
uploadBlob(blob: ArrayBufferLike, signal?: AbortSignal): Promise<IFluidHandle<ArrayBufferLike>>;
|
|
126
|
+
// (undocumented)
|
|
127
|
+
visibilityState: VisibilityState;
|
|
128
|
+
waitAttached(): Promise<void>;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
// @public
|
|
132
|
+
export class FluidObjectHandle<T extends FluidObject = FluidObject> implements IFluidHandle {
|
|
133
|
+
constructor(value: T | Promise<T>, path: string, routeContext: IFluidHandleContext);
|
|
134
|
+
// (undocumented)
|
|
135
|
+
readonly absolutePath: string;
|
|
136
|
+
// (undocumented)
|
|
137
|
+
attachGraph(): void;
|
|
138
|
+
// (undocumented)
|
|
139
|
+
bind(handle: IFluidHandle): void;
|
|
140
|
+
// (undocumented)
|
|
141
|
+
get(): Promise<any>;
|
|
142
|
+
// (undocumented)
|
|
143
|
+
get IFluidHandle(): IFluidHandle;
|
|
144
|
+
// (undocumented)
|
|
145
|
+
get isAttached(): boolean;
|
|
146
|
+
// (undocumented)
|
|
147
|
+
readonly path: string;
|
|
148
|
+
// (undocumented)
|
|
149
|
+
readonly routeContext: IFluidHandleContext;
|
|
150
|
+
// (undocumented)
|
|
151
|
+
protected readonly value: T | Promise<T>;
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
// @public (undocumented)
|
|
155
|
+
export interface ISharedObjectRegistry {
|
|
156
|
+
// (undocumented)
|
|
157
|
+
get(name: string): IChannelFactory | undefined;
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
// @public
|
|
161
|
+
export const mixinRequestHandler: (requestHandler: (request: IRequest, runtime: FluidDataStoreRuntime) => Promise<IResponse>, Base?: typeof FluidDataStoreRuntime) => typeof FluidDataStoreRuntime;
|
|
162
|
+
|
|
163
|
+
// @public
|
|
164
|
+
export const mixinSummaryHandler: (handler: (runtime: FluidDataStoreRuntime) => Promise<{
|
|
165
|
+
path: string[];
|
|
166
|
+
content: string;
|
|
167
|
+
} | undefined>, Base?: typeof FluidDataStoreRuntime) => typeof FluidDataStoreRuntime;
|
|
168
|
+
|
|
169
|
+
// (No @packageDocumentation comment for this package)
|
|
170
|
+
|
|
171
|
+
```
|
|
@@ -9,21 +9,29 @@ import { IAudience, IDeltaManager, AttachState, ILoaderOptions } from "@fluidfra
|
|
|
9
9
|
import { IClientDetails, IDocumentMessage, ISequencedDocumentMessage, IQuorumClients } from "@fluidframework/protocol-definitions";
|
|
10
10
|
import { IFluidDataStoreContext, IFluidDataStoreChannel, IGarbageCollectionData, IInboundSignalMessage, ISummaryTreeWithStats, VisibilityState, ITelemetryContext, IIdCompressor } from "@fluidframework/runtime-definitions";
|
|
11
11
|
import { IChannel, IFluidDataStoreRuntime, IFluidDataStoreRuntimeEvents, IChannelFactory } from "@fluidframework/datastore-definitions";
|
|
12
|
+
/**
|
|
13
|
+
* @public
|
|
14
|
+
*/
|
|
12
15
|
export declare enum DataStoreMessageType {
|
|
13
16
|
Attach = "attach",
|
|
14
17
|
ChannelOp = "op"
|
|
15
18
|
}
|
|
19
|
+
/**
|
|
20
|
+
* @public
|
|
21
|
+
*/
|
|
16
22
|
export interface ISharedObjectRegistry {
|
|
17
23
|
get(name: string): IChannelFactory | undefined;
|
|
18
24
|
}
|
|
19
25
|
/**
|
|
20
26
|
* Base data store class
|
|
27
|
+
*
|
|
28
|
+
* @public
|
|
21
29
|
*/
|
|
22
30
|
export declare class FluidDataStoreRuntime extends TypedEventEmitter<IFluidDataStoreRuntimeEvents> implements IFluidDataStoreChannel, IFluidDataStoreRuntime, IFluidHandleContext {
|
|
23
31
|
private readonly dataStoreContext;
|
|
24
32
|
private readonly sharedObjectRegistry;
|
|
25
33
|
/**
|
|
26
|
-
* @deprecated
|
|
34
|
+
* @deprecated Instantiate the class using its constructor instead.
|
|
27
35
|
*
|
|
28
36
|
* Loads the data store runtime
|
|
29
37
|
* @param context - The data store context
|
|
@@ -36,7 +44,7 @@ export declare class FluidDataStoreRuntime extends TypedEventEmitter<IFluidDataS
|
|
|
36
44
|
*/
|
|
37
45
|
readonly entryPoint: IFluidHandle<FluidObject>;
|
|
38
46
|
/**
|
|
39
|
-
* @deprecated
|
|
47
|
+
* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
|
|
40
48
|
*/
|
|
41
49
|
get IFluidRouter(): this;
|
|
42
50
|
get connected(): boolean;
|
|
@@ -182,7 +190,13 @@ export declare class FluidDataStoreRuntime extends TypedEventEmitter<IFluidDataS
|
|
|
182
190
|
summarize(fullTree?: boolean, trackState?: boolean, telemetryContext?: ITelemetryContext): Promise<ISummaryTreeWithStats>;
|
|
183
191
|
getAttachSummary(telemetryContext?: ITelemetryContext): ISummaryTreeWithStats;
|
|
184
192
|
submitMessage(type: DataStoreMessageType, content: any, localOpMetadata: unknown): void;
|
|
185
|
-
|
|
193
|
+
/**
|
|
194
|
+
* Submits the signal to be sent to other clients.
|
|
195
|
+
* @param type - Type of the signal.
|
|
196
|
+
* @param content - Content of the signal.
|
|
197
|
+
* @param targetClientId - When specified, the signal is only sent to the provided client id.
|
|
198
|
+
*/
|
|
199
|
+
submitSignal(type: string, content: any, targetClientId?: string): void;
|
|
186
200
|
/**
|
|
187
201
|
* Will return when the data store is attached.
|
|
188
202
|
*/
|
|
@@ -224,6 +238,8 @@ export declare class FluidDataStoreRuntime extends TypedEventEmitter<IFluidDataS
|
|
|
224
238
|
* Request handler is only called when data store can't resolve request, i.e. for custom requests.
|
|
225
239
|
* @param Base - base class, inherits from FluidDataStoreRuntime
|
|
226
240
|
* @param requestHandler - request handler to mix in
|
|
241
|
+
*
|
|
242
|
+
* @public
|
|
227
243
|
*/
|
|
228
244
|
export declare const mixinRequestHandler: (requestHandler: (request: IRequest, runtime: FluidDataStoreRuntime) => Promise<IResponse>, Base?: typeof FluidDataStoreRuntime) => typeof FluidDataStoreRuntime;
|
|
229
245
|
/**
|
|
@@ -231,6 +247,8 @@ export declare const mixinRequestHandler: (requestHandler: (request: IRequest, r
|
|
|
231
247
|
* @param handler - handler that returns info about blob to be added to summary.
|
|
232
248
|
* Or undefined not to add anything to summary.
|
|
233
249
|
* @param Base - base class, inherits from FluidDataStoreRuntime
|
|
250
|
+
*
|
|
251
|
+
* @public
|
|
234
252
|
*/
|
|
235
253
|
export declare const mixinSummaryHandler: (handler: (runtime: FluidDataStoreRuntime) => Promise<{
|
|
236
254
|
path: string[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dataStoreRuntime.d.ts","sourceRoot":"","sources":["../src/dataStoreRuntime.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,iBAAiB,EAAE,MAAM,8BAA8B,CAAC;AACjE,OAAO,EAEN,mBAAmB,EAQnB,MAAM,iCAAiC,CAAC;AACzC,OAAO,EACN,WAAW,EACX,YAAY,EACZ,mBAAmB,EACnB,QAAQ,EACR,SAAS,EACT,MAAM,iCAAiC,CAAC;AAEzC,OAAO,EACN,SAAS,EACT,aAAa,EACb,WAAW,EACX,cAAc,EACd,MAAM,uCAAuC,CAAC;AAE/C,OAAO,EACN,cAAc,EACd,gBAAgB,EAChB,yBAAyB,EAIzB,cAAc,EACd,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAKN,sBAAsB,EACtB,sBAAsB,EACtB,sBAAsB,EACtB,qBAAqB,EACrB,qBAAqB,EACrB,eAAe,EACf,iBAAiB,EACjB,aAAa,EACb,MAAM,qCAAqC,CAAC;AAa7C,OAAO,EACN,QAAQ,EACR,sBAAsB,EACtB,4BAA4B,EAC5B,eAAe,EACf,MAAM,uCAAuC,CAAC;AAW/C,oBAAY,oBAAoB;IAE/B,MA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c,CAAC,OAAO,EAAE,GAAG,GAAG,OAAO,CAAC,OAAO,CAAC;IAgC3D,OAAO,CAAC,eAAe;IAKvB,OAAO,CAAC,gBAAgB;IAqBxB,OAAO,CAAC,cAAc;IA0CtB,OAAO,CAAC,eAAe;IAMvB;;;;OAIG;IACH,OAAO,CAAC,+BAA+B;CAwBvC;AAED;;;;;;;GAOG;AACH,eAAO,MAAM,mBAAmB,6BACL,QAAQ,WAAW,qBAAqB,KAAK,QAAQ,SAAS,CAAC,SACnF,4BAA4B,iCAUD,CAAC;AAEnC;;;;;;;GAOG;AACH,eAAO,MAAM,mBAAmB,sBAErB,qBAAqB,KAC1B,QAAQ;IAAE,IAAI,EAAE,MAAM,EAAE,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,GAAG,SAAS,CAAC,SACvD,4BAA4B,iCAyCD,CAAC"}
|
package/dist/dataStoreRuntime.js
CHANGED
|
@@ -18,6 +18,9 @@ const channelContext_1 = require("./channelContext");
|
|
|
18
18
|
const localChannelContext_1 = require("./localChannelContext");
|
|
19
19
|
const remoteChannelContext_1 = require("./remoteChannelContext");
|
|
20
20
|
const fluidHandle_1 = require("./fluidHandle");
|
|
21
|
+
/**
|
|
22
|
+
* @public
|
|
23
|
+
*/
|
|
21
24
|
var DataStoreMessageType;
|
|
22
25
|
(function (DataStoreMessageType) {
|
|
23
26
|
// Creates a new channel
|
|
@@ -26,10 +29,12 @@ var DataStoreMessageType;
|
|
|
26
29
|
})(DataStoreMessageType || (exports.DataStoreMessageType = DataStoreMessageType = {}));
|
|
27
30
|
/**
|
|
28
31
|
* Base data store class
|
|
32
|
+
*
|
|
33
|
+
* @public
|
|
29
34
|
*/
|
|
30
35
|
class FluidDataStoreRuntime extends client_utils_1.TypedEventEmitter {
|
|
31
36
|
/**
|
|
32
|
-
* @deprecated
|
|
37
|
+
* @deprecated Instantiate the class using its constructor instead.
|
|
33
38
|
*
|
|
34
39
|
* Loads the data store runtime
|
|
35
40
|
* @param context - The data store context
|
|
@@ -40,7 +45,7 @@ class FluidDataStoreRuntime extends client_utils_1.TypedEventEmitter {
|
|
|
40
45
|
return new FluidDataStoreRuntime(context, sharedObjectRegistry, existing, async (dataStoreRuntime) => dataStoreRuntime.entryPoint);
|
|
41
46
|
}
|
|
42
47
|
/**
|
|
43
|
-
* @deprecated
|
|
48
|
+
* @deprecated Will be removed in future major release. Migrate all usage of IFluidRouter to the "entryPoint" pattern. Refer to Removing-IFluidRouter.md
|
|
44
49
|
*/
|
|
45
50
|
get IFluidRouter() {
|
|
46
51
|
return this;
|
|
@@ -548,9 +553,15 @@ class FluidDataStoreRuntime extends client_utils_1.TypedEventEmitter {
|
|
|
548
553
|
submitMessage(type, content, localOpMetadata) {
|
|
549
554
|
this.submit(type, content, localOpMetadata);
|
|
550
555
|
}
|
|
551
|
-
|
|
556
|
+
/**
|
|
557
|
+
* Submits the signal to be sent to other clients.
|
|
558
|
+
* @param type - Type of the signal.
|
|
559
|
+
* @param content - Content of the signal.
|
|
560
|
+
* @param targetClientId - When specified, the signal is only sent to the provided client id.
|
|
561
|
+
*/
|
|
562
|
+
submitSignal(type, content, targetClientId) {
|
|
552
563
|
this.verifyNotClosed();
|
|
553
|
-
return this.dataStoreContext.submitSignal(type, content);
|
|
564
|
+
return this.dataStoreContext.submitSignal(type, content, targetClientId);
|
|
554
565
|
}
|
|
555
566
|
/**
|
|
556
567
|
* Will return when the data store is attached.
|
|
@@ -745,6 +756,8 @@ exports.FluidDataStoreRuntime = FluidDataStoreRuntime;
|
|
|
745
756
|
* Request handler is only called when data store can't resolve request, i.e. for custom requests.
|
|
746
757
|
* @param Base - base class, inherits from FluidDataStoreRuntime
|
|
747
758
|
* @param requestHandler - request handler to mix in
|
|
759
|
+
*
|
|
760
|
+
* @public
|
|
748
761
|
*/
|
|
749
762
|
const mixinRequestHandler = (requestHandler, Base = FluidDataStoreRuntime) => class RuntimeWithRequestHandler extends Base {
|
|
750
763
|
async request(request) {
|
|
@@ -761,6 +774,8 @@ exports.mixinRequestHandler = mixinRequestHandler;
|
|
|
761
774
|
* @param handler - handler that returns info about blob to be added to summary.
|
|
762
775
|
* Or undefined not to add anything to summary.
|
|
763
776
|
* @param Base - base class, inherits from FluidDataStoreRuntime
|
|
777
|
+
*
|
|
778
|
+
* @public
|
|
764
779
|
*/
|
|
765
780
|
const mixinSummaryHandler = (handler, Base = FluidDataStoreRuntime) => class RuntimeWithSummarizerHandler extends Base {
|
|
766
781
|
addBlob(summary, path, content) {
|