@fluidframework/odsp-driver-definitions 2.1.0-276326 → 2.1.0-281041
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/README.md +3 -1
- package/api-extractor/{api-extractor-lint-beta.cjs.json → api-extractor.current.json} +2 -2
- package/api-extractor/api-extractor.legacy.json +1 -1
- package/api-extractor.json +1 -1
- package/api-report/odsp-driver-definitions.legacy.alpha.api.md +3 -3
- package/api-report/odsp-driver-definitions.legacy.public.api.md +9 -0
- package/dist/factory.d.ts +2 -2
- package/dist/factory.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/legacy.d.ts +1 -1
- package/dist/odspCache.d.ts +6 -1
- package/dist/odspCache.d.ts.map +1 -1
- package/dist/odspCache.js +6 -1
- package/dist/odspCache.js.map +1 -1
- package/dist/public.d.ts +1 -1
- package/dist/tokenFetch.d.ts +1 -1
- package/dist/tokenFetch.js.map +1 -1
- package/internal.d.ts +1 -1
- package/legacy.d.ts +1 -1
- package/lib/factory.d.ts +2 -2
- package/lib/factory.js.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/legacy.d.ts +1 -1
- package/lib/odspCache.d.ts +6 -1
- package/lib/odspCache.d.ts.map +1 -1
- package/lib/odspCache.js +5 -0
- package/lib/odspCache.js.map +1 -1
- package/lib/public.d.ts +1 -1
- package/lib/tokenFetch.d.ts +1 -1
- package/lib/tokenFetch.js.map +1 -1
- package/package.json +27 -27
- package/src/factory.ts +2 -2
- package/src/index.ts +1 -0
- package/src/odspCache.ts +8 -1
- package/src/tokenFetch.ts +1 -1
- package/api-extractor/api-extractor-lint-beta.esm.json +0 -5
- package/beta.d.ts +0 -11
- package/dist/beta.d.ts +0 -12
- package/lib/beta.d.ts +0 -12
package/README.md
CHANGED
|
@@ -12,10 +12,12 @@ Though the host is responsible for implementing the IPersistedCache, snapshot ca
|
|
|
12
12
|
|
|
13
13
|
## Using Fluid Framework libraries
|
|
14
14
|
|
|
15
|
-
When taking a dependency on a Fluid Framework library, we recommend using a `^` (caret) version range, such as `^1.3.4`.
|
|
15
|
+
When taking a dependency on a Fluid Framework library's public APIs, we recommend using a `^` (caret) version range, such as `^1.3.4`.
|
|
16
16
|
While Fluid Framework libraries may use different ranges with interdependencies between other Fluid Framework libraries,
|
|
17
17
|
library consumers should always prefer `^`.
|
|
18
18
|
|
|
19
|
+
If using any of Fluid Framework's unstable APIs (for example, its `beta` APIs), we recommend using a more constrained version range, such as `~`.
|
|
20
|
+
|
|
19
21
|
<!-- prettier-ignore-end -->
|
|
20
22
|
|
|
21
23
|
<!-- AUTO-GENERATED-CONTENT:END -->
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
|
|
3
|
-
"extends": "<projectFolder>/../../../common/build/build-common/api-extractor-
|
|
4
|
-
"mainEntryPointFilePath": "<projectFolder>/
|
|
3
|
+
"extends": "<projectFolder>/../../../common/build/build-common/api-extractor-report.esm.current.json",
|
|
4
|
+
"mainEntryPointFilePath": "<projectFolder>/lib/public.d.ts"
|
|
5
5
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
|
|
3
|
-
"extends": "<projectFolder>/../../../common/build/build-common/api-extractor-
|
|
3
|
+
"extends": "<projectFolder>/../../../common/build/build-common/api-extractor-report.esm.legacy.json"
|
|
4
4
|
}
|
package/api-extractor.json
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
|
|
3
|
-
"extends": "../../../common/build/build-common/api-extractor-
|
|
3
|
+
"extends": "../../../common/build/build-common/api-extractor-model.esm.json"
|
|
4
4
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
```ts
|
|
6
6
|
|
|
7
7
|
// @alpha (undocumented)
|
|
8
|
-
export type CacheContentType = "snapshot" | "ops";
|
|
8
|
+
export type CacheContentType = "snapshot" | "ops" | "snapshotWithLoadingGroupId";
|
|
9
9
|
|
|
10
10
|
// @alpha (undocumented)
|
|
11
11
|
export interface HostStoragePolicy {
|
|
@@ -37,9 +37,9 @@ export interface ICacheEntry extends IEntry {
|
|
|
37
37
|
|
|
38
38
|
// @alpha (undocumented)
|
|
39
39
|
export interface ICollabSessionOptions {
|
|
40
|
-
// @deprecated
|
|
40
|
+
// @deprecated
|
|
41
41
|
forceAccessTokenViaAuthorizationHeader?: boolean;
|
|
42
|
-
// @deprecated
|
|
42
|
+
// @deprecated
|
|
43
43
|
unauthenticatedUserDisplayName?: string;
|
|
44
44
|
}
|
|
45
45
|
|
package/dist/factory.d.ts
CHANGED
|
@@ -55,13 +55,12 @@ export interface IOpsCachingPolicy {
|
|
|
55
55
|
*/
|
|
56
56
|
export interface ICollabSessionOptions {
|
|
57
57
|
/**
|
|
58
|
-
* @deprecated starting in 2.0-RC3. No longer needed.
|
|
59
58
|
* Value indicating the display name for session that admits unauthenticated user.
|
|
60
59
|
* This name will be used in attribution associated with edits made by such user.
|
|
60
|
+
* @deprecated starting in 2.0-RC3. No longer needed.
|
|
61
61
|
*/
|
|
62
62
|
unauthenticatedUserDisplayName?: string;
|
|
63
63
|
/**
|
|
64
|
-
* @deprecated Due to security reasons we will be passing the token via Authorization header only.
|
|
65
64
|
* Value indicating session preference to always pass access token via Authorization header.
|
|
66
65
|
* Default behavior is to pass access token via query parameter unless overall href string
|
|
67
66
|
* length exceeds 2048 characters. Using query param is performance optimization which results
|
|
@@ -69,6 +68,7 @@ export interface ICollabSessionOptions {
|
|
|
69
68
|
* validate CORS. However, not all ODSP implementations understand this optimization.
|
|
70
69
|
* For instance, auth layer on Converged stack will fail request with access token passed via
|
|
71
70
|
* query param.
|
|
71
|
+
* @deprecated Due to security reasons we will be passing the token via Authorization header only.
|
|
72
72
|
*/
|
|
73
73
|
forceAccessTokenViaAuthorizationHeader?: boolean;
|
|
74
74
|
}
|
package/dist/factory.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"factory.js","sourceRoot":"","sources":["../src/factory.ts"],"names":[],"mappings":";AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * @legacy\n * @alpha\n */\nexport interface ISnapshotOptions {\n\tblobs?: number;\n\tdeltas?: number;\n\tchannels?: number;\n\n\t/**\n\t * Maximum Data size (in bytes)\n\t *\n\t * @remarks\n\t * If specified, SPO will fail snapshot request with 413 error (see {@link @fluidframework/odsp-driver-definitions#(OdspErrorTypes:variable).snapshotTooBig})\n\t * if snapshot is bigger in size than specified limit.\n\t */\n\tmds?: number;\n\n\t/*\n\t * Maximum time limit to fetch snapshot (in seconds)\n\t * If specified, client will timeout the fetch request if it exceeds the time limit and\n\t * will try to fetch the snapshot without blobs.\n\t */\n\ttimeout?: number;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface IOpsCachingPolicy {\n\t/**\n\t * Batch size. Controls how many ops are grouped together as single cache entry\n\t * The bigger the number, the more efficient it is (less reads & writes)\n\t * At the same time, big number means we wait for so many ops to accumulate, which\n\t * increases chances and number of trailing ops that would not be flushed to cache\n\t * when user closes tab\n\t * Use any number below 1 to disable caching\n\t * Default: 100\n\t */\n\tbatchSize?: number;\n\n\t/**\n\t * To reduce the problem of losing trailing ops when using big batch sizes, host\n\t * could specify how often driver should flush ops it has not flushed yet.\n\t * -1 means do not use timer.\n\t * Measured in ms.\n\t * Default: 5000\n\t */\n\ttimerGranularity?: number;\n\n\t/**\n\t * Total number of ops to cache. When we reach that number, ops caching stops\n\t * Default: 5000\n\t */\n\ttotalOpsToCache?: number;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface ICollabSessionOptions {\n\t/**\n\t *
|
|
1
|
+
{"version":3,"file":"factory.js","sourceRoot":"","sources":["../src/factory.ts"],"names":[],"mappings":";AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * @legacy\n * @alpha\n */\nexport interface ISnapshotOptions {\n\tblobs?: number;\n\tdeltas?: number;\n\tchannels?: number;\n\n\t/**\n\t * Maximum Data size (in bytes)\n\t *\n\t * @remarks\n\t * If specified, SPO will fail snapshot request with 413 error (see {@link @fluidframework/odsp-driver-definitions#(OdspErrorTypes:variable).snapshotTooBig})\n\t * if snapshot is bigger in size than specified limit.\n\t */\n\tmds?: number;\n\n\t/*\n\t * Maximum time limit to fetch snapshot (in seconds)\n\t * If specified, client will timeout the fetch request if it exceeds the time limit and\n\t * will try to fetch the snapshot without blobs.\n\t */\n\ttimeout?: number;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface IOpsCachingPolicy {\n\t/**\n\t * Batch size. Controls how many ops are grouped together as single cache entry\n\t * The bigger the number, the more efficient it is (less reads & writes)\n\t * At the same time, big number means we wait for so many ops to accumulate, which\n\t * increases chances and number of trailing ops that would not be flushed to cache\n\t * when user closes tab\n\t * Use any number below 1 to disable caching\n\t * Default: 100\n\t */\n\tbatchSize?: number;\n\n\t/**\n\t * To reduce the problem of losing trailing ops when using big batch sizes, host\n\t * could specify how often driver should flush ops it has not flushed yet.\n\t * -1 means do not use timer.\n\t * Measured in ms.\n\t * Default: 5000\n\t */\n\ttimerGranularity?: number;\n\n\t/**\n\t * Total number of ops to cache. When we reach that number, ops caching stops\n\t * Default: 5000\n\t */\n\ttotalOpsToCache?: number;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface ICollabSessionOptions {\n\t/**\n\t * Value indicating the display name for session that admits unauthenticated user.\n\t * This name will be used in attribution associated with edits made by such user.\n\t * @deprecated starting in 2.0-RC3. No longer needed.\n\t */\n\tunauthenticatedUserDisplayName?: string;\n\t/**\n\t * Value indicating session preference to always pass access token via Authorization header.\n\t * Default behavior is to pass access token via query parameter unless overall href string\n\t * length exceeds 2048 characters. Using query param is performance optimization which results\n\t * in ODSP XHR request being treated as 'simple' request which do not require OPTIONS call to\n\t * validate CORS. However, not all ODSP implementations understand this optimization.\n\t * For instance, auth layer on Converged stack will fail request with access token passed via\n\t * query param.\n\t * @deprecated Due to security reasons we will be passing the token via Authorization header only.\n\t */\n\tforceAccessTokenViaAuthorizationHeader?: boolean;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface HostStoragePolicy {\n\tsnapshotOptions?: ISnapshotOptions;\n\n\t/**\n\t * If set to true, tells driver to concurrently fetch snapshot from storage (SPO) and cache\n\t * Container loads from whatever comes first in such case.\n\t * Snapshot fetched from storage is pushed to cache in either case.\n\t * If set to false, driver will first consult with cache. Only on cache miss (cache does not\n\t * return snapshot), driver will fetch snapshot from storage (and push it to cache), otherwise\n\t * it will load from cache and not reach out to storage.\n\t * Passing true results in faster loads and keeping cache more current, but it increases bandwidth consumption.\n\t */\n\tconcurrentSnapshotFetch?: boolean;\n\n\t// Options overwriting default ops fetching from storage.\n\topsBatchSize?: number;\n\tconcurrentOpsBatches?: number;\n\n\t/**\n\t * Policy controlling ops caching (leveraging IPersistedCache passed to driver factory)\n\t */\n\topsCaching?: IOpsCachingPolicy;\n\n\t/**\n\t * Policy controlling how collaboration session is established\n\t */\n\tsessionOptions?: ICollabSessionOptions;\n\n\t/**\n\t * @deprecated This field will be always set to true after removal.\n\t * True to have the sharing link redeem fallback in case the Trees Latest/Redeem 1RT call fails with redeem error.\n\t * During fallback it will first redeem the sharing link and then make the Trees latest call.\n\t */\n\tenableRedeemFallback?: boolean;\n\n\t/**\n\t * Policy controlling if we will cache initial summary when we create a document\n\t */\n\tcacheCreateNewSummary?: boolean;\n\n\t/**\n\t * @deprecated This will be replaced with feature gate snapshotFormatFetchType.\n\t * Policy controlling if we want to fetch binary format snapshot.\n\t */\n\tfetchBinarySnapshotFormat?: boolean;\n\n\t/**\n\t * If set to true, socket cache are per OdspDocumentService instead of shared across all instances\n\t */\n\tisolateSocketCache?: boolean;\n\n\t/**\n\t * @deprecated Switch to using the new feature gated by enableSingleRequestForShareLinkWithCreate\n\t * with 'createLinkScope' and 'createLinkRole' is requested to the odsp apis instead of 'createLinkType'.\n\t * It enables the creation of sharing link along with the creation of file by setting this value to true.\n\t * If the host provides a 'createLinkType' parameter in the request URL to the container.attach()\n\t * method, we will send the request to ODSP with the same (if the flag is enabled) so\n\t * that a share link can be created with the creation of file to save number for round trips made to ODSP.\n\t * (This flag works independently of enableSingleRequestForShareLinkWithCreate which is used for sharing link\n\t * requests where 'createLinkScope' is requested.)\n\t */\n\tenableShareLinkWithCreate?: boolean;\n\n\t/**\n\t * Enable creation of sharing link along with the creation of file by setting this value to true.\n\t * If the host provides a 'createLinkScope' parameter in the request URL to the container.attach()\n\t * method, we will send the request to ODSP with the same (if the flag is enabled) so\n\t * that a share link can be created with the creation of file to save number for round trips made to ODSP.\n\t * (This flag works independently of enableShareLinkWithCreate which was used for old sharing link requests\n\t * where 'createLinkType' was requested.)\n\t */\n\tenableSingleRequestForShareLinkWithCreate?: boolean;\n\n\t/**\n\t * True if host does not want the storage service to use the prefetch cache to get the snapshot. Undefined will be treated\n\t * as false. This is if the host wants to do some A/B testing.\n\t */\n\tavoidPrefetchSnapshotCache?: boolean;\n}\n"]}
|
package/dist/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
export { IOdspError, IOdspErrorAugmentations, OdspError, OdspErrorTypes } from "./errors.js";
|
|
6
6
|
export { HostStoragePolicy, ICollabSessionOptions, IOpsCachingPolicy, ISnapshotOptions, } from "./factory.js";
|
|
7
|
-
export { CacheContentType, maximumCacheDurationMs, getKeyForCacheEntry, ICacheEntry, IEntry, IFileEntry, IPersistedCache, snapshotKey, } from "./odspCache.js";
|
|
7
|
+
export { CacheContentType, maximumCacheDurationMs, getKeyForCacheEntry, ICacheEntry, IEntry, IFileEntry, IPersistedCache, snapshotKey, snapshotWithLoadingGroupIdKey, } from "./odspCache.js";
|
|
8
8
|
export { IOdspResolvedUrl, IOdspUrlParts, ISharingLink, ISharingLinkKind, ShareLinkInfoType, SharingLinkRole, SharingLinkScope, } from "./resolvedUrl.js";
|
|
9
9
|
export { IdentityType, InstrumentedStorageTokenFetcher, InstrumentedTokenFetcher, isTokenFromCache, OdspResourceTokenFetchOptions, TokenFetcher, TokenFetchOptions, authHeaderFromTokenResponse, tokenFromResponse, TokenResponse, } from "./tokenFetch.js";
|
|
10
10
|
export { IProvideSessionAwareDriverFactory, IRelaySessionAwareDriverFactory, ISocketStorageDiscovery, } from "./sessionProvider.js";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,UAAU,EAAE,uBAAuB,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7F,OAAO,EACN,iBAAiB,EACjB,qBAAqB,EACrB,iBAAiB,EACjB,gBAAgB,GAChB,MAAM,cAAc,CAAC;AACtB,OAAO,EACN,gBAAgB,EAChB,sBAAsB,EACtB,mBAAmB,EACnB,WAAW,EACX,MAAM,EACN,UAAU,EACV,eAAe,EACf,WAAW,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,UAAU,EAAE,uBAAuB,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7F,OAAO,EACN,iBAAiB,EACjB,qBAAqB,EACrB,iBAAiB,EACjB,gBAAgB,GAChB,MAAM,cAAc,CAAC;AACtB,OAAO,EACN,gBAAgB,EAChB,sBAAsB,EACtB,mBAAmB,EACnB,WAAW,EACX,MAAM,EACN,UAAU,EACV,eAAe,EACf,WAAW,EACX,6BAA6B,GAC7B,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACN,gBAAgB,EAChB,aAAa,EACb,YAAY,EACZ,gBAAgB,EAChB,iBAAiB,EACjB,eAAe,EACf,gBAAgB,GAChB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACN,YAAY,EACZ,+BAA+B,EAC/B,wBAAwB,EACxB,gBAAgB,EAChB,6BAA6B,EAC7B,YAAY,EACZ,iBAAiB,EACjB,2BAA2B,EAC3B,iBAAiB,EACjB,aAAa,GACb,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACN,iCAAiC,EACjC,+BAA+B,EAC/B,uBAAuB,GACvB,MAAM,sBAAsB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -4,13 +4,14 @@
|
|
|
4
4
|
* Licensed under the MIT License.
|
|
5
5
|
*/
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
-
exports.tokenFromResponse = exports.authHeaderFromTokenResponse = exports.isTokenFromCache = exports.SharingLinkScope = exports.SharingLinkRole = exports.snapshotKey = exports.getKeyForCacheEntry = exports.maximumCacheDurationMs = exports.OdspErrorTypes = void 0;
|
|
7
|
+
exports.tokenFromResponse = exports.authHeaderFromTokenResponse = exports.isTokenFromCache = exports.SharingLinkScope = exports.SharingLinkRole = exports.snapshotWithLoadingGroupIdKey = exports.snapshotKey = exports.getKeyForCacheEntry = exports.maximumCacheDurationMs = exports.OdspErrorTypes = void 0;
|
|
8
8
|
var errors_js_1 = require("./errors.js");
|
|
9
9
|
Object.defineProperty(exports, "OdspErrorTypes", { enumerable: true, get: function () { return errors_js_1.OdspErrorTypes; } });
|
|
10
10
|
var odspCache_js_1 = require("./odspCache.js");
|
|
11
11
|
Object.defineProperty(exports, "maximumCacheDurationMs", { enumerable: true, get: function () { return odspCache_js_1.maximumCacheDurationMs; } });
|
|
12
12
|
Object.defineProperty(exports, "getKeyForCacheEntry", { enumerable: true, get: function () { return odspCache_js_1.getKeyForCacheEntry; } });
|
|
13
13
|
Object.defineProperty(exports, "snapshotKey", { enumerable: true, get: function () { return odspCache_js_1.snapshotKey; } });
|
|
14
|
+
Object.defineProperty(exports, "snapshotWithLoadingGroupIdKey", { enumerable: true, get: function () { return odspCache_js_1.snapshotWithLoadingGroupIdKey; } });
|
|
14
15
|
var resolvedUrl_js_1 = require("./resolvedUrl.js");
|
|
15
16
|
Object.defineProperty(exports, "SharingLinkRole", { enumerable: true, get: function () { return resolvedUrl_js_1.SharingLinkRole; } });
|
|
16
17
|
Object.defineProperty(exports, "SharingLinkScope", { enumerable: true, get: function () { return resolvedUrl_js_1.SharingLinkScope; } });
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,yCAA6F;AAApC,2GAAA,cAAc,OAAA;AAOvE,+
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,yCAA6F;AAApC,2GAAA,cAAc,OAAA;AAOvE,+CAUwB;AARvB,sHAAA,sBAAsB,OAAA;AACtB,mHAAA,mBAAmB,OAAA;AAKnB,2GAAA,WAAW,OAAA;AACX,6HAAA,6BAA6B,OAAA;AAE9B,mDAQ0B;AAFzB,iHAAA,eAAe,OAAA;AACf,kHAAA,gBAAgB,OAAA;AAEjB,iDAWyB;AAPxB,iHAAA,gBAAgB,OAAA;AAIhB,4HAAA,2BAA2B,OAAA;AAC3B,kHAAA,iBAAiB,OAAA","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport { IOdspError, IOdspErrorAugmentations, OdspError, OdspErrorTypes } from \"./errors.js\";\nexport {\n\tHostStoragePolicy,\n\tICollabSessionOptions,\n\tIOpsCachingPolicy,\n\tISnapshotOptions,\n} from \"./factory.js\";\nexport {\n\tCacheContentType,\n\tmaximumCacheDurationMs,\n\tgetKeyForCacheEntry,\n\tICacheEntry,\n\tIEntry,\n\tIFileEntry,\n\tIPersistedCache,\n\tsnapshotKey,\n\tsnapshotWithLoadingGroupIdKey,\n} from \"./odspCache.js\";\nexport {\n\tIOdspResolvedUrl,\n\tIOdspUrlParts,\n\tISharingLink,\n\tISharingLinkKind,\n\tShareLinkInfoType,\n\tSharingLinkRole,\n\tSharingLinkScope,\n} from \"./resolvedUrl.js\";\nexport {\n\tIdentityType,\n\tInstrumentedStorageTokenFetcher,\n\tInstrumentedTokenFetcher,\n\tisTokenFromCache,\n\tOdspResourceTokenFetchOptions,\n\tTokenFetcher,\n\tTokenFetchOptions,\n\tauthHeaderFromTokenResponse,\n\ttokenFromResponse,\n\tTokenResponse,\n} from \"./tokenFetch.js\";\nexport {\n\tIProvideSessionAwareDriverFactory,\n\tIRelaySessionAwareDriverFactory,\n\tISocketStorageDiscovery,\n} from \"./sessionProvider.js\";\n"]}
|
package/dist/legacy.d.ts
CHANGED
package/dist/odspCache.d.ts
CHANGED
|
@@ -17,11 +17,16 @@ export declare const maximumCacheDurationMs: FiveDaysMs;
|
|
|
17
17
|
* @internal
|
|
18
18
|
*/
|
|
19
19
|
export declare const snapshotKey = "snapshot";
|
|
20
|
+
/**
|
|
21
|
+
* Describes key for partial snapshot with loading GroupId in cache entry.
|
|
22
|
+
* @internal
|
|
23
|
+
*/
|
|
24
|
+
export declare const snapshotWithLoadingGroupIdKey = "snapshotWithLoadingGroupId";
|
|
20
25
|
/**
|
|
21
26
|
* @legacy
|
|
22
27
|
* @alpha
|
|
23
28
|
*/
|
|
24
|
-
export type CacheContentType = "snapshot" | "ops";
|
|
29
|
+
export type CacheContentType = "snapshot" | "ops" | "snapshotWithLoadingGroupId";
|
|
25
30
|
/**
|
|
26
31
|
* @legacy
|
|
27
32
|
* @alpha
|
package/dist/odspCache.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odspCache.d.ts","sourceRoot":"","sources":["../src/odspCache.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,KAAK,UAAU,EAAE,YAAY,EAAE,MAAM,6CAA6C,CAAC;AAE5F;;;;;;;GAOG;AACH,eAAO,MAAM,sBAAsB,EAAE,UAAwB,CAAC;AAE9D;;;GAGG;AACH,eAAO,MAAM,WAAW,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"odspCache.d.ts","sourceRoot":"","sources":["../src/odspCache.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,KAAK,UAAU,EAAE,YAAY,EAAE,MAAM,6CAA6C,CAAC;AAE5F;;;;;;;GAOG;AACH,eAAO,MAAM,sBAAsB,EAAE,UAAwB,CAAC;AAE9D;;;GAGG;AACH,eAAO,MAAM,WAAW,aAAa,CAAC;AAEtC;;;GAGG;AACH,eAAO,MAAM,6BAA6B,+BAA+B,CAAC;AAE1E;;;GAGG;AACH,MAAM,MAAM,gBAAgB,GAAG,UAAU,GAAG,KAAK,GAAG,4BAA4B,CAAC;AAOjF;;;GAGG;AACH,MAAM,WAAW,UAAU;IAC1B;;;OAGG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;;;;OAKG;IACH,WAAW,EAAE,YAAY,CAAC;CAC1B;AAED;;;;GAIG;AACH,MAAM,WAAW,MAAM;IACtB;;;;OAIG;IACH,IAAI,EAAE,gBAAgB,CAAC;IAEvB;;;;;;;OAOG;IACH,GAAG,EAAE,MAAM,CAAC;CACZ;AAED;;;;GAIG;AACH,MAAM,WAAW,WAAY,SAAQ,MAAM;IAC1C;;OAEG;IACH,IAAI,EAAE,UAAU,CAAC;CACjB;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,eAAe;IAC/B;;;;OAIG;IACH,GAAG,CAAC,KAAK,EAAE,WAAW,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;IAEtC;;;;;OAKG;IACH,GAAG,CAAC,KAAK,EAAE,WAAW,EAAE,KAAK,EAAE,GAAG,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEnD;;;OAGG;IACH,aAAa,CAAC,IAAI,EAAE,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC/C;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,WAAW,GAAG,MAAM,CAE9D"}
|
package/dist/odspCache.js
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Licensed under the MIT License.
|
|
5
5
|
*/
|
|
6
6
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
-
exports.getKeyForCacheEntry = exports.snapshotKey = exports.maximumCacheDurationMs = void 0;
|
|
7
|
+
exports.getKeyForCacheEntry = exports.snapshotWithLoadingGroupIdKey = exports.snapshotKey = exports.maximumCacheDurationMs = void 0;
|
|
8
8
|
/**
|
|
9
9
|
* Must be less than IDocumentStorageServicePolicies.maximumCacheDurationMs policy of 5 days.
|
|
10
10
|
* That policy is the outward expression and this value is the implementation - using a larger value
|
|
@@ -19,6 +19,11 @@ exports.maximumCacheDurationMs = 432000000; // 5 days in ms
|
|
|
19
19
|
* @internal
|
|
20
20
|
*/
|
|
21
21
|
exports.snapshotKey = "snapshot";
|
|
22
|
+
/**
|
|
23
|
+
* Describes key for partial snapshot with loading GroupId in cache entry.
|
|
24
|
+
* @internal
|
|
25
|
+
*/
|
|
26
|
+
exports.snapshotWithLoadingGroupIdKey = "snapshotWithLoadingGroupId";
|
|
22
27
|
/**
|
|
23
28
|
* Api to generate a cache key from cache entry.
|
|
24
29
|
* @param entry - cache entry from which a cache key is generated
|
package/dist/odspCache.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odspCache.js","sourceRoot":"","sources":["../src/odspCache.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH;;;;;;;GAOG;AACU,QAAA,sBAAsB,GAAe,SAAW,CAAC,CAAC,eAAe;AAE9E;;;GAGG;AACU,QAAA,WAAW,GAAG,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"odspCache.js","sourceRoot":"","sources":["../src/odspCache.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAIH;;;;;;;GAOG;AACU,QAAA,sBAAsB,GAAe,SAAW,CAAC,CAAC,eAAe;AAE9E;;;GAGG;AACU,QAAA,WAAW,GAAG,UAAU,CAAC;AAEtC;;;GAGG;AACU,QAAA,6BAA6B,GAAG,4BAA4B,CAAC;AAoG1E;;;;;GAKG;AACH,SAAgB,mBAAmB,CAAC,KAAkB;IACrD,OAAO,GAAG,KAAK,CAAC,IAAI,CAAC,KAAK,IAAI,KAAK,CAAC,IAAI,IAAI,KAAK,CAAC,GAAG,EAAE,CAAC;AACzD,CAAC;AAFD,kDAEC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { type FiveDaysMs, IResolvedUrl } from \"@fluidframework/driver-definitions/internal\";\n\n/**\n * Must be less than IDocumentStorageServicePolicies.maximumCacheDurationMs policy of 5 days.\n * That policy is the outward expression and this value is the implementation - using a larger value\n * would violate that statement of the driver's behavior.\n * Other parts of the system (such as Garbage Collection) depend on that policy being properly implemented.\n *\n * @internal\n */\nexport const maximumCacheDurationMs: FiveDaysMs = 432_000_000; // 5 days in ms\n\n/**\n * Describes what kind of content is stored in cache entry.\n * @internal\n */\nexport const snapshotKey = \"snapshot\";\n\n/**\n * Describes key for partial snapshot with loading GroupId in cache entry.\n * @internal\n */\nexport const snapshotWithLoadingGroupIdKey = \"snapshotWithLoadingGroupId\";\n\n/**\n * @legacy\n * @alpha\n */\nexport type CacheContentType = \"snapshot\" | \"ops\" | \"snapshotWithLoadingGroupId\";\n\n/*\n * File / container identifier.\n * There is overlapping information here - host can use all of it or parts\n * to implement storage / identify files.\n */\n/**\n * @legacy\n * @alpha\n */\nexport interface IFileEntry {\n\t/**\n\t * Unique and stable ID of the document.\n\t * Driver guarantees that docId is stable ID uniquely identifying document.\n\t */\n\tdocId: string;\n\t/**\n\t * Resolved URI is provided for additional versatility - host can use it to\n\t * identify file in storage, and (as example) delete all cached entries for\n\t * a file if user requests so.\n\t * This is IOdspResolvedUrl in case of ODSP driver.\n\t */\n\tresolvedUrl: IResolvedUrl;\n}\n\n/**\n * Cache entry. Identifies file that this entry belongs to, and type of content stored in it.\n * @legacy\n * @alpha\n */\nexport interface IEntry {\n\t/**\n\t * Identifies type of entry for a given file.\n\t * Each file can have multiple types of entries associated with it.\n\t * For example, it can be snapshot, blob, ops, etc.\n\t */\n\ttype: CacheContentType;\n\n\t/**\n\t * Identifies individual entry for a given file and type.\n\t * Each file can have multiple cache entries associated with it.\n\t * This property identifies a particular instance of entry.\n\t * For example, for blobs it will be unique ID of the blob in a file.\n\t * For batch of ops, it can be starting op sequence number.\n\t * For types that have only one entry (like snapshots), it will be empty string.\n\t */\n\tkey: string;\n}\n\n/**\n * Cache entry. Identifies file that this entry belongs to, and type of content stored in it.\n * @legacy\n * @alpha\n */\nexport interface ICacheEntry extends IEntry {\n\t/**\n\t * Identifies file in storage this cached entry is for\n\t */\n\tfile: IFileEntry;\n}\n\n/**\n * Persistent cache. This interface can be implemented by the host to provide durable caching\n * across sessions. If not provided at driver factory construction, factory will use in-memory\n * cache implementation that does not survive across sessions. Snapshot entires stored in the\n * IPersistedCache will be considered stale and removed after 2 days. Read the README for more\n * information.\n * @legacy\n * @alpha\n */\nexport interface IPersistedCache {\n\t/**\n\t * Get the cache value of the key\n\t * @param entry - cache entry, identifies file and particular key for this file.\n\t * @returns Cached value. undefined if nothing is cached.\n\t */\n\tget(entry: ICacheEntry): Promise<any>;\n\n\t/**\n\t * Put the value into cache.\n\t * Important - only serializable content is allowed since this cache may be persisted between sessions\n\t * @param entry - cache entry.\n\t * @param value - JSON-serializable content.\n\t */\n\tput(entry: ICacheEntry, value: any): Promise<void>;\n\n\t/**\n\t * Removes the entries from the cache for given parametres.\n\t * @param file - file entry to be deleted.\n\t */\n\tremoveEntries(file: IFileEntry): Promise<void>;\n}\n\n/**\n * Api to generate a cache key from cache entry.\n * @param entry - cache entry from which a cache key is generated\n * @returns The key for cache.\n * @internal\n */\nexport function getKeyForCacheEntry(entry: ICacheEntry): string {\n\treturn `${entry.file.docId}_${entry.type}_${entry.key}`;\n}\n"]}
|
package/dist/public.d.ts
CHANGED
package/dist/tokenFetch.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ export interface TokenResponse {
|
|
|
12
12
|
token: string;
|
|
13
13
|
/**
|
|
14
14
|
* Authorization header value will be used verbatim when making network call that requires the token.
|
|
15
|
-
* If not
|
|
15
|
+
* If not provided, the token value will be assumed to be a Bearer token and will be used to generate the
|
|
16
16
|
* Authorization header value in the following format: `Bearer ${token}`.
|
|
17
17
|
*/
|
|
18
18
|
readonly authorizationHeader?: string;
|
package/dist/tokenFetch.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokenFetch.js","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAsFH;;;;;GAKG;AACI,MAAM,iBAAiB,GAAG,CAChC,aAAwD,EACxC,EAAE,CAClB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,aAAa;IACf,CAAC,CAAC,aAAa,KAAK,SAAS;QAC5B,CAAC,CAAC,IAAI;QACN,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC;AAPZ,QAAA,iBAAiB,qBAOL;AAEzB;;;;;GAKG;AACI,MAAM,2BAA2B,GAAG,CAC1C,aAAwD,EACxC,EAAE;IAClB,IAAI,OAAO,aAAa,KAAK,QAAQ,IAAI,aAAa,EAAE,mBAAmB,KAAK,SAAS,EAAE,CAAC;QAC3F,OAAO,aAAa,CAAC,mBAAmB,CAAC;IAC1C,CAAC;IACD,MAAM,KAAK,GAAG,IAAA,yBAAiB,EAAC,aAAa,CAAC,CAAC;IAC/C,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;QACpB,OAAO,UAAU,KAAK,EAAE,CAAC;IAC1B,CAAC;IACD,OAAO,IAAI,CAAC;AACb,CAAC,CAAC;AAXW,QAAA,2BAA2B,+BAWtC;AAEF;;;;;;GAMG;AACI,MAAM,gBAAgB,GAAG,CAC/B,aAA4C,EACtB,EAAE,CACxB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,SAAS;IACX,CAAC,CAAC,aAAa,CAAC,SAAS,CAAC;AALf,QAAA,gBAAgB,oBAKD","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * Represents token response\n * @legacy\n * @alpha\n */\nexport interface TokenResponse {\n\t/** Token value */\n\ttoken: string;\n\n\t/**\n\t * Authorization header value will be used verbatim when making network call that requires the token.\n\t * If not
|
|
1
|
+
{"version":3,"file":"tokenFetch.js","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAsFH;;;;;GAKG;AACI,MAAM,iBAAiB,GAAG,CAChC,aAAwD,EACxC,EAAE,CAClB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,aAAa;IACf,CAAC,CAAC,aAAa,KAAK,SAAS;QAC5B,CAAC,CAAC,IAAI;QACN,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC;AAPZ,QAAA,iBAAiB,qBAOL;AAEzB;;;;;GAKG;AACI,MAAM,2BAA2B,GAAG,CAC1C,aAAwD,EACxC,EAAE;IAClB,IAAI,OAAO,aAAa,KAAK,QAAQ,IAAI,aAAa,EAAE,mBAAmB,KAAK,SAAS,EAAE,CAAC;QAC3F,OAAO,aAAa,CAAC,mBAAmB,CAAC;IAC1C,CAAC;IACD,MAAM,KAAK,GAAG,IAAA,yBAAiB,EAAC,aAAa,CAAC,CAAC;IAC/C,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;QACpB,OAAO,UAAU,KAAK,EAAE,CAAC;IAC1B,CAAC;IACD,OAAO,IAAI,CAAC;AACb,CAAC,CAAC;AAXW,QAAA,2BAA2B,+BAWtC;AAEF;;;;;;GAMG;AACI,MAAM,gBAAgB,GAAG,CAC/B,aAA4C,EACtB,EAAE,CACxB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,SAAS;IACX,CAAC,CAAC,aAAa,CAAC,SAAS,CAAC;AALf,QAAA,gBAAgB,oBAKD","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * Represents token response\n * @legacy\n * @alpha\n */\nexport interface TokenResponse {\n\t/** Token value */\n\ttoken: string;\n\n\t/**\n\t * Authorization header value will be used verbatim when making network call that requires the token.\n\t * If not provided, the token value will be assumed to be a Bearer token and will be used to generate the\n\t * Authorization header value in the following format: `Bearer ${token}`.\n\t */\n\treadonly authorizationHeader?: string;\n\n\t/**\n\t * Whether or not the token was obtained from local cache.\n\t * @remarks `undefined` indicates that it could not be determined whether or not the token was obtained this way.\n\t */\n\tfromCache?: boolean;\n}\n\n/**\n * Represents access token fetch options\n * @legacy\n * @alpha\n */\nexport interface TokenFetchOptions {\n\t/**\n\t * Value indicating whether fresh token has to be returned.\n\t * If false then it is okay to return cached unexpired token if available.\n\t */\n\trefresh: boolean;\n\n\t/**\n\t * Claims that have to be passed with token fetch request.\n\t * These can be used to specify additional information that must be passed to token authority.\n\t */\n\tclaims?: string;\n\n\t/**\n\t * Tenant id of authority that must be handling token fetch.\n\t * If it is not specified then it is up to token fetching logic to determine which tenant authority\n\t * to use to issue access token.\n\t */\n\ttenantId?: string;\n\n\t/**\n\t * Request that will be made using the fetched token.\n\t * - url: full request url, including query params\n\t * - method: method type\n\t * Request info may be encoded into the returned token that the receiver can use to validate that caller is allowed to make specific call.\n\t */\n\treadonly request?: { url: string; method: \"GET\" | \"POST\" | \"PATCH\" | \"DELETE\" | \"PUT\" };\n}\n\n/**\n * Represents access token fetch options for ODSP resource\n * @legacy\n * @alpha\n */\nexport interface OdspResourceTokenFetchOptions extends TokenFetchOptions {\n\t/** Site url representing ODSP resource location */\n\tsiteUrl: string;\n\n\t/** ODSP drive id where resource resides. Optional, used only when fetching token to access ODSP file */\n\tdriveId?: string;\n\n\t/** ODSP item id representing resource. Optional, used only when fetching token to access ODSP file */\n\titemId?: string;\n}\n\n/**\n * Method signature for callback method used to fetch access token\n * @param options - token fetch options\n * @returns If successful, TokenResponse object representing token value along with flag indicating\n * whether token came from cache. Legacy implementation may return a string for token value;\n * in this case it should be assumes that fromCache signal is undefined. Null is returned in case of failure.\n * @legacy\n * @alpha\n */\nexport type TokenFetcher<T> = (options: T) => Promise<string | TokenResponse | null>;\n\n/**\n * Helper method which transforms return value for TokenFetcher method to token string\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Token value\n * @internal\n */\nexport const tokenFromResponse = (\n\ttokenResponse: string | TokenResponse | null | undefined,\n): string | null =>\n\ttokenResponse === null || typeof tokenResponse === \"string\"\n\t\t? tokenResponse\n\t\t: tokenResponse === undefined\n\t\t\t? null\n\t\t\t: tokenResponse.token;\n\n/**\n * Helper method which transforms return value for TokenFetcher method to Authorization header value\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Authorization header value\n * @internal\n */\nexport const authHeaderFromTokenResponse = (\n\ttokenResponse: string | TokenResponse | null | undefined,\n): string | null => {\n\tif (typeof tokenResponse === \"object\" && tokenResponse?.authorizationHeader !== undefined) {\n\t\treturn tokenResponse.authorizationHeader;\n\t}\n\tconst token = tokenFromResponse(tokenResponse);\n\tif (token !== null) {\n\t\treturn `Bearer ${token}`;\n\t}\n\treturn null;\n};\n\n/**\n * Helper method which returns flag indicating whether token response comes from local cache\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Value indicating whether response came from cache.\n * Undefined is returned when we could not determine the source of token.\n * @internal\n */\nexport const isTokenFromCache = (\n\ttokenResponse: string | TokenResponse | null,\n): boolean | undefined =>\n\ttokenResponse === null || typeof tokenResponse === \"string\"\n\t\t? undefined\n\t\t: tokenResponse.fromCache;\n\n/**\n * Identity types supported by ODSP driver.\n * `Consumer` represents user authenticated with Microsoft Account (MSA).\n * `Enterprise` represents user authenticated with M365 tenant account.\n * @legacy\n * @alpha\n */\nexport type IdentityType = \"Consumer\" | \"Enterprise\";\n\n/**\n * @returns Authorization header value\n * @internal\n */\nexport type InstrumentedStorageTokenFetcher = (\n\toptions: TokenFetchOptions,\n\tname: string,\n\talwaysRecordTokenFetchTelemetry?: boolean,\n) => Promise<string>;\n\n/**\n * @internal\n */\nexport type InstrumentedTokenFetcher = (\n\toptions: TokenFetchOptions,\n\tname: string,\n\talwaysRecordTokenFetchTelemetry?: boolean,\n) => Promise<string | null>;\n"]}
|
package/internal.d.ts
CHANGED
package/legacy.d.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
/*
|
|
7
7
|
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
-
* Generated by "flub generate entrypoints" in @
|
|
8
|
+
* Generated by "flub generate entrypoints" in @fluid-tools/build-cli.
|
|
9
9
|
*/
|
|
10
10
|
|
|
11
11
|
export * from "./lib/legacy.js";
|
package/lib/factory.d.ts
CHANGED
|
@@ -55,13 +55,12 @@ export interface IOpsCachingPolicy {
|
|
|
55
55
|
*/
|
|
56
56
|
export interface ICollabSessionOptions {
|
|
57
57
|
/**
|
|
58
|
-
* @deprecated starting in 2.0-RC3. No longer needed.
|
|
59
58
|
* Value indicating the display name for session that admits unauthenticated user.
|
|
60
59
|
* This name will be used in attribution associated with edits made by such user.
|
|
60
|
+
* @deprecated starting in 2.0-RC3. No longer needed.
|
|
61
61
|
*/
|
|
62
62
|
unauthenticatedUserDisplayName?: string;
|
|
63
63
|
/**
|
|
64
|
-
* @deprecated Due to security reasons we will be passing the token via Authorization header only.
|
|
65
64
|
* Value indicating session preference to always pass access token via Authorization header.
|
|
66
65
|
* Default behavior is to pass access token via query parameter unless overall href string
|
|
67
66
|
* length exceeds 2048 characters. Using query param is performance optimization which results
|
|
@@ -69,6 +68,7 @@ export interface ICollabSessionOptions {
|
|
|
69
68
|
* validate CORS. However, not all ODSP implementations understand this optimization.
|
|
70
69
|
* For instance, auth layer on Converged stack will fail request with access token passed via
|
|
71
70
|
* query param.
|
|
71
|
+
* @deprecated Due to security reasons we will be passing the token via Authorization header only.
|
|
72
72
|
*/
|
|
73
73
|
forceAccessTokenViaAuthorizationHeader?: boolean;
|
|
74
74
|
}
|
package/lib/factory.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"factory.js","sourceRoot":"","sources":["../src/factory.ts"],"names":[],"mappings":"AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * @legacy\n * @alpha\n */\nexport interface ISnapshotOptions {\n\tblobs?: number;\n\tdeltas?: number;\n\tchannels?: number;\n\n\t/**\n\t * Maximum Data size (in bytes)\n\t *\n\t * @remarks\n\t * If specified, SPO will fail snapshot request with 413 error (see {@link @fluidframework/odsp-driver-definitions#(OdspErrorTypes:variable).snapshotTooBig})\n\t * if snapshot is bigger in size than specified limit.\n\t */\n\tmds?: number;\n\n\t/*\n\t * Maximum time limit to fetch snapshot (in seconds)\n\t * If specified, client will timeout the fetch request if it exceeds the time limit and\n\t * will try to fetch the snapshot without blobs.\n\t */\n\ttimeout?: number;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface IOpsCachingPolicy {\n\t/**\n\t * Batch size. Controls how many ops are grouped together as single cache entry\n\t * The bigger the number, the more efficient it is (less reads & writes)\n\t * At the same time, big number means we wait for so many ops to accumulate, which\n\t * increases chances and number of trailing ops that would not be flushed to cache\n\t * when user closes tab\n\t * Use any number below 1 to disable caching\n\t * Default: 100\n\t */\n\tbatchSize?: number;\n\n\t/**\n\t * To reduce the problem of losing trailing ops when using big batch sizes, host\n\t * could specify how often driver should flush ops it has not flushed yet.\n\t * -1 means do not use timer.\n\t * Measured in ms.\n\t * Default: 5000\n\t */\n\ttimerGranularity?: number;\n\n\t/**\n\t * Total number of ops to cache. When we reach that number, ops caching stops\n\t * Default: 5000\n\t */\n\ttotalOpsToCache?: number;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface ICollabSessionOptions {\n\t/**\n\t *
|
|
1
|
+
{"version":3,"file":"factory.js","sourceRoot":"","sources":["../src/factory.ts"],"names":[],"mappings":"AAAA;;;GAGG","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * @legacy\n * @alpha\n */\nexport interface ISnapshotOptions {\n\tblobs?: number;\n\tdeltas?: number;\n\tchannels?: number;\n\n\t/**\n\t * Maximum Data size (in bytes)\n\t *\n\t * @remarks\n\t * If specified, SPO will fail snapshot request with 413 error (see {@link @fluidframework/odsp-driver-definitions#(OdspErrorTypes:variable).snapshotTooBig})\n\t * if snapshot is bigger in size than specified limit.\n\t */\n\tmds?: number;\n\n\t/*\n\t * Maximum time limit to fetch snapshot (in seconds)\n\t * If specified, client will timeout the fetch request if it exceeds the time limit and\n\t * will try to fetch the snapshot without blobs.\n\t */\n\ttimeout?: number;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface IOpsCachingPolicy {\n\t/**\n\t * Batch size. Controls how many ops are grouped together as single cache entry\n\t * The bigger the number, the more efficient it is (less reads & writes)\n\t * At the same time, big number means we wait for so many ops to accumulate, which\n\t * increases chances and number of trailing ops that would not be flushed to cache\n\t * when user closes tab\n\t * Use any number below 1 to disable caching\n\t * Default: 100\n\t */\n\tbatchSize?: number;\n\n\t/**\n\t * To reduce the problem of losing trailing ops when using big batch sizes, host\n\t * could specify how often driver should flush ops it has not flushed yet.\n\t * -1 means do not use timer.\n\t * Measured in ms.\n\t * Default: 5000\n\t */\n\ttimerGranularity?: number;\n\n\t/**\n\t * Total number of ops to cache. When we reach that number, ops caching stops\n\t * Default: 5000\n\t */\n\ttotalOpsToCache?: number;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface ICollabSessionOptions {\n\t/**\n\t * Value indicating the display name for session that admits unauthenticated user.\n\t * This name will be used in attribution associated with edits made by such user.\n\t * @deprecated starting in 2.0-RC3. No longer needed.\n\t */\n\tunauthenticatedUserDisplayName?: string;\n\t/**\n\t * Value indicating session preference to always pass access token via Authorization header.\n\t * Default behavior is to pass access token via query parameter unless overall href string\n\t * length exceeds 2048 characters. Using query param is performance optimization which results\n\t * in ODSP XHR request being treated as 'simple' request which do not require OPTIONS call to\n\t * validate CORS. However, not all ODSP implementations understand this optimization.\n\t * For instance, auth layer on Converged stack will fail request with access token passed via\n\t * query param.\n\t * @deprecated Due to security reasons we will be passing the token via Authorization header only.\n\t */\n\tforceAccessTokenViaAuthorizationHeader?: boolean;\n}\n\n/**\n * @legacy\n * @alpha\n */\nexport interface HostStoragePolicy {\n\tsnapshotOptions?: ISnapshotOptions;\n\n\t/**\n\t * If set to true, tells driver to concurrently fetch snapshot from storage (SPO) and cache\n\t * Container loads from whatever comes first in such case.\n\t * Snapshot fetched from storage is pushed to cache in either case.\n\t * If set to false, driver will first consult with cache. Only on cache miss (cache does not\n\t * return snapshot), driver will fetch snapshot from storage (and push it to cache), otherwise\n\t * it will load from cache and not reach out to storage.\n\t * Passing true results in faster loads and keeping cache more current, but it increases bandwidth consumption.\n\t */\n\tconcurrentSnapshotFetch?: boolean;\n\n\t// Options overwriting default ops fetching from storage.\n\topsBatchSize?: number;\n\tconcurrentOpsBatches?: number;\n\n\t/**\n\t * Policy controlling ops caching (leveraging IPersistedCache passed to driver factory)\n\t */\n\topsCaching?: IOpsCachingPolicy;\n\n\t/**\n\t * Policy controlling how collaboration session is established\n\t */\n\tsessionOptions?: ICollabSessionOptions;\n\n\t/**\n\t * @deprecated This field will be always set to true after removal.\n\t * True to have the sharing link redeem fallback in case the Trees Latest/Redeem 1RT call fails with redeem error.\n\t * During fallback it will first redeem the sharing link and then make the Trees latest call.\n\t */\n\tenableRedeemFallback?: boolean;\n\n\t/**\n\t * Policy controlling if we will cache initial summary when we create a document\n\t */\n\tcacheCreateNewSummary?: boolean;\n\n\t/**\n\t * @deprecated This will be replaced with feature gate snapshotFormatFetchType.\n\t * Policy controlling if we want to fetch binary format snapshot.\n\t */\n\tfetchBinarySnapshotFormat?: boolean;\n\n\t/**\n\t * If set to true, socket cache are per OdspDocumentService instead of shared across all instances\n\t */\n\tisolateSocketCache?: boolean;\n\n\t/**\n\t * @deprecated Switch to using the new feature gated by enableSingleRequestForShareLinkWithCreate\n\t * with 'createLinkScope' and 'createLinkRole' is requested to the odsp apis instead of 'createLinkType'.\n\t * It enables the creation of sharing link along with the creation of file by setting this value to true.\n\t * If the host provides a 'createLinkType' parameter in the request URL to the container.attach()\n\t * method, we will send the request to ODSP with the same (if the flag is enabled) so\n\t * that a share link can be created with the creation of file to save number for round trips made to ODSP.\n\t * (This flag works independently of enableSingleRequestForShareLinkWithCreate which is used for sharing link\n\t * requests where 'createLinkScope' is requested.)\n\t */\n\tenableShareLinkWithCreate?: boolean;\n\n\t/**\n\t * Enable creation of sharing link along with the creation of file by setting this value to true.\n\t * If the host provides a 'createLinkScope' parameter in the request URL to the container.attach()\n\t * method, we will send the request to ODSP with the same (if the flag is enabled) so\n\t * that a share link can be created with the creation of file to save number for round trips made to ODSP.\n\t * (This flag works independently of enableShareLinkWithCreate which was used for old sharing link requests\n\t * where 'createLinkType' was requested.)\n\t */\n\tenableSingleRequestForShareLinkWithCreate?: boolean;\n\n\t/**\n\t * True if host does not want the storage service to use the prefetch cache to get the snapshot. Undefined will be treated\n\t * as false. This is if the host wants to do some A/B testing.\n\t */\n\tavoidPrefetchSnapshotCache?: boolean;\n}\n"]}
|
package/lib/index.d.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
export { IOdspError, IOdspErrorAugmentations, OdspError, OdspErrorTypes } from "./errors.js";
|
|
6
6
|
export { HostStoragePolicy, ICollabSessionOptions, IOpsCachingPolicy, ISnapshotOptions, } from "./factory.js";
|
|
7
|
-
export { CacheContentType, maximumCacheDurationMs, getKeyForCacheEntry, ICacheEntry, IEntry, IFileEntry, IPersistedCache, snapshotKey, } from "./odspCache.js";
|
|
7
|
+
export { CacheContentType, maximumCacheDurationMs, getKeyForCacheEntry, ICacheEntry, IEntry, IFileEntry, IPersistedCache, snapshotKey, snapshotWithLoadingGroupIdKey, } from "./odspCache.js";
|
|
8
8
|
export { IOdspResolvedUrl, IOdspUrlParts, ISharingLink, ISharingLinkKind, ShareLinkInfoType, SharingLinkRole, SharingLinkScope, } from "./resolvedUrl.js";
|
|
9
9
|
export { IdentityType, InstrumentedStorageTokenFetcher, InstrumentedTokenFetcher, isTokenFromCache, OdspResourceTokenFetchOptions, TokenFetcher, TokenFetchOptions, authHeaderFromTokenResponse, tokenFromResponse, TokenResponse, } from "./tokenFetch.js";
|
|
10
10
|
export { IProvideSessionAwareDriverFactory, IRelaySessionAwareDriverFactory, ISocketStorageDiscovery, } from "./sessionProvider.js";
|
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,UAAU,EAAE,uBAAuB,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7F,OAAO,EACN,iBAAiB,EACjB,qBAAqB,EACrB,iBAAiB,EACjB,gBAAgB,GAChB,MAAM,cAAc,CAAC;AACtB,OAAO,EACN,gBAAgB,EAChB,sBAAsB,EACtB,mBAAmB,EACnB,WAAW,EACX,MAAM,EACN,UAAU,EACV,eAAe,EACf,WAAW,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,UAAU,EAAE,uBAAuB,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAC7F,OAAO,EACN,iBAAiB,EACjB,qBAAqB,EACrB,iBAAiB,EACjB,gBAAgB,GAChB,MAAM,cAAc,CAAC;AACtB,OAAO,EACN,gBAAgB,EAChB,sBAAsB,EACtB,mBAAmB,EACnB,WAAW,EACX,MAAM,EACN,UAAU,EACV,eAAe,EACf,WAAW,EACX,6BAA6B,GAC7B,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACN,gBAAgB,EAChB,aAAa,EACb,YAAY,EACZ,gBAAgB,EAChB,iBAAiB,EACjB,eAAe,EACf,gBAAgB,GAChB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EACN,YAAY,EACZ,+BAA+B,EAC/B,wBAAwB,EACxB,gBAAgB,EAChB,6BAA6B,EAC7B,YAAY,EACZ,iBAAiB,EACjB,2BAA2B,EAC3B,iBAAiB,EACjB,aAAa,GACb,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACN,iCAAiC,EACjC,+BAA+B,EAC/B,uBAAuB,GACvB,MAAM,sBAAsB,CAAC"}
|
package/lib/index.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* Licensed under the MIT License.
|
|
4
4
|
*/
|
|
5
5
|
export { OdspErrorTypes } from "./errors.js";
|
|
6
|
-
export { maximumCacheDurationMs, getKeyForCacheEntry, snapshotKey, } from "./odspCache.js";
|
|
6
|
+
export { maximumCacheDurationMs, getKeyForCacheEntry, snapshotKey, snapshotWithLoadingGroupIdKey, } from "./odspCache.js";
|
|
7
7
|
export { SharingLinkRole, SharingLinkScope, } from "./resolvedUrl.js";
|
|
8
8
|
export { isTokenFromCache, authHeaderFromTokenResponse, tokenFromResponse, } from "./tokenFetch.js";
|
|
9
9
|
//# sourceMappingURL=index.js.map
|
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAkD,cAAc,EAAE,MAAM,aAAa,CAAC;AAO7F,OAAO,EAEN,sBAAsB,EACtB,mBAAmB,EAKnB,WAAW,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAkD,cAAc,EAAE,MAAM,aAAa,CAAC;AAO7F,OAAO,EAEN,sBAAsB,EACtB,mBAAmB,EAKnB,WAAW,EACX,6BAA6B,GAC7B,MAAM,gBAAgB,CAAC;AACxB,OAAO,EAMN,eAAe,EACf,gBAAgB,GAChB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAIN,gBAAgB,EAIhB,2BAA2B,EAC3B,iBAAiB,GAEjB,MAAM,iBAAiB,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport { IOdspError, IOdspErrorAugmentations, OdspError, OdspErrorTypes } from \"./errors.js\";\nexport {\n\tHostStoragePolicy,\n\tICollabSessionOptions,\n\tIOpsCachingPolicy,\n\tISnapshotOptions,\n} from \"./factory.js\";\nexport {\n\tCacheContentType,\n\tmaximumCacheDurationMs,\n\tgetKeyForCacheEntry,\n\tICacheEntry,\n\tIEntry,\n\tIFileEntry,\n\tIPersistedCache,\n\tsnapshotKey,\n\tsnapshotWithLoadingGroupIdKey,\n} from \"./odspCache.js\";\nexport {\n\tIOdspResolvedUrl,\n\tIOdspUrlParts,\n\tISharingLink,\n\tISharingLinkKind,\n\tShareLinkInfoType,\n\tSharingLinkRole,\n\tSharingLinkScope,\n} from \"./resolvedUrl.js\";\nexport {\n\tIdentityType,\n\tInstrumentedStorageTokenFetcher,\n\tInstrumentedTokenFetcher,\n\tisTokenFromCache,\n\tOdspResourceTokenFetchOptions,\n\tTokenFetcher,\n\tTokenFetchOptions,\n\tauthHeaderFromTokenResponse,\n\ttokenFromResponse,\n\tTokenResponse,\n} from \"./tokenFetch.js\";\nexport {\n\tIProvideSessionAwareDriverFactory,\n\tIRelaySessionAwareDriverFactory,\n\tISocketStorageDiscovery,\n} from \"./sessionProvider.js\";\n"]}
|
package/lib/legacy.d.ts
CHANGED
package/lib/odspCache.d.ts
CHANGED
|
@@ -17,11 +17,16 @@ export declare const maximumCacheDurationMs: FiveDaysMs;
|
|
|
17
17
|
* @internal
|
|
18
18
|
*/
|
|
19
19
|
export declare const snapshotKey = "snapshot";
|
|
20
|
+
/**
|
|
21
|
+
* Describes key for partial snapshot with loading GroupId in cache entry.
|
|
22
|
+
* @internal
|
|
23
|
+
*/
|
|
24
|
+
export declare const snapshotWithLoadingGroupIdKey = "snapshotWithLoadingGroupId";
|
|
20
25
|
/**
|
|
21
26
|
* @legacy
|
|
22
27
|
* @alpha
|
|
23
28
|
*/
|
|
24
|
-
export type CacheContentType = "snapshot" | "ops";
|
|
29
|
+
export type CacheContentType = "snapshot" | "ops" | "snapshotWithLoadingGroupId";
|
|
25
30
|
/**
|
|
26
31
|
* @legacy
|
|
27
32
|
* @alpha
|
package/lib/odspCache.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odspCache.d.ts","sourceRoot":"","sources":["../src/odspCache.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,KAAK,UAAU,EAAE,YAAY,EAAE,MAAM,6CAA6C,CAAC;AAE5F;;;;;;;GAOG;AACH,eAAO,MAAM,sBAAsB,EAAE,UAAwB,CAAC;AAE9D;;;GAGG;AACH,eAAO,MAAM,WAAW,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"odspCache.d.ts","sourceRoot":"","sources":["../src/odspCache.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,EAAE,KAAK,UAAU,EAAE,YAAY,EAAE,MAAM,6CAA6C,CAAC;AAE5F;;;;;;;GAOG;AACH,eAAO,MAAM,sBAAsB,EAAE,UAAwB,CAAC;AAE9D;;;GAGG;AACH,eAAO,MAAM,WAAW,aAAa,CAAC;AAEtC;;;GAGG;AACH,eAAO,MAAM,6BAA6B,+BAA+B,CAAC;AAE1E;;;GAGG;AACH,MAAM,MAAM,gBAAgB,GAAG,UAAU,GAAG,KAAK,GAAG,4BAA4B,CAAC;AAOjF;;;GAGG;AACH,MAAM,WAAW,UAAU;IAC1B;;;OAGG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;;;;OAKG;IACH,WAAW,EAAE,YAAY,CAAC;CAC1B;AAED;;;;GAIG;AACH,MAAM,WAAW,MAAM;IACtB;;;;OAIG;IACH,IAAI,EAAE,gBAAgB,CAAC;IAEvB;;;;;;;OAOG;IACH,GAAG,EAAE,MAAM,CAAC;CACZ;AAED;;;;GAIG;AACH,MAAM,WAAW,WAAY,SAAQ,MAAM;IAC1C;;OAEG;IACH,IAAI,EAAE,UAAU,CAAC;CACjB;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,eAAe;IAC/B;;;;OAIG;IACH,GAAG,CAAC,KAAK,EAAE,WAAW,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;IAEtC;;;;;OAKG;IACH,GAAG,CAAC,KAAK,EAAE,WAAW,EAAE,KAAK,EAAE,GAAG,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAEnD;;;OAGG;IACH,aAAa,CAAC,IAAI,EAAE,UAAU,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;CAC/C;AAED;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,WAAW,GAAG,MAAM,CAE9D"}
|
package/lib/odspCache.js
CHANGED
|
@@ -16,6 +16,11 @@ export const maximumCacheDurationMs = 432000000; // 5 days in ms
|
|
|
16
16
|
* @internal
|
|
17
17
|
*/
|
|
18
18
|
export const snapshotKey = "snapshot";
|
|
19
|
+
/**
|
|
20
|
+
* Describes key for partial snapshot with loading GroupId in cache entry.
|
|
21
|
+
* @internal
|
|
22
|
+
*/
|
|
23
|
+
export const snapshotWithLoadingGroupIdKey = "snapshotWithLoadingGroupId";
|
|
19
24
|
/**
|
|
20
25
|
* Api to generate a cache key from cache entry.
|
|
21
26
|
* @param entry - cache entry from which a cache key is generated
|
package/lib/odspCache.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"odspCache.js","sourceRoot":"","sources":["../src/odspCache.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,sBAAsB,GAAe,SAAW,CAAC,CAAC,eAAe;AAE9E;;;GAGG;AACH,MAAM,CAAC,MAAM,WAAW,GAAG,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"odspCache.js","sourceRoot":"","sources":["../src/odspCache.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,sBAAsB,GAAe,SAAW,CAAC,CAAC,eAAe;AAE9E;;;GAGG;AACH,MAAM,CAAC,MAAM,WAAW,GAAG,UAAU,CAAC;AAEtC;;;GAGG;AACH,MAAM,CAAC,MAAM,6BAA6B,GAAG,4BAA4B,CAAC;AAoG1E;;;;;GAKG;AACH,MAAM,UAAU,mBAAmB,CAAC,KAAkB;IACrD,OAAO,GAAG,KAAK,CAAC,IAAI,CAAC,KAAK,IAAI,KAAK,CAAC,IAAI,IAAI,KAAK,CAAC,GAAG,EAAE,CAAC;AACzD,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { type FiveDaysMs, IResolvedUrl } from \"@fluidframework/driver-definitions/internal\";\n\n/**\n * Must be less than IDocumentStorageServicePolicies.maximumCacheDurationMs policy of 5 days.\n * That policy is the outward expression and this value is the implementation - using a larger value\n * would violate that statement of the driver's behavior.\n * Other parts of the system (such as Garbage Collection) depend on that policy being properly implemented.\n *\n * @internal\n */\nexport const maximumCacheDurationMs: FiveDaysMs = 432_000_000; // 5 days in ms\n\n/**\n * Describes what kind of content is stored in cache entry.\n * @internal\n */\nexport const snapshotKey = \"snapshot\";\n\n/**\n * Describes key for partial snapshot with loading GroupId in cache entry.\n * @internal\n */\nexport const snapshotWithLoadingGroupIdKey = \"snapshotWithLoadingGroupId\";\n\n/**\n * @legacy\n * @alpha\n */\nexport type CacheContentType = \"snapshot\" | \"ops\" | \"snapshotWithLoadingGroupId\";\n\n/*\n * File / container identifier.\n * There is overlapping information here - host can use all of it or parts\n * to implement storage / identify files.\n */\n/**\n * @legacy\n * @alpha\n */\nexport interface IFileEntry {\n\t/**\n\t * Unique and stable ID of the document.\n\t * Driver guarantees that docId is stable ID uniquely identifying document.\n\t */\n\tdocId: string;\n\t/**\n\t * Resolved URI is provided for additional versatility - host can use it to\n\t * identify file in storage, and (as example) delete all cached entries for\n\t * a file if user requests so.\n\t * This is IOdspResolvedUrl in case of ODSP driver.\n\t */\n\tresolvedUrl: IResolvedUrl;\n}\n\n/**\n * Cache entry. Identifies file that this entry belongs to, and type of content stored in it.\n * @legacy\n * @alpha\n */\nexport interface IEntry {\n\t/**\n\t * Identifies type of entry for a given file.\n\t * Each file can have multiple types of entries associated with it.\n\t * For example, it can be snapshot, blob, ops, etc.\n\t */\n\ttype: CacheContentType;\n\n\t/**\n\t * Identifies individual entry for a given file and type.\n\t * Each file can have multiple cache entries associated with it.\n\t * This property identifies a particular instance of entry.\n\t * For example, for blobs it will be unique ID of the blob in a file.\n\t * For batch of ops, it can be starting op sequence number.\n\t * For types that have only one entry (like snapshots), it will be empty string.\n\t */\n\tkey: string;\n}\n\n/**\n * Cache entry. Identifies file that this entry belongs to, and type of content stored in it.\n * @legacy\n * @alpha\n */\nexport interface ICacheEntry extends IEntry {\n\t/**\n\t * Identifies file in storage this cached entry is for\n\t */\n\tfile: IFileEntry;\n}\n\n/**\n * Persistent cache. This interface can be implemented by the host to provide durable caching\n * across sessions. If not provided at driver factory construction, factory will use in-memory\n * cache implementation that does not survive across sessions. Snapshot entires stored in the\n * IPersistedCache will be considered stale and removed after 2 days. Read the README for more\n * information.\n * @legacy\n * @alpha\n */\nexport interface IPersistedCache {\n\t/**\n\t * Get the cache value of the key\n\t * @param entry - cache entry, identifies file and particular key for this file.\n\t * @returns Cached value. undefined if nothing is cached.\n\t */\n\tget(entry: ICacheEntry): Promise<any>;\n\n\t/**\n\t * Put the value into cache.\n\t * Important - only serializable content is allowed since this cache may be persisted between sessions\n\t * @param entry - cache entry.\n\t * @param value - JSON-serializable content.\n\t */\n\tput(entry: ICacheEntry, value: any): Promise<void>;\n\n\t/**\n\t * Removes the entries from the cache for given parametres.\n\t * @param file - file entry to be deleted.\n\t */\n\tremoveEntries(file: IFileEntry): Promise<void>;\n}\n\n/**\n * Api to generate a cache key from cache entry.\n * @param entry - cache entry from which a cache key is generated\n * @returns The key for cache.\n * @internal\n */\nexport function getKeyForCacheEntry(entry: ICacheEntry): string {\n\treturn `${entry.file.docId}_${entry.type}_${entry.key}`;\n}\n"]}
|
package/lib/public.d.ts
CHANGED
package/lib/tokenFetch.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ export interface TokenResponse {
|
|
|
12
12
|
token: string;
|
|
13
13
|
/**
|
|
14
14
|
* Authorization header value will be used verbatim when making network call that requires the token.
|
|
15
|
-
* If not
|
|
15
|
+
* If not provided, the token value will be assumed to be a Bearer token and will be used to generate the
|
|
16
16
|
* Authorization header value in the following format: `Bearer ${token}`.
|
|
17
17
|
*/
|
|
18
18
|
readonly authorizationHeader?: string;
|
package/lib/tokenFetch.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokenFetch.js","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAsFH;;;;;GAKG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAChC,aAAwD,EACxC,EAAE,CAClB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,aAAa;IACf,CAAC,CAAC,aAAa,KAAK,SAAS;QAC5B,CAAC,CAAC,IAAI;QACN,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC;AAEzB;;;;;GAKG;AACH,MAAM,CAAC,MAAM,2BAA2B,GAAG,CAC1C,aAAwD,EACxC,EAAE;IAClB,IAAI,OAAO,aAAa,KAAK,QAAQ,IAAI,aAAa,EAAE,mBAAmB,KAAK,SAAS,EAAE,CAAC;QAC3F,OAAO,aAAa,CAAC,mBAAmB,CAAC;IAC1C,CAAC;IACD,MAAM,KAAK,GAAG,iBAAiB,CAAC,aAAa,CAAC,CAAC;IAC/C,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;QACpB,OAAO,UAAU,KAAK,EAAE,CAAC;IAC1B,CAAC;IACD,OAAO,IAAI,CAAC;AACb,CAAC,CAAC;AAEF;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAC/B,aAA4C,EACtB,EAAE,CACxB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,SAAS;IACX,CAAC,CAAC,aAAa,CAAC,SAAS,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * Represents token response\n * @legacy\n * @alpha\n */\nexport interface TokenResponse {\n\t/** Token value */\n\ttoken: string;\n\n\t/**\n\t * Authorization header value will be used verbatim when making network call that requires the token.\n\t * If not
|
|
1
|
+
{"version":3,"file":"tokenFetch.js","sourceRoot":"","sources":["../src/tokenFetch.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAsFH;;;;;GAKG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAChC,aAAwD,EACxC,EAAE,CAClB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,aAAa;IACf,CAAC,CAAC,aAAa,KAAK,SAAS;QAC5B,CAAC,CAAC,IAAI;QACN,CAAC,CAAC,aAAa,CAAC,KAAK,CAAC;AAEzB;;;;;GAKG;AACH,MAAM,CAAC,MAAM,2BAA2B,GAAG,CAC1C,aAAwD,EACxC,EAAE;IAClB,IAAI,OAAO,aAAa,KAAK,QAAQ,IAAI,aAAa,EAAE,mBAAmB,KAAK,SAAS,EAAE,CAAC;QAC3F,OAAO,aAAa,CAAC,mBAAmB,CAAC;IAC1C,CAAC;IACD,MAAM,KAAK,GAAG,iBAAiB,CAAC,aAAa,CAAC,CAAC;IAC/C,IAAI,KAAK,KAAK,IAAI,EAAE,CAAC;QACpB,OAAO,UAAU,KAAK,EAAE,CAAC;IAC1B,CAAC;IACD,OAAO,IAAI,CAAC;AACb,CAAC,CAAC;AAEF;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAC/B,aAA4C,EACtB,EAAE,CACxB,aAAa,KAAK,IAAI,IAAI,OAAO,aAAa,KAAK,QAAQ;IAC1D,CAAC,CAAC,SAAS;IACX,CAAC,CAAC,aAAa,CAAC,SAAS,CAAC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\n/**\n * Represents token response\n * @legacy\n * @alpha\n */\nexport interface TokenResponse {\n\t/** Token value */\n\ttoken: string;\n\n\t/**\n\t * Authorization header value will be used verbatim when making network call that requires the token.\n\t * If not provided, the token value will be assumed to be a Bearer token and will be used to generate the\n\t * Authorization header value in the following format: `Bearer ${token}`.\n\t */\n\treadonly authorizationHeader?: string;\n\n\t/**\n\t * Whether or not the token was obtained from local cache.\n\t * @remarks `undefined` indicates that it could not be determined whether or not the token was obtained this way.\n\t */\n\tfromCache?: boolean;\n}\n\n/**\n * Represents access token fetch options\n * @legacy\n * @alpha\n */\nexport interface TokenFetchOptions {\n\t/**\n\t * Value indicating whether fresh token has to be returned.\n\t * If false then it is okay to return cached unexpired token if available.\n\t */\n\trefresh: boolean;\n\n\t/**\n\t * Claims that have to be passed with token fetch request.\n\t * These can be used to specify additional information that must be passed to token authority.\n\t */\n\tclaims?: string;\n\n\t/**\n\t * Tenant id of authority that must be handling token fetch.\n\t * If it is not specified then it is up to token fetching logic to determine which tenant authority\n\t * to use to issue access token.\n\t */\n\ttenantId?: string;\n\n\t/**\n\t * Request that will be made using the fetched token.\n\t * - url: full request url, including query params\n\t * - method: method type\n\t * Request info may be encoded into the returned token that the receiver can use to validate that caller is allowed to make specific call.\n\t */\n\treadonly request?: { url: string; method: \"GET\" | \"POST\" | \"PATCH\" | \"DELETE\" | \"PUT\" };\n}\n\n/**\n * Represents access token fetch options for ODSP resource\n * @legacy\n * @alpha\n */\nexport interface OdspResourceTokenFetchOptions extends TokenFetchOptions {\n\t/** Site url representing ODSP resource location */\n\tsiteUrl: string;\n\n\t/** ODSP drive id where resource resides. Optional, used only when fetching token to access ODSP file */\n\tdriveId?: string;\n\n\t/** ODSP item id representing resource. Optional, used only when fetching token to access ODSP file */\n\titemId?: string;\n}\n\n/**\n * Method signature for callback method used to fetch access token\n * @param options - token fetch options\n * @returns If successful, TokenResponse object representing token value along with flag indicating\n * whether token came from cache. Legacy implementation may return a string for token value;\n * in this case it should be assumes that fromCache signal is undefined. Null is returned in case of failure.\n * @legacy\n * @alpha\n */\nexport type TokenFetcher<T> = (options: T) => Promise<string | TokenResponse | null>;\n\n/**\n * Helper method which transforms return value for TokenFetcher method to token string\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Token value\n * @internal\n */\nexport const tokenFromResponse = (\n\ttokenResponse: string | TokenResponse | null | undefined,\n): string | null =>\n\ttokenResponse === null || typeof tokenResponse === \"string\"\n\t\t? tokenResponse\n\t\t: tokenResponse === undefined\n\t\t\t? null\n\t\t\t: tokenResponse.token;\n\n/**\n * Helper method which transforms return value for TokenFetcher method to Authorization header value\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Authorization header value\n * @internal\n */\nexport const authHeaderFromTokenResponse = (\n\ttokenResponse: string | TokenResponse | null | undefined,\n): string | null => {\n\tif (typeof tokenResponse === \"object\" && tokenResponse?.authorizationHeader !== undefined) {\n\t\treturn tokenResponse.authorizationHeader;\n\t}\n\tconst token = tokenFromResponse(tokenResponse);\n\tif (token !== null) {\n\t\treturn `Bearer ${token}`;\n\t}\n\treturn null;\n};\n\n/**\n * Helper method which returns flag indicating whether token response comes from local cache\n * @param tokenResponse - return value for TokenFetcher method\n * @returns Value indicating whether response came from cache.\n * Undefined is returned when we could not determine the source of token.\n * @internal\n */\nexport const isTokenFromCache = (\n\ttokenResponse: string | TokenResponse | null,\n): boolean | undefined =>\n\ttokenResponse === null || typeof tokenResponse === \"string\"\n\t\t? undefined\n\t\t: tokenResponse.fromCache;\n\n/**\n * Identity types supported by ODSP driver.\n * `Consumer` represents user authenticated with Microsoft Account (MSA).\n * `Enterprise` represents user authenticated with M365 tenant account.\n * @legacy\n * @alpha\n */\nexport type IdentityType = \"Consumer\" | \"Enterprise\";\n\n/**\n * @returns Authorization header value\n * @internal\n */\nexport type InstrumentedStorageTokenFetcher = (\n\toptions: TokenFetchOptions,\n\tname: string,\n\talwaysRecordTokenFetchTelemetry?: boolean,\n) => Promise<string>;\n\n/**\n * @internal\n */\nexport type InstrumentedTokenFetcher = (\n\toptions: TokenFetchOptions,\n\tname: string,\n\talwaysRecordTokenFetchTelemetry?: boolean,\n) => Promise<string | null>;\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fluidframework/odsp-driver-definitions",
|
|
3
|
-
"version": "2.1.0-
|
|
3
|
+
"version": "2.1.0-281041",
|
|
4
4
|
"description": "Socket storage implementation for SPO and ODC",
|
|
5
5
|
"homepage": "https://fluidframework.com",
|
|
6
6
|
"repository": {
|
|
@@ -23,16 +23,6 @@
|
|
|
23
23
|
"default": "./dist/index.js"
|
|
24
24
|
}
|
|
25
25
|
},
|
|
26
|
-
"./beta": {
|
|
27
|
-
"import": {
|
|
28
|
-
"types": "./lib/beta.d.ts",
|
|
29
|
-
"default": "./lib/index.js"
|
|
30
|
-
},
|
|
31
|
-
"require": {
|
|
32
|
-
"types": "./dist/beta.d.ts",
|
|
33
|
-
"default": "./dist/index.js"
|
|
34
|
-
}
|
|
35
|
-
},
|
|
36
26
|
"./legacy": {
|
|
37
27
|
"import": {
|
|
38
28
|
"types": "./lib/legacy.d.ts",
|
|
@@ -57,16 +47,16 @@
|
|
|
57
47
|
"main": "lib/index.js",
|
|
58
48
|
"types": "lib/public.d.ts",
|
|
59
49
|
"dependencies": {
|
|
60
|
-
"@fluidframework/driver-definitions": "2.1.0-
|
|
50
|
+
"@fluidframework/driver-definitions": "2.1.0-281041"
|
|
61
51
|
},
|
|
62
52
|
"devDependencies": {
|
|
63
53
|
"@arethetypeswrong/cli": "^0.15.2",
|
|
64
|
-
"@biomejs/biome": "
|
|
65
|
-
"@fluid-tools/build-cli": "^0.
|
|
54
|
+
"@biomejs/biome": "~1.8.3",
|
|
55
|
+
"@fluid-tools/build-cli": "^0.40.0",
|
|
66
56
|
"@fluidframework/build-common": "^2.0.3",
|
|
67
|
-
"@fluidframework/build-tools": "^0.
|
|
57
|
+
"@fluidframework/build-tools": "^0.40.0",
|
|
68
58
|
"@fluidframework/eslint-config-fluid": "^5.3.0",
|
|
69
|
-
"@fluidframework/odsp-driver-definitions-previous": "npm:@fluidframework/odsp-driver-definitions@2.0.0
|
|
59
|
+
"@fluidframework/odsp-driver-definitions-previous": "npm:@fluidframework/odsp-driver-definitions@2.0.0",
|
|
70
60
|
"@microsoft/api-extractor": "^7.45.1",
|
|
71
61
|
"concurrently": "^8.2.1",
|
|
72
62
|
"copyfiles": "^2.4.1",
|
|
@@ -77,42 +67,52 @@
|
|
|
77
67
|
"typescript": "~5.4.5"
|
|
78
68
|
},
|
|
79
69
|
"typeValidation": {
|
|
80
|
-
"broken": {
|
|
70
|
+
"broken": {
|
|
71
|
+
"TypeAliasDeclaration_CacheContentType": {
|
|
72
|
+
"backCompat": false
|
|
73
|
+
},
|
|
74
|
+
"InterfaceDeclaration_ICacheEntry": {
|
|
75
|
+
"backCompat": false
|
|
76
|
+
},
|
|
77
|
+
"InterfaceDeclaration_IEntry": {
|
|
78
|
+
"backCompat": false
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
81
|
},
|
|
82
82
|
"scripts": {
|
|
83
83
|
"api": "fluid-build . --task api",
|
|
84
84
|
"api-extractor:commonjs": "flub generate entrypoints --outDir ./dist",
|
|
85
85
|
"api-extractor:esnext": "flub generate entrypoints --outDir ./lib --node10TypeCompat",
|
|
86
86
|
"build": "fluid-build . --task build",
|
|
87
|
+
"build:api-reports": "concurrently \"npm:build:api-reports:*\"",
|
|
88
|
+
"build:api-reports:current": "api-extractor run --local --config api-extractor/api-extractor.current.json",
|
|
89
|
+
"build:api-reports:legacy": "api-extractor run --local --config api-extractor/api-extractor.legacy.json",
|
|
87
90
|
"build:commonjs": "fluid-build . --task commonjs",
|
|
88
91
|
"build:compile": "fluid-build . --task compile",
|
|
89
|
-
"build:docs": "
|
|
90
|
-
"build:docs:current": "api-extractor run --local",
|
|
91
|
-
"build:docs:legacy": "api-extractor run --local --config api-extractor/api-extractor.legacy.json",
|
|
92
|
+
"build:docs": "api-extractor run --local",
|
|
92
93
|
"build:esnext": "tsc --project ./tsconfig.json",
|
|
93
94
|
"build:test": "npm run build:test:esm && npm run build:test:cjs",
|
|
94
95
|
"build:test:cjs": "fluid-tsc commonjs --project ./src/test/tsconfig.cjs.json",
|
|
95
96
|
"build:test:esm": "tsc --project ./src/test/tsconfig.json",
|
|
96
97
|
"check:are-the-types-wrong": "attw --pack .",
|
|
97
|
-
"check:biome": "biome check .
|
|
98
|
+
"check:biome": "biome check .",
|
|
98
99
|
"check:exports": "concurrently \"npm:check:exports:*\"",
|
|
99
100
|
"check:exports:bundle-release-tags": "api-extractor run --config api-extractor/api-extractor-lint-bundle.json",
|
|
100
|
-
"check:exports:cjs:beta": "api-extractor run --config api-extractor/api-extractor-lint-beta.cjs.json",
|
|
101
101
|
"check:exports:cjs:legacy": "api-extractor run --config api-extractor/api-extractor-lint-legacy.cjs.json",
|
|
102
102
|
"check:exports:cjs:public": "api-extractor run --config api-extractor/api-extractor-lint-public.cjs.json",
|
|
103
|
-
"check:exports:esm:beta": "api-extractor run --config api-extractor/api-extractor-lint-beta.esm.json",
|
|
104
103
|
"check:exports:esm:legacy": "api-extractor run --config api-extractor/api-extractor-lint-legacy.esm.json",
|
|
105
104
|
"check:exports:esm:public": "api-extractor run --config api-extractor/api-extractor-lint-public.esm.json",
|
|
106
105
|
"check:format": "npm run check:biome",
|
|
107
106
|
"check:prettier": "prettier --check . --cache --ignore-path ../../../.prettierignore",
|
|
108
|
-
"ci:build:
|
|
109
|
-
"ci:build:
|
|
110
|
-
"ci:build:
|
|
107
|
+
"ci:build:api-reports": "concurrently \"npm:ci:build:api-reports:*\"",
|
|
108
|
+
"ci:build:api-reports:current": "api-extractor run --config api-extractor/api-extractor.current.json",
|
|
109
|
+
"ci:build:api-reports:legacy": "api-extractor run --config api-extractor/api-extractor.legacy.json",
|
|
110
|
+
"ci:build:docs": "api-extractor run",
|
|
111
111
|
"clean": "rimraf --glob dist lib \"*.d.ts\" \"**/*.tsbuildinfo\" \"**/*.build.log\" _api-extractor-temp",
|
|
112
112
|
"eslint": "eslint --format stylish src",
|
|
113
113
|
"eslint:fix": "eslint --format stylish src --fix --fix-type problem,suggestion,layout",
|
|
114
114
|
"format": "npm run format:biome",
|
|
115
|
-
"format:biome": "biome check . --
|
|
115
|
+
"format:biome": "biome check . --write",
|
|
116
116
|
"format:prettier": "prettier --write . --cache --ignore-path ../../../.prettierignore",
|
|
117
117
|
"lint": "fluid-build . --task lint",
|
|
118
118
|
"lint:fix": "fluid-build . --task eslint:fix --task format",
|
package/src/factory.ts
CHANGED
|
@@ -67,13 +67,12 @@ export interface IOpsCachingPolicy {
|
|
|
67
67
|
*/
|
|
68
68
|
export interface ICollabSessionOptions {
|
|
69
69
|
/**
|
|
70
|
-
* @deprecated starting in 2.0-RC3. No longer needed.
|
|
71
70
|
* Value indicating the display name for session that admits unauthenticated user.
|
|
72
71
|
* This name will be used in attribution associated with edits made by such user.
|
|
72
|
+
* @deprecated starting in 2.0-RC3. No longer needed.
|
|
73
73
|
*/
|
|
74
74
|
unauthenticatedUserDisplayName?: string;
|
|
75
75
|
/**
|
|
76
|
-
* @deprecated Due to security reasons we will be passing the token via Authorization header only.
|
|
77
76
|
* Value indicating session preference to always pass access token via Authorization header.
|
|
78
77
|
* Default behavior is to pass access token via query parameter unless overall href string
|
|
79
78
|
* length exceeds 2048 characters. Using query param is performance optimization which results
|
|
@@ -81,6 +80,7 @@ export interface ICollabSessionOptions {
|
|
|
81
80
|
* validate CORS. However, not all ODSP implementations understand this optimization.
|
|
82
81
|
* For instance, auth layer on Converged stack will fail request with access token passed via
|
|
83
82
|
* query param.
|
|
83
|
+
* @deprecated Due to security reasons we will be passing the token via Authorization header only.
|
|
84
84
|
*/
|
|
85
85
|
forceAccessTokenViaAuthorizationHeader?: boolean;
|
|
86
86
|
}
|
package/src/index.ts
CHANGED
package/src/odspCache.ts
CHANGED
|
@@ -20,11 +20,18 @@ export const maximumCacheDurationMs: FiveDaysMs = 432_000_000; // 5 days in ms
|
|
|
20
20
|
* @internal
|
|
21
21
|
*/
|
|
22
22
|
export const snapshotKey = "snapshot";
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Describes key for partial snapshot with loading GroupId in cache entry.
|
|
26
|
+
* @internal
|
|
27
|
+
*/
|
|
28
|
+
export const snapshotWithLoadingGroupIdKey = "snapshotWithLoadingGroupId";
|
|
29
|
+
|
|
23
30
|
/**
|
|
24
31
|
* @legacy
|
|
25
32
|
* @alpha
|
|
26
33
|
*/
|
|
27
|
-
export type CacheContentType = "snapshot" | "ops";
|
|
34
|
+
export type CacheContentType = "snapshot" | "ops" | "snapshotWithLoadingGroupId";
|
|
28
35
|
|
|
29
36
|
/*
|
|
30
37
|
* File / container identifier.
|
package/src/tokenFetch.ts
CHANGED
|
@@ -14,7 +14,7 @@ export interface TokenResponse {
|
|
|
14
14
|
|
|
15
15
|
/**
|
|
16
16
|
* Authorization header value will be used verbatim when making network call that requires the token.
|
|
17
|
-
* If not
|
|
17
|
+
* If not provided, the token value will be assumed to be a Bearer token and will be used to generate the
|
|
18
18
|
* Authorization header value in the following format: `Bearer ${token}`.
|
|
19
19
|
*/
|
|
20
20
|
readonly authorizationHeader?: string;
|
package/beta.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
-
* Licensed under the MIT License.
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
/*
|
|
7
|
-
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
-
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
-
*/
|
|
10
|
-
|
|
11
|
-
export * from "./lib/beta.js";
|
package/dist/beta.d.ts
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
-
* Licensed under the MIT License.
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
/*
|
|
7
|
-
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
-
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
-
*/
|
|
10
|
-
|
|
11
|
-
export {}
|
|
12
|
-
|
package/lib/beta.d.ts
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
/*!
|
|
2
|
-
* Copyright (c) Microsoft Corporation and contributors. All rights reserved.
|
|
3
|
-
* Licensed under the MIT License.
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
/*
|
|
7
|
-
* THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
|
|
8
|
-
* Generated by "flub generate entrypoints" in @fluidframework/build-tools.
|
|
9
|
-
*/
|
|
10
|
-
|
|
11
|
-
export {}
|
|
12
|
-
|