@fluidframework/driver-utils 2.0.0-internal.7.2.2 → 2.0.0-internal.7.4.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/README.md +1 -2
- package/api-extractor-lint.json +13 -0
- package/api-extractor.json +9 -1
- package/api-report/driver-utils.api.md +48 -48
- package/dist/adapters/compression/compressionTypes.d.ts +2 -2
- package/dist/adapters/compression/compressionTypes.js +1 -1
- package/dist/adapters/compression/compressionTypes.js.map +1 -1
- package/dist/adapters/compression/summaryblob/documentStorageServiceSummaryBlobCompressionAdapter.d.ts +1 -1
- package/dist/adapters/compression/summaryblob/documentStorageServiceSummaryBlobCompressionAdapter.js +1 -1
- package/dist/adapters/compression/summaryblob/documentStorageServiceSummaryBlobCompressionAdapter.js.map +1 -1
- package/dist/adapters/predefinedAdapters.d.ts +1 -1
- package/dist/adapters/predefinedAdapters.js +1 -1
- package/dist/adapters/predefinedAdapters.js.map +1 -1
- package/dist/blob.d.ts +3 -3
- package/dist/blob.js +3 -3
- package/dist/blob.js.map +1 -1
- package/dist/buildSnapshotTree.d.ts +1 -1
- package/dist/buildSnapshotTree.js +1 -1
- package/dist/buildSnapshotTree.js.map +1 -1
- package/dist/documentStorageServiceProxy.d.ts +1 -1
- package/dist/documentStorageServiceProxy.js +1 -1
- package/dist/documentStorageServiceProxy.js.map +1 -1
- package/dist/driver-utils-alpha.d.ts +169 -0
- package/dist/driver-utils-beta.d.ts +176 -0
- package/dist/driver-utils-public.d.ts +176 -0
- package/dist/driver-utils-untrimmed.d.ts +590 -0
- package/dist/error.d.ts +1 -1
- package/dist/error.js +1 -1
- package/dist/error.js.map +1 -1
- package/dist/insecureUrlResolver.d.ts +1 -1
- package/dist/insecureUrlResolver.js +1 -1
- package/dist/insecureUrlResolver.js.map +1 -1
- package/dist/messageRecognition.d.ts +3 -3
- package/dist/messageRecognition.js +3 -3
- package/dist/messageRecognition.js.map +1 -1
- package/dist/network.d.ts +19 -19
- package/dist/network.d.ts.map +1 -1
- package/dist/network.js +18 -18
- package/dist/network.js.map +1 -1
- package/dist/networkUtils.d.ts +1 -1
- package/dist/networkUtils.js +1 -1
- package/dist/networkUtils.js.map +1 -1
- package/dist/packageVersion.d.ts +1 -1
- package/dist/packageVersion.js +1 -1
- package/dist/packageVersion.js.map +1 -1
- package/dist/parallelRequests.d.ts +6 -6
- package/dist/parallelRequests.d.ts.map +1 -1
- package/dist/parallelRequests.js +14 -14
- package/dist/parallelRequests.js.map +1 -1
- package/dist/prefetchDocumentStorageService.d.ts +1 -1
- package/dist/prefetchDocumentStorageService.js +1 -1
- package/dist/prefetchDocumentStorageService.js.map +1 -1
- package/dist/rateLimiter.d.ts +1 -1
- package/dist/rateLimiter.js +1 -1
- package/dist/rateLimiter.js.map +1 -1
- package/dist/readAndParse.d.ts +1 -1
- package/dist/readAndParse.js +1 -1
- package/dist/readAndParse.js.map +1 -1
- package/dist/runWithRetry.d.ts +11 -9
- package/dist/runWithRetry.d.ts.map +1 -1
- package/dist/runWithRetry.js +20 -16
- package/dist/runWithRetry.js.map +1 -1
- package/dist/summaryForCreateNew.d.ts +2 -2
- package/dist/summaryForCreateNew.js +2 -2
- package/dist/summaryForCreateNew.js.map +1 -1
- package/dist/treeConversions.d.ts +1 -1
- package/dist/treeConversions.js +1 -1
- package/dist/treeConversions.js.map +1 -1
- package/dist/tsdoc-metadata.json +1 -1
- package/lib/adapters/compression/compressionTypes.d.ts +2 -2
- package/lib/adapters/compression/compressionTypes.js +1 -1
- package/lib/adapters/compression/compressionTypes.js.map +1 -1
- package/lib/adapters/compression/summaryblob/documentStorageServiceSummaryBlobCompressionAdapter.d.ts +1 -1
- package/lib/adapters/compression/summaryblob/documentStorageServiceSummaryBlobCompressionAdapter.js +1 -1
- package/lib/adapters/compression/summaryblob/documentStorageServiceSummaryBlobCompressionAdapter.js.map +1 -1
- package/lib/adapters/predefinedAdapters.d.ts +1 -1
- package/lib/adapters/predefinedAdapters.js +1 -1
- package/lib/adapters/predefinedAdapters.js.map +1 -1
- package/lib/blob.d.ts +3 -3
- package/lib/blob.js +3 -3
- package/lib/blob.js.map +1 -1
- package/lib/buildSnapshotTree.d.ts +1 -1
- package/lib/buildSnapshotTree.js +1 -1
- package/lib/buildSnapshotTree.js.map +1 -1
- package/lib/documentStorageServiceProxy.d.ts +1 -1
- package/lib/documentStorageServiceProxy.js +1 -1
- package/lib/documentStorageServiceProxy.js.map +1 -1
- package/lib/driver-utils-alpha.d.ts +169 -0
- package/lib/driver-utils-beta.d.ts +176 -0
- package/lib/driver-utils-public.d.ts +176 -0
- package/lib/driver-utils-untrimmed.d.ts +590 -0
- package/lib/error.d.ts +1 -1
- package/lib/error.js +1 -1
- package/lib/error.js.map +1 -1
- package/lib/insecureUrlResolver.d.ts +1 -1
- package/lib/insecureUrlResolver.js +1 -1
- package/lib/insecureUrlResolver.js.map +1 -1
- package/lib/messageRecognition.d.ts +3 -3
- package/lib/messageRecognition.js +3 -3
- package/lib/messageRecognition.js.map +1 -1
- package/lib/network.d.ts +19 -19
- package/lib/network.d.ts.map +1 -1
- package/lib/network.js +18 -18
- package/lib/network.js.map +1 -1
- package/lib/networkUtils.d.ts +1 -1
- package/lib/networkUtils.js +1 -1
- package/lib/networkUtils.js.map +1 -1
- package/lib/packageVersion.d.ts +1 -1
- package/lib/packageVersion.js +1 -1
- package/lib/packageVersion.js.map +1 -1
- package/lib/parallelRequests.d.ts +6 -6
- package/lib/parallelRequests.d.ts.map +1 -1
- package/lib/parallelRequests.js +14 -14
- package/lib/parallelRequests.js.map +1 -1
- package/lib/prefetchDocumentStorageService.d.ts +1 -1
- package/lib/prefetchDocumentStorageService.js +1 -1
- package/lib/prefetchDocumentStorageService.js.map +1 -1
- package/lib/rateLimiter.d.ts +1 -1
- package/lib/rateLimiter.js +1 -1
- package/lib/rateLimiter.js.map +1 -1
- package/lib/readAndParse.d.ts +1 -1
- package/lib/readAndParse.js +1 -1
- package/lib/readAndParse.js.map +1 -1
- package/lib/runWithRetry.d.ts +11 -9
- package/lib/runWithRetry.d.ts.map +1 -1
- package/lib/runWithRetry.js +20 -16
- package/lib/runWithRetry.js.map +1 -1
- package/lib/summaryForCreateNew.d.ts +2 -2
- package/lib/summaryForCreateNew.js +2 -2
- package/lib/summaryForCreateNew.js.map +1 -1
- package/lib/treeConversions.d.ts +1 -1
- package/lib/treeConversions.js +1 -1
- package/lib/treeConversions.js.map +1 -1
- package/package.json +38 -19
- package/src/adapters/compression/compressionTypes.ts +2 -2
- package/src/adapters/compression/summaryblob/documentStorageServiceSummaryBlobCompressionAdapter.ts +1 -1
- package/src/adapters/predefinedAdapters.ts +1 -1
- package/src/blob.ts +3 -3
- package/src/buildSnapshotTree.ts +1 -1
- package/src/documentStorageServiceProxy.ts +1 -1
- package/src/error.ts +1 -1
- package/src/insecureUrlResolver.ts +1 -1
- package/src/messageRecognition.ts +3 -3
- package/src/network.ts +19 -19
- package/src/networkUtils.ts +1 -1
- package/src/packageVersion.ts +1 -1
- package/src/parallelRequests.ts +15 -15
- package/src/prefetchDocumentStorageService.ts +1 -1
- package/src/rateLimiter.ts +1 -1
- package/src/readAndParse.ts +1 -1
- package/src/runWithRetry.ts +25 -18
- package/src/summaryForCreateNew.ts +2 -2
- package/src/treeConversions.ts +1 -1
package/dist/blob.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"blob.js","sourceRoot":"","sources":["../src/blob.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,+EAM8C;AAE9C;;;GAGG;AACH,MAAa,aAAa;IAKzB;;;;;OAKG;IACH,YACiB,IAAY,EAC5B,QAAgB,EAChB,WAA+B,OAAO;QAFtB,SAAI,GAAJ,IAAI,CAAQ;QAXb,SAAI,GAAG,+BAAQ,CAAC,IAAI,CAAC;QACrB,SAAI,GAAG,gCAAS,CAAC,IAAI,CAAC;QAcrC,IAAI,CAAC,KAAK,GAAG,EAAE,QAAQ,EAAE,QAAQ,EAAE,CAAC;IACrC,CAAC;CACD;AAlBD,sCAkBC;AAED;;;GAGG;AACH,MAAa,aAAa;IAIzB;;;;OAIG;IACH,YACiB,IAAY,EACZ,KAAY;QADZ,SAAI,GAAJ,IAAI,CAAQ;QACZ,UAAK,GAAL,KAAK,CAAO;QAVb,SAAI,GAAG,+BAAQ,CAAC,SAAS,CAAC;QAC1B,SAAI,GAAG,gCAAS,CAAC,IAAI,CAAC;IAUnC,CAAC;CACJ;AAbD,sCAaC;AAED;;;GAGG;AACH,MAAa,mBAAmB;IAK/B;;;;OAIG;IACH,YACiB,IAAY,EACZ,EAAU;QADV,SAAI,GAAJ,IAAI,CAAQ;QACZ,OAAE,GAAF,EAAE,CAAQ;QAXX,SAAI,GAAG,+BAAQ,CAAC,IAAI,CAAC;QACrB,SAAI,GAAG,gCAAS,CAAC,UAAU,CAAC;QAY3C,IAAI,CAAC,KAAK,GAAG,EAAE,EAAE,EAAE,CAAC;IACrB,CAAC;CACD;AAhBD,kDAgBC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport {\n\tFileMode,\n\tIBlob,\n\tIAttachment,\n\tITree,\n\tTreeEntry,\n} from \"@fluidframework/protocol-definitions\";\n\n/**\n * Basic implementation of a blob ITreeEntry\n * @
|
|
1
|
+
{"version":3,"file":"blob.js","sourceRoot":"","sources":["../src/blob.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,+EAM8C;AAE9C;;;GAGG;AACH,MAAa,aAAa;IAKzB;;;;;OAKG;IACH,YACiB,IAAY,EAC5B,QAAgB,EAChB,WAA+B,OAAO;QAFtB,SAAI,GAAJ,IAAI,CAAQ;QAXb,SAAI,GAAG,+BAAQ,CAAC,IAAI,CAAC;QACrB,SAAI,GAAG,gCAAS,CAAC,IAAI,CAAC;QAcrC,IAAI,CAAC,KAAK,GAAG,EAAE,QAAQ,EAAE,QAAQ,EAAE,CAAC;IACrC,CAAC;CACD;AAlBD,sCAkBC;AAED;;;GAGG;AACH,MAAa,aAAa;IAIzB;;;;OAIG;IACH,YACiB,IAAY,EACZ,KAAY;QADZ,SAAI,GAAJ,IAAI,CAAQ;QACZ,UAAK,GAAL,KAAK,CAAO;QAVb,SAAI,GAAG,+BAAQ,CAAC,SAAS,CAAC;QAC1B,SAAI,GAAG,gCAAS,CAAC,IAAI,CAAC;IAUnC,CAAC;CACJ;AAbD,sCAaC;AAED;;;GAGG;AACH,MAAa,mBAAmB;IAK/B;;;;OAIG;IACH,YACiB,IAAY,EACZ,EAAU;QADV,SAAI,GAAJ,IAAI,CAAQ;QACZ,OAAE,GAAF,EAAE,CAAQ;QAXX,SAAI,GAAG,+BAAQ,CAAC,IAAI,CAAC;QACrB,SAAI,GAAG,gCAAS,CAAC,UAAU,CAAC;QAY3C,IAAI,CAAC,KAAK,GAAG,EAAE,EAAE,EAAE,CAAC;IACrB,CAAC;CACD;AAhBD,kDAgBC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport {\n\tFileMode,\n\tIBlob,\n\tIAttachment,\n\tITree,\n\tTreeEntry,\n} from \"@fluidframework/protocol-definitions\";\n\n/**\n * Basic implementation of a blob ITreeEntry\n * @internal\n */\nexport class BlobTreeEntry {\n\tpublic readonly mode = FileMode.File;\n\tpublic readonly type = TreeEntry.Blob;\n\tpublic readonly value: IBlob;\n\n\t/**\n\t * Creates a blob ITreeEntry\n\t * @param path - path of entry\n\t * @param contents - blob contents\n\t * @param encoding - encoding of contents; defaults to utf-8\n\t */\n\tconstructor(\n\t\tpublic readonly path: string,\n\t\tcontents: string,\n\t\tencoding: \"utf-8\" | \"base64\" = \"utf-8\",\n\t) {\n\t\tthis.value = { contents, encoding };\n\t}\n}\n\n/**\n * Basic implementation of a tree ITreeEntry\n * @internal\n */\nexport class TreeTreeEntry {\n\tpublic readonly mode = FileMode.Directory;\n\tpublic readonly type = TreeEntry.Tree;\n\n\t/**\n\t * Creates a tree ITreeEntry\n\t * @param path - path of entry\n\t * @param value - subtree\n\t */\n\tconstructor(\n\t\tpublic readonly path: string,\n\t\tpublic readonly value: ITree,\n\t) {}\n}\n\n/**\n * Basic implementation of an attachment ITreeEntry\n * @internal\n */\nexport class AttachmentTreeEntry {\n\tpublic readonly mode = FileMode.File;\n\tpublic readonly type = TreeEntry.Attachment;\n\tpublic readonly value: IAttachment;\n\n\t/**\n\t * Creates an attachment ITreeEntry\n\t * @param path - path of entry\n\t * @param id - id of external blob attachment\n\t */\n\tconstructor(\n\t\tpublic readonly path: string,\n\t\tpublic readonly id: string,\n\t) {\n\t\tthis.value = { id };\n\t}\n}\n"]}
|
|
@@ -10,7 +10,7 @@ import { ISnapshotTree, ITreeEntry } from "@fluidframework/protocol-definitions"
|
|
|
10
10
|
* @param blobMap - a map of blob's sha1 to content that gets filled with content from entries
|
|
11
11
|
* NOTE: blobMap's validity is contingent on the returned promise's resolution
|
|
12
12
|
* @returns the hierarchical tree
|
|
13
|
-
* @
|
|
13
|
+
* @internal
|
|
14
14
|
*/
|
|
15
15
|
export declare function buildSnapshotTree(entries: ITreeEntry[], blobMap: Map<string, ArrayBufferLike>): ISnapshotTree;
|
|
16
16
|
//# sourceMappingURL=buildSnapshotTree.d.ts.map
|
|
@@ -69,7 +69,7 @@ function flatten(tree, blobMap) {
|
|
|
69
69
|
* @param blobMap - a map of blob's sha1 to content that gets filled with content from entries
|
|
70
70
|
* NOTE: blobMap's validity is contingent on the returned promise's resolution
|
|
71
71
|
* @returns the hierarchical tree
|
|
72
|
-
* @
|
|
72
|
+
* @internal
|
|
73
73
|
*/
|
|
74
74
|
function buildSnapshotTree(entries, blobMap) {
|
|
75
75
|
const flattened = flatten(entries, blobMap);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"buildSnapshotTree.js","sourceRoot":"","sources":["../src/buildSnapshotTree.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,+DAA8D;AAC9D,2DAAoD;AAEpD,+EAK8C;AAC9C,iEAAsE;AACtE,+BAAkC;AAElC,SAAS,WAAW,CACnB,IAAY,EACZ,WAAyB,EACzB,OAAqC;IAErC,MAAM,OAAO,GAAqB,EAAE,CAAC;IACrC,KAAK,MAAM,SAAS,IAAI,WAAW,EAAE;QACpC,MAAM,OAAO,GAAG,GAAG,IAAI,GAAG,SAAS,CAAC,IAAI,EAAE,CAAC;QAE3C,IAAI,SAAS,CAAC,IAAI,KAAK,gCAAS,CAAC,IAAI,EAAE;YACtC,MAAM,IAAI,GAAG,SAAS,CAAC,KAAK,CAAC;YAC7B,MAAM,MAAM,GAAG,IAAA,6BAAc,EAAC,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;YAC5D,MAAM,EAAE,GAAG,IAAA,SAAI,GAAE,CAAC;YAClB,OAAO,CAAC,GAAG,CAAC,EAAE,EAAE,MAAM,CAAC,CAAC;YAExB,MAAM,KAAK,GAAmB;gBAC7B,IAAI,EAAE,+BAAQ,CAAC,SAAS,CAAC,IAAI,CAAC;gBAC9B,IAAI,EAAE,OAAO;gBACb,GAAG,EAAE,EAAE;gBACP,IAAI,EAAE,CAAC;gBACP,IAAI,EAAE,MAAM;gBACZ,GAAG,EAAE,EAAE;aACP,CAAC;YACF,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;SACpB;aAAM,IAAI,SAAS,CAAC,IAAI,KAAK,gCAAS,CAAC,IAAI,EAAE;YAC7C,IAAA,mBAAM,EACL,SAAS,CAAC,IAAI,KAAK,gCAAS,CAAC,IAAI,EACjC,KAAK,CAAC,8CAA8C,CACpD,CAAC;YACF,MAAM,CAAC,GAAG,SAAS,CAAC,KAAK,CAAC;YAC1B,MAAM,KAAK,GAAmB;gBAC7B,IAAI,EAAE,+BAAQ,CAAC,SAAS,CAAC,IAAI,CAAC;gBAC9B,IAAI,EAAE,OAAO;gBACb,GAAG,EAAE,EAAE;gBACP,IAAI,EAAE,CAAC,CAAC;gBACR,IAAI,EAAE,MAAM;gBACZ,GAAG,EAAE,EAAE;aACP,CAAC;YACF,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;YAEpB,MAAM,cAAc,GAAG,WAAW,CAAC,GAAG,OAAO,GAAG,EAAE,CAAC,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;YACtE,OAAO,CAAC,IAAI,CAAC,GAAG,cAAc,CAAC,CAAC;SAChC;KACD;IAED,OAAO,OAAO,CAAC;AAChB,CAAC;AAED;;;;;;GAMG;AACH,SAAS,OAAO,CAAC,IAAkB,EAAE,OAAqC;IACzE,MAAM,OAAO,GAAG,WAAW,CAAC,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/C,OAAO;QACN,GAAG,EAAE,EAAE;QACP,IAAI,EAAE,OAAO;QACb,GAAG,EAAE,EAAE;KACP,CAAC;AACH,CAAC;AAED;;;;;;;;GAQG;AACH,SAAgB,iBAAiB,CAChC,OAAqB,EACrB,OAAqC;IAErC,MAAM,SAAS,GAAG,OAAO,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IAC5C,OAAO,IAAA,qCAAqB,EAAC,SAAS,CAAC,CAAC;AACzC,CAAC;AAND,8CAMC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { stringToBuffer } from \"@fluid-internal/client-utils\";\nimport { assert } from \"@fluidframework/core-utils\";\nimport * as git from \"@fluidframework/gitresources\";\nimport {\n\tFileMode,\n\tISnapshotTree,\n\tITreeEntry,\n\tTreeEntry,\n} from \"@fluidframework/protocol-definitions\";\nimport { buildGitTreeHierarchy } from \"@fluidframework/protocol-base\";\nimport { v4 as uuid } from \"uuid\";\n\nfunction flattenCore(\n\tpath: string,\n\ttreeEntries: ITreeEntry[],\n\tblobMap: Map<string, ArrayBufferLike>,\n): git.ITreeEntry[] {\n\tconst entries: git.ITreeEntry[] = [];\n\tfor (const treeEntry of treeEntries) {\n\t\tconst subPath = `${path}${treeEntry.path}`;\n\n\t\tif (treeEntry.type === TreeEntry.Blob) {\n\t\t\tconst blob = treeEntry.value;\n\t\t\tconst buffer = stringToBuffer(blob.contents, blob.encoding);\n\t\t\tconst id = uuid();\n\t\t\tblobMap.set(id, buffer);\n\n\t\t\tconst entry: git.ITreeEntry = {\n\t\t\t\tmode: FileMode[treeEntry.mode],\n\t\t\t\tpath: subPath,\n\t\t\t\tsha: id,\n\t\t\t\tsize: 0,\n\t\t\t\ttype: \"blob\",\n\t\t\t\turl: \"\",\n\t\t\t};\n\t\t\tentries.push(entry);\n\t\t} else if (treeEntry.type === TreeEntry.Tree) {\n\t\t\tassert(\n\t\t\t\ttreeEntry.type === TreeEntry.Tree,\n\t\t\t\t0x101 /* \"Unexpected tree entry type on flatten!\" */,\n\t\t\t);\n\t\t\tconst t = treeEntry.value;\n\t\t\tconst entry: git.ITreeEntry = {\n\t\t\t\tmode: FileMode[treeEntry.mode],\n\t\t\t\tpath: subPath,\n\t\t\t\tsha: \"\",\n\t\t\t\tsize: -1,\n\t\t\t\ttype: \"tree\",\n\t\t\t\turl: \"\",\n\t\t\t};\n\t\t\tentries.push(entry);\n\n\t\t\tconst subTreeEntries = flattenCore(`${subPath}/`, t.entries, blobMap);\n\t\t\tentries.push(...subTreeEntries);\n\t\t}\n\t}\n\n\treturn entries;\n}\n\n/**\n * Create a flatten view of an array of ITreeEntry\n *\n * @param tree - an array of ITreeEntry to flatten\n * @param blobMap - a map of blob's sha1 to content\n * @returns A flatten with of the ITreeEntry\n */\nfunction flatten(tree: ITreeEntry[], blobMap: Map<string, ArrayBufferLike>): git.ITree {\n\tconst entries = flattenCore(\"\", tree, blobMap);\n\treturn {\n\t\tsha: \"\",\n\t\ttree: entries,\n\t\turl: \"\",\n\t};\n}\n\n/**\n * Build a tree hierarchy base on an array of ITreeEntry\n *\n * @param entries - an array of ITreeEntry to flatten\n * @param blobMap - a map of blob's sha1 to content that gets filled with content from entries\n * NOTE: blobMap's validity is contingent on the returned promise's resolution\n * @returns the hierarchical tree\n * @
|
|
1
|
+
{"version":3,"file":"buildSnapshotTree.js","sourceRoot":"","sources":["../src/buildSnapshotTree.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,+DAA8D;AAC9D,2DAAoD;AAEpD,+EAK8C;AAC9C,iEAAsE;AACtE,+BAAkC;AAElC,SAAS,WAAW,CACnB,IAAY,EACZ,WAAyB,EACzB,OAAqC;IAErC,MAAM,OAAO,GAAqB,EAAE,CAAC;IACrC,KAAK,MAAM,SAAS,IAAI,WAAW,EAAE;QACpC,MAAM,OAAO,GAAG,GAAG,IAAI,GAAG,SAAS,CAAC,IAAI,EAAE,CAAC;QAE3C,IAAI,SAAS,CAAC,IAAI,KAAK,gCAAS,CAAC,IAAI,EAAE;YACtC,MAAM,IAAI,GAAG,SAAS,CAAC,KAAK,CAAC;YAC7B,MAAM,MAAM,GAAG,IAAA,6BAAc,EAAC,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;YAC5D,MAAM,EAAE,GAAG,IAAA,SAAI,GAAE,CAAC;YAClB,OAAO,CAAC,GAAG,CAAC,EAAE,EAAE,MAAM,CAAC,CAAC;YAExB,MAAM,KAAK,GAAmB;gBAC7B,IAAI,EAAE,+BAAQ,CAAC,SAAS,CAAC,IAAI,CAAC;gBAC9B,IAAI,EAAE,OAAO;gBACb,GAAG,EAAE,EAAE;gBACP,IAAI,EAAE,CAAC;gBACP,IAAI,EAAE,MAAM;gBACZ,GAAG,EAAE,EAAE;aACP,CAAC;YACF,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;SACpB;aAAM,IAAI,SAAS,CAAC,IAAI,KAAK,gCAAS,CAAC,IAAI,EAAE;YAC7C,IAAA,mBAAM,EACL,SAAS,CAAC,IAAI,KAAK,gCAAS,CAAC,IAAI,EACjC,KAAK,CAAC,8CAA8C,CACpD,CAAC;YACF,MAAM,CAAC,GAAG,SAAS,CAAC,KAAK,CAAC;YAC1B,MAAM,KAAK,GAAmB;gBAC7B,IAAI,EAAE,+BAAQ,CAAC,SAAS,CAAC,IAAI,CAAC;gBAC9B,IAAI,EAAE,OAAO;gBACb,GAAG,EAAE,EAAE;gBACP,IAAI,EAAE,CAAC,CAAC;gBACR,IAAI,EAAE,MAAM;gBACZ,GAAG,EAAE,EAAE;aACP,CAAC;YACF,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;YAEpB,MAAM,cAAc,GAAG,WAAW,CAAC,GAAG,OAAO,GAAG,EAAE,CAAC,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;YACtE,OAAO,CAAC,IAAI,CAAC,GAAG,cAAc,CAAC,CAAC;SAChC;KACD;IAED,OAAO,OAAO,CAAC;AAChB,CAAC;AAED;;;;;;GAMG;AACH,SAAS,OAAO,CAAC,IAAkB,EAAE,OAAqC;IACzE,MAAM,OAAO,GAAG,WAAW,CAAC,EAAE,EAAE,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/C,OAAO;QACN,GAAG,EAAE,EAAE;QACP,IAAI,EAAE,OAAO;QACb,GAAG,EAAE,EAAE;KACP,CAAC;AACH,CAAC;AAED;;;;;;;;GAQG;AACH,SAAgB,iBAAiB,CAChC,OAAqB,EACrB,OAAqC;IAErC,MAAM,SAAS,GAAG,OAAO,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IAC5C,OAAO,IAAA,qCAAqB,EAAC,SAAS,CAAC,CAAC;AACzC,CAAC;AAND,8CAMC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { stringToBuffer } from \"@fluid-internal/client-utils\";\nimport { assert } from \"@fluidframework/core-utils\";\nimport * as git from \"@fluidframework/gitresources\";\nimport {\n\tFileMode,\n\tISnapshotTree,\n\tITreeEntry,\n\tTreeEntry,\n} from \"@fluidframework/protocol-definitions\";\nimport { buildGitTreeHierarchy } from \"@fluidframework/protocol-base\";\nimport { v4 as uuid } from \"uuid\";\n\nfunction flattenCore(\n\tpath: string,\n\ttreeEntries: ITreeEntry[],\n\tblobMap: Map<string, ArrayBufferLike>,\n): git.ITreeEntry[] {\n\tconst entries: git.ITreeEntry[] = [];\n\tfor (const treeEntry of treeEntries) {\n\t\tconst subPath = `${path}${treeEntry.path}`;\n\n\t\tif (treeEntry.type === TreeEntry.Blob) {\n\t\t\tconst blob = treeEntry.value;\n\t\t\tconst buffer = stringToBuffer(blob.contents, blob.encoding);\n\t\t\tconst id = uuid();\n\t\t\tblobMap.set(id, buffer);\n\n\t\t\tconst entry: git.ITreeEntry = {\n\t\t\t\tmode: FileMode[treeEntry.mode],\n\t\t\t\tpath: subPath,\n\t\t\t\tsha: id,\n\t\t\t\tsize: 0,\n\t\t\t\ttype: \"blob\",\n\t\t\t\turl: \"\",\n\t\t\t};\n\t\t\tentries.push(entry);\n\t\t} else if (treeEntry.type === TreeEntry.Tree) {\n\t\t\tassert(\n\t\t\t\ttreeEntry.type === TreeEntry.Tree,\n\t\t\t\t0x101 /* \"Unexpected tree entry type on flatten!\" */,\n\t\t\t);\n\t\t\tconst t = treeEntry.value;\n\t\t\tconst entry: git.ITreeEntry = {\n\t\t\t\tmode: FileMode[treeEntry.mode],\n\t\t\t\tpath: subPath,\n\t\t\t\tsha: \"\",\n\t\t\t\tsize: -1,\n\t\t\t\ttype: \"tree\",\n\t\t\t\turl: \"\",\n\t\t\t};\n\t\t\tentries.push(entry);\n\n\t\t\tconst subTreeEntries = flattenCore(`${subPath}/`, t.entries, blobMap);\n\t\t\tentries.push(...subTreeEntries);\n\t\t}\n\t}\n\n\treturn entries;\n}\n\n/**\n * Create a flatten view of an array of ITreeEntry\n *\n * @param tree - an array of ITreeEntry to flatten\n * @param blobMap - a map of blob's sha1 to content\n * @returns A flatten with of the ITreeEntry\n */\nfunction flatten(tree: ITreeEntry[], blobMap: Map<string, ArrayBufferLike>): git.ITree {\n\tconst entries = flattenCore(\"\", tree, blobMap);\n\treturn {\n\t\tsha: \"\",\n\t\ttree: entries,\n\t\turl: \"\",\n\t};\n}\n\n/**\n * Build a tree hierarchy base on an array of ITreeEntry\n *\n * @param entries - an array of ITreeEntry to flatten\n * @param blobMap - a map of blob's sha1 to content that gets filled with content from entries\n * NOTE: blobMap's validity is contingent on the returned promise's resolution\n * @returns the hierarchical tree\n * @internal\n */\nexport function buildSnapshotTree(\n\tentries: ITreeEntry[],\n\tblobMap: Map<string, ArrayBufferLike>,\n): ISnapshotTree {\n\tconst flattened = flatten(entries, blobMap);\n\treturn buildGitTreeHierarchy(flattened);\n}\n"]}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
import { FetchSource, IDocumentStorageService, IDocumentStorageServicePolicies, ISummaryContext } from "@fluidframework/driver-definitions";
|
|
6
6
|
import { ICreateBlobResponse, ISnapshotTree, ISummaryHandle, ISummaryTree, IVersion } from "@fluidframework/protocol-definitions";
|
|
7
7
|
/**
|
|
8
|
-
* @
|
|
8
|
+
* @internal
|
|
9
9
|
*/
|
|
10
10
|
export declare class DocumentStorageServiceProxy implements IDocumentStorageService {
|
|
11
11
|
protected readonly internalStorageService: IDocumentStorageService;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"documentStorageServiceProxy.js","sourceRoot":"","sources":["../src/documentStorageServiceProxy.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAgBH;;GAEG;AACH,MAAa,2BAA2B;IAGvC,IAAW,QAAQ,CAAC,QAAqD;QACxE,IAAI,CAAC,SAAS,GAAG,QAAQ,CAAC;IAC3B,CAAC;IAED,IAAW,QAAQ;QAClB,OAAO,IAAI,CAAC,SAAS,IAAI,IAAI,CAAC,sBAAsB,CAAC,QAAQ,CAAC;IAC/D,CAAC;IAED,IAAW,aAAa;QACvB,OAAO,IAAI,CAAC,sBAAsB,CAAC,aAAa,CAAC;IAClD,CAAC;IAED,YAA+B,sBAA+C;QAA/C,2BAAsB,GAAtB,sBAAsB,CAAyB;IAAG,CAAC;IAE3E,KAAK,CAAC,eAAe,CAC3B,OAAkB,EAClB,YAAqB;QAErB,OAAO,IAAI,CAAC,sBAAsB,CAAC,eAAe,CAAC,OAAO,EAAE,YAAY,CAAC,CAAC;IAC3E,CAAC;IAEM,KAAK,CAAC,WAAW,CACvB,SAAwB,EACxB,KAAa,EACb,YAAqB,EACrB,WAAyB;QAEzB,OAAO,IAAI,CAAC,sBAAsB,CAAC,WAAW,CAAC,SAAS,EAAE,KAAK,EAAE,YAAY,EAAE,WAAW,CAAC,CAAC;IAC7F,CAAC;IAEM,KAAK,CAAC,wBAAwB,CACpC,OAAqB,EACrB,OAAwB;QAExB,OAAO,IAAI,CAAC,sBAAsB,CAAC,wBAAwB,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IAC/E,CAAC;IAEM,KAAK,CAAC,eAAe,CAAC,MAAsB;QAClD,OAAO,IAAI,CAAC,sBAAsB,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC;IAC5D,CAAC;IAEM,KAAK,CAAC,UAAU,CAAC,IAAqB;QAC5C,OAAO,IAAI,CAAC,sBAAsB,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;IACrD,CAAC;IAEM,KAAK,CAAC,QAAQ,CAAC,MAAc;QACnC,OAAO,IAAI,CAAC,sBAAsB,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IACrD,CAAC;CACD;AAnDD,kEAmDC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport {\n\tFetchSource,\n\tIDocumentStorageService,\n\tIDocumentStorageServicePolicies,\n\tISummaryContext,\n} from \"@fluidframework/driver-definitions\";\nimport {\n\tICreateBlobResponse,\n\tISnapshotTree,\n\tISummaryHandle,\n\tISummaryTree,\n\tIVersion,\n} from \"@fluidframework/protocol-definitions\";\n\n/**\n * @
|
|
1
|
+
{"version":3,"file":"documentStorageServiceProxy.js","sourceRoot":"","sources":["../src/documentStorageServiceProxy.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAgBH;;GAEG;AACH,MAAa,2BAA2B;IAGvC,IAAW,QAAQ,CAAC,QAAqD;QACxE,IAAI,CAAC,SAAS,GAAG,QAAQ,CAAC;IAC3B,CAAC;IAED,IAAW,QAAQ;QAClB,OAAO,IAAI,CAAC,SAAS,IAAI,IAAI,CAAC,sBAAsB,CAAC,QAAQ,CAAC;IAC/D,CAAC;IAED,IAAW,aAAa;QACvB,OAAO,IAAI,CAAC,sBAAsB,CAAC,aAAa,CAAC;IAClD,CAAC;IAED,YAA+B,sBAA+C;QAA/C,2BAAsB,GAAtB,sBAAsB,CAAyB;IAAG,CAAC;IAE3E,KAAK,CAAC,eAAe,CAC3B,OAAkB,EAClB,YAAqB;QAErB,OAAO,IAAI,CAAC,sBAAsB,CAAC,eAAe,CAAC,OAAO,EAAE,YAAY,CAAC,CAAC;IAC3E,CAAC;IAEM,KAAK,CAAC,WAAW,CACvB,SAAwB,EACxB,KAAa,EACb,YAAqB,EACrB,WAAyB;QAEzB,OAAO,IAAI,CAAC,sBAAsB,CAAC,WAAW,CAAC,SAAS,EAAE,KAAK,EAAE,YAAY,EAAE,WAAW,CAAC,CAAC;IAC7F,CAAC;IAEM,KAAK,CAAC,wBAAwB,CACpC,OAAqB,EACrB,OAAwB;QAExB,OAAO,IAAI,CAAC,sBAAsB,CAAC,wBAAwB,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;IAC/E,CAAC;IAEM,KAAK,CAAC,eAAe,CAAC,MAAsB;QAClD,OAAO,IAAI,CAAC,sBAAsB,CAAC,eAAe,CAAC,MAAM,CAAC,CAAC;IAC5D,CAAC;IAEM,KAAK,CAAC,UAAU,CAAC,IAAqB;QAC5C,OAAO,IAAI,CAAC,sBAAsB,CAAC,UAAU,CAAC,IAAI,CAAC,CAAC;IACrD,CAAC;IAEM,KAAK,CAAC,QAAQ,CAAC,MAAc;QACnC,OAAO,IAAI,CAAC,sBAAsB,CAAC,QAAQ,CAAC,MAAM,CAAC,CAAC;IACrD,CAAC;CACD;AAnDD,kEAmDC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport {\n\tFetchSource,\n\tIDocumentStorageService,\n\tIDocumentStorageServicePolicies,\n\tISummaryContext,\n} from \"@fluidframework/driver-definitions\";\nimport {\n\tICreateBlobResponse,\n\tISnapshotTree,\n\tISummaryHandle,\n\tISummaryTree,\n\tIVersion,\n} from \"@fluidframework/protocol-definitions\";\n\n/**\n * @internal\n */\nexport class DocumentStorageServiceProxy implements IDocumentStorageService {\n\tprivate _policies: IDocumentStorageServicePolicies | undefined;\n\n\tpublic set policies(policies: IDocumentStorageServicePolicies | undefined) {\n\t\tthis._policies = policies;\n\t}\n\n\tpublic get policies() {\n\t\treturn this._policies ?? this.internalStorageService.policies;\n\t}\n\n\tpublic get repositoryUrl(): string {\n\t\treturn this.internalStorageService.repositoryUrl;\n\t}\n\n\tconstructor(protected readonly internalStorageService: IDocumentStorageService) {}\n\n\tpublic async getSnapshotTree(\n\t\tversion?: IVersion,\n\t\tscenarioName?: string,\n\t): Promise<ISnapshotTree | null> {\n\t\treturn this.internalStorageService.getSnapshotTree(version, scenarioName);\n\t}\n\n\tpublic async getVersions(\n\t\tversionId: string | null,\n\t\tcount: number,\n\t\tscenarioName?: string,\n\t\tfetchSource?: FetchSource,\n\t): Promise<IVersion[]> {\n\t\treturn this.internalStorageService.getVersions(versionId, count, scenarioName, fetchSource);\n\t}\n\n\tpublic async uploadSummaryWithContext(\n\t\tsummary: ISummaryTree,\n\t\tcontext: ISummaryContext,\n\t): Promise<string> {\n\t\treturn this.internalStorageService.uploadSummaryWithContext(summary, context);\n\t}\n\n\tpublic async downloadSummary(handle: ISummaryHandle): Promise<ISummaryTree> {\n\t\treturn this.internalStorageService.downloadSummary(handle);\n\t}\n\n\tpublic async createBlob(file: ArrayBufferLike): Promise<ICreateBlobResponse> {\n\t\treturn this.internalStorageService.createBlob(file);\n\t}\n\n\tpublic async readBlob(blobId: string): Promise<ArrayBufferLike> {\n\t\treturn this.internalStorageService.readBlob(blobId);\n\t}\n}\n"]}
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
import { FetchSource } from '@fluidframework/driver-definitions';
|
|
2
|
+
import { IAttachment } from '@fluidframework/protocol-definitions';
|
|
3
|
+
import { IAuthorizationError } from '@fluidframework/driver-definitions';
|
|
4
|
+
import { IBlob } from '@fluidframework/protocol-definitions';
|
|
5
|
+
import { ICommittedProposal } from '@fluidframework/protocol-definitions';
|
|
6
|
+
import { ICreateBlobResponse } from '@fluidframework/protocol-definitions';
|
|
7
|
+
import { IDeltasFetchResult } from '@fluidframework/driver-definitions';
|
|
8
|
+
import { IDocumentAttributes } from '@fluidframework/protocol-definitions';
|
|
9
|
+
import { IDocumentMessage } from '@fluidframework/protocol-definitions';
|
|
10
|
+
import { IDocumentServiceFactory } from '@fluidframework/driver-definitions';
|
|
11
|
+
import { IDocumentStorageService } from '@fluidframework/driver-definitions';
|
|
12
|
+
import { IDocumentStorageServicePolicies } from '@fluidframework/driver-definitions';
|
|
13
|
+
import { IDriverErrorBase } from '@fluidframework/driver-definitions';
|
|
14
|
+
import { IFluidErrorBase } from '@fluidframework/telemetry-utils';
|
|
15
|
+
import { ILocationRedirectionError } from '@fluidframework/driver-definitions';
|
|
16
|
+
import { IRequest } from '@fluidframework/core-interfaces';
|
|
17
|
+
import { IResolvedUrl } from '@fluidframework/driver-definitions';
|
|
18
|
+
import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
|
|
19
|
+
import { ISnapshotTree } from '@fluidframework/protocol-definitions';
|
|
20
|
+
import { IStream } from '@fluidframework/driver-definitions';
|
|
21
|
+
import { IStreamResult } from '@fluidframework/driver-definitions';
|
|
22
|
+
import { ISummaryContext } from '@fluidframework/driver-definitions';
|
|
23
|
+
import { ISummaryHandle } from '@fluidframework/protocol-definitions';
|
|
24
|
+
import { ISummaryTree } from '@fluidframework/protocol-definitions';
|
|
25
|
+
import { ITelemetryErrorEvent } from '@fluidframework/core-interfaces';
|
|
26
|
+
import { ITelemetryLoggerExt } from '@fluidframework/telemetry-utils';
|
|
27
|
+
import { ITelemetryProperties } from '@fluidframework/core-interfaces';
|
|
28
|
+
import { IThrottlingWarning } from '@fluidframework/driver-definitions';
|
|
29
|
+
import { ITree } from '@fluidframework/protocol-definitions';
|
|
30
|
+
import { ITreeEntry } from '@fluidframework/protocol-definitions';
|
|
31
|
+
import { IUrlResolver } from '@fluidframework/driver-definitions';
|
|
32
|
+
import { IVersion } from '@fluidframework/protocol-definitions';
|
|
33
|
+
import { LoaderCachingPolicy } from '@fluidframework/driver-definitions';
|
|
34
|
+
import { LoggingError } from '@fluidframework/telemetry-utils';
|
|
35
|
+
|
|
36
|
+
/* Excluded from this release type: applyStorageCompression */
|
|
37
|
+
|
|
38
|
+
/* Excluded from this release type: AttachmentTreeEntry */
|
|
39
|
+
|
|
40
|
+
/* Excluded from this release type: AuthorizationError */
|
|
41
|
+
|
|
42
|
+
/* Excluded from this release type: blobHeadersBlobName */
|
|
43
|
+
|
|
44
|
+
/* Excluded from this release type: BlobTreeEntry */
|
|
45
|
+
|
|
46
|
+
/* Excluded from this release type: buildSnapshotTree */
|
|
47
|
+
|
|
48
|
+
/* Excluded from this release type: calculateMaxWaitTime */
|
|
49
|
+
|
|
50
|
+
/* Excluded from this release type: canBeCoalescedByService */
|
|
51
|
+
|
|
52
|
+
/* Excluded from this release type: canRetryOnError */
|
|
53
|
+
|
|
54
|
+
/* Excluded from this release type: CombinedAppAndProtocolSummary */
|
|
55
|
+
|
|
56
|
+
/* Excluded from this release type: convertSummaryTreeToSnapshotITree */
|
|
57
|
+
|
|
58
|
+
/* Excluded from this release type: createGenericNetworkError */
|
|
59
|
+
|
|
60
|
+
/* Excluded from this release type: createWriteError */
|
|
61
|
+
|
|
62
|
+
/* Excluded from this release type: DeltaStreamConnectionForbiddenError */
|
|
63
|
+
|
|
64
|
+
/* Excluded from this release type: DocumentStorageServiceProxy */
|
|
65
|
+
|
|
66
|
+
/* Excluded from this release type: DriverErrorTelemetryProps */
|
|
67
|
+
|
|
68
|
+
/* Excluded from this release type: emptyMessageStream */
|
|
69
|
+
|
|
70
|
+
/* Excluded from this release type: FluidInvalidSchemaError */
|
|
71
|
+
|
|
72
|
+
/* Excluded from this release type: GenericNetworkError */
|
|
73
|
+
|
|
74
|
+
/* Excluded from this release type: getDocAttributesFromProtocolSummary */
|
|
75
|
+
|
|
76
|
+
/* Excluded from this release type: getQuorumValuesFromProtocolSummary */
|
|
77
|
+
|
|
78
|
+
/* Excluded from this release type: getRetryDelayFromError */
|
|
79
|
+
|
|
80
|
+
/* Excluded from this release type: getRetryDelaySecondsFromError */
|
|
81
|
+
|
|
82
|
+
/* Excluded from this release type: IAuthorizationError */
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* @alpha
|
|
86
|
+
*/
|
|
87
|
+
export declare interface ICompressionStorageConfig {
|
|
88
|
+
algorithm: SummaryCompressionAlgorithm;
|
|
89
|
+
minSizeToCompress: number;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
/* Excluded from this release type: IDeltasFetchResult */
|
|
93
|
+
|
|
94
|
+
/* Excluded from this release type: IFluidErrorBase */
|
|
95
|
+
|
|
96
|
+
/* Excluded from this release type: ILocationRedirectionError */
|
|
97
|
+
|
|
98
|
+
/* Excluded from this release type: InsecureUrlResolver */
|
|
99
|
+
|
|
100
|
+
/* Excluded from this release type: IProgress */
|
|
101
|
+
|
|
102
|
+
/* Excluded from this release type: isCombinedAppAndProtocolSummary */
|
|
103
|
+
|
|
104
|
+
/* Excluded from this release type: isOnline */
|
|
105
|
+
|
|
106
|
+
/* Excluded from this release type: isRuntimeMessage */
|
|
107
|
+
|
|
108
|
+
/* Excluded from this release type: IThrottlingWarning */
|
|
109
|
+
|
|
110
|
+
/* Excluded from this release type: LocationRedirectionError */
|
|
111
|
+
|
|
112
|
+
/* Excluded from this release type: LoggingError */
|
|
113
|
+
|
|
114
|
+
/* Excluded from this release type: logNetworkFailure */
|
|
115
|
+
|
|
116
|
+
/* Excluded from this release type: MessageType2 */
|
|
117
|
+
|
|
118
|
+
/* Excluded from this release type: NetworkErrorBasic */
|
|
119
|
+
|
|
120
|
+
/* Excluded from this release type: NonRetryableError */
|
|
121
|
+
|
|
122
|
+
/* Excluded from this release type: OnlineStatus */
|
|
123
|
+
|
|
124
|
+
/* Excluded from this release type: ParallelRequests */
|
|
125
|
+
|
|
126
|
+
/* Excluded from this release type: PrefetchDocumentStorageService */
|
|
127
|
+
|
|
128
|
+
/* Excluded from this release type: Queue */
|
|
129
|
+
|
|
130
|
+
/**
|
|
131
|
+
* @alpha
|
|
132
|
+
*/
|
|
133
|
+
export declare class RateLimiter {
|
|
134
|
+
private maxRequests;
|
|
135
|
+
private readonly tasks;
|
|
136
|
+
constructor(maxRequests: number);
|
|
137
|
+
get waitQueueLength(): number;
|
|
138
|
+
protected readonly release: () => void;
|
|
139
|
+
protected acquire(): Promise<void>;
|
|
140
|
+
schedule<T>(work: () => Promise<T>): Promise<T>;
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
/* Excluded from this release type: readAndParse */
|
|
144
|
+
|
|
145
|
+
/* Excluded from this release type: requestOps */
|
|
146
|
+
|
|
147
|
+
/* Excluded from this release type: RetryableError */
|
|
148
|
+
|
|
149
|
+
/* Excluded from this release type: runWithRetry */
|
|
150
|
+
|
|
151
|
+
/* Excluded from this release type: streamFromMessages */
|
|
152
|
+
|
|
153
|
+
/* Excluded from this release type: streamObserver */
|
|
154
|
+
|
|
155
|
+
/**
|
|
156
|
+
* @alpha
|
|
157
|
+
*/
|
|
158
|
+
export declare enum SummaryCompressionAlgorithm {
|
|
159
|
+
None = 0,
|
|
160
|
+
LZ4 = 1
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
/* Excluded from this release type: ThrottlingError */
|
|
164
|
+
|
|
165
|
+
/* Excluded from this release type: TreeTreeEntry */
|
|
166
|
+
|
|
167
|
+
/* Excluded from this release type: UsageError */
|
|
168
|
+
|
|
169
|
+
export { }
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
import { FetchSource } from '@fluidframework/driver-definitions';
|
|
2
|
+
import { IAttachment } from '@fluidframework/protocol-definitions';
|
|
3
|
+
import { IAuthorizationError } from '@fluidframework/driver-definitions';
|
|
4
|
+
import { IBlob } from '@fluidframework/protocol-definitions';
|
|
5
|
+
import { ICommittedProposal } from '@fluidframework/protocol-definitions';
|
|
6
|
+
import { ICreateBlobResponse } from '@fluidframework/protocol-definitions';
|
|
7
|
+
import { IDeltasFetchResult } from '@fluidframework/driver-definitions';
|
|
8
|
+
import { IDocumentAttributes } from '@fluidframework/protocol-definitions';
|
|
9
|
+
import { IDocumentMessage } from '@fluidframework/protocol-definitions';
|
|
10
|
+
import { IDocumentServiceFactory } from '@fluidframework/driver-definitions';
|
|
11
|
+
import { IDocumentStorageService } from '@fluidframework/driver-definitions';
|
|
12
|
+
import { IDocumentStorageServicePolicies } from '@fluidframework/driver-definitions';
|
|
13
|
+
import { IDriverErrorBase } from '@fluidframework/driver-definitions';
|
|
14
|
+
import { IFluidErrorBase } from '@fluidframework/telemetry-utils';
|
|
15
|
+
import { ILocationRedirectionError } from '@fluidframework/driver-definitions';
|
|
16
|
+
import { IRequest } from '@fluidframework/core-interfaces';
|
|
17
|
+
import { IResolvedUrl } from '@fluidframework/driver-definitions';
|
|
18
|
+
import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
|
|
19
|
+
import { ISnapshotTree } from '@fluidframework/protocol-definitions';
|
|
20
|
+
import { IStream } from '@fluidframework/driver-definitions';
|
|
21
|
+
import { IStreamResult } from '@fluidframework/driver-definitions';
|
|
22
|
+
import { ISummaryContext } from '@fluidframework/driver-definitions';
|
|
23
|
+
import { ISummaryHandle } from '@fluidframework/protocol-definitions';
|
|
24
|
+
import { ISummaryTree } from '@fluidframework/protocol-definitions';
|
|
25
|
+
import { ITelemetryErrorEvent } from '@fluidframework/core-interfaces';
|
|
26
|
+
import { ITelemetryLoggerExt } from '@fluidframework/telemetry-utils';
|
|
27
|
+
import { ITelemetryProperties } from '@fluidframework/core-interfaces';
|
|
28
|
+
import { IThrottlingWarning } from '@fluidframework/driver-definitions';
|
|
29
|
+
import { ITree } from '@fluidframework/protocol-definitions';
|
|
30
|
+
import { ITreeEntry } from '@fluidframework/protocol-definitions';
|
|
31
|
+
import { IUrlResolver } from '@fluidframework/driver-definitions';
|
|
32
|
+
import { IVersion } from '@fluidframework/protocol-definitions';
|
|
33
|
+
import { LoaderCachingPolicy } from '@fluidframework/driver-definitions';
|
|
34
|
+
import { LoggingError } from '@fluidframework/telemetry-utils';
|
|
35
|
+
|
|
36
|
+
/* Excluded from this release type: applyStorageCompression */
|
|
37
|
+
|
|
38
|
+
/* Excluded from this release type: AttachmentTreeEntry */
|
|
39
|
+
|
|
40
|
+
/* Excluded from this release type: AuthorizationError */
|
|
41
|
+
|
|
42
|
+
/* Excluded from this release type: blobHeadersBlobName */
|
|
43
|
+
|
|
44
|
+
/* Excluded from this release type: BlobTreeEntry */
|
|
45
|
+
|
|
46
|
+
/* Excluded from this release type: buildSnapshotTree */
|
|
47
|
+
|
|
48
|
+
/* Excluded from this release type: calculateMaxWaitTime */
|
|
49
|
+
|
|
50
|
+
/* Excluded from this release type: canBeCoalescedByService */
|
|
51
|
+
|
|
52
|
+
/* Excluded from this release type: canRetryOnError */
|
|
53
|
+
|
|
54
|
+
/* Excluded from this release type: CombinedAppAndProtocolSummary */
|
|
55
|
+
|
|
56
|
+
/* Excluded from this release type: convertSummaryTreeToSnapshotITree */
|
|
57
|
+
|
|
58
|
+
/* Excluded from this release type: createGenericNetworkError */
|
|
59
|
+
|
|
60
|
+
/* Excluded from this release type: createWriteError */
|
|
61
|
+
|
|
62
|
+
/* Excluded from this release type: DeltaStreamConnectionForbiddenError */
|
|
63
|
+
|
|
64
|
+
/* Excluded from this release type: DocumentStorageServiceProxy */
|
|
65
|
+
|
|
66
|
+
/* Excluded from this release type: DriverErrorTelemetryProps */
|
|
67
|
+
|
|
68
|
+
/* Excluded from this release type: emptyMessageStream */
|
|
69
|
+
|
|
70
|
+
/* Excluded from this release type: FetchSource */
|
|
71
|
+
|
|
72
|
+
/* Excluded from this release type: FluidInvalidSchemaError */
|
|
73
|
+
|
|
74
|
+
/* Excluded from this release type: GenericNetworkError */
|
|
75
|
+
|
|
76
|
+
/* Excluded from this release type: getDocAttributesFromProtocolSummary */
|
|
77
|
+
|
|
78
|
+
/* Excluded from this release type: getQuorumValuesFromProtocolSummary */
|
|
79
|
+
|
|
80
|
+
/* Excluded from this release type: getRetryDelayFromError */
|
|
81
|
+
|
|
82
|
+
/* Excluded from this release type: getRetryDelaySecondsFromError */
|
|
83
|
+
|
|
84
|
+
/* Excluded from this release type: IAuthorizationError */
|
|
85
|
+
|
|
86
|
+
/* Excluded from this release type: ICompressionStorageConfig */
|
|
87
|
+
|
|
88
|
+
/* Excluded from this release type: IDeltasFetchResult */
|
|
89
|
+
|
|
90
|
+
/* Excluded from this release type: IDocumentServiceFactory */
|
|
91
|
+
|
|
92
|
+
/* Excluded from this release type: IDocumentStorageService */
|
|
93
|
+
|
|
94
|
+
/* Excluded from this release type: IDocumentStorageServicePolicies */
|
|
95
|
+
|
|
96
|
+
/* Excluded from this release type: IDriverErrorBase */
|
|
97
|
+
|
|
98
|
+
/* Excluded from this release type: IFluidErrorBase */
|
|
99
|
+
|
|
100
|
+
/* Excluded from this release type: ILocationRedirectionError */
|
|
101
|
+
|
|
102
|
+
/* Excluded from this release type: InsecureUrlResolver */
|
|
103
|
+
|
|
104
|
+
/* Excluded from this release type: IProgress */
|
|
105
|
+
|
|
106
|
+
/* Excluded from this release type: IRequest */
|
|
107
|
+
|
|
108
|
+
/* Excluded from this release type: IResolvedUrl */
|
|
109
|
+
|
|
110
|
+
/* Excluded from this release type: isCombinedAppAndProtocolSummary */
|
|
111
|
+
|
|
112
|
+
/* Excluded from this release type: isOnline */
|
|
113
|
+
|
|
114
|
+
/* Excluded from this release type: isRuntimeMessage */
|
|
115
|
+
|
|
116
|
+
/* Excluded from this release type: IStream */
|
|
117
|
+
|
|
118
|
+
/* Excluded from this release type: IStreamResult */
|
|
119
|
+
|
|
120
|
+
/* Excluded from this release type: ISummaryContext */
|
|
121
|
+
|
|
122
|
+
/* Excluded from this release type: ITelemetryErrorEvent */
|
|
123
|
+
|
|
124
|
+
/* Excluded from this release type: ITelemetryLoggerExt */
|
|
125
|
+
|
|
126
|
+
/* Excluded from this release type: ITelemetryProperties */
|
|
127
|
+
|
|
128
|
+
/* Excluded from this release type: IThrottlingWarning */
|
|
129
|
+
|
|
130
|
+
/* Excluded from this release type: IUrlResolver */
|
|
131
|
+
|
|
132
|
+
/* Excluded from this release type: LoaderCachingPolicy */
|
|
133
|
+
|
|
134
|
+
/* Excluded from this release type: LocationRedirectionError */
|
|
135
|
+
|
|
136
|
+
/* Excluded from this release type: LoggingError */
|
|
137
|
+
|
|
138
|
+
/* Excluded from this release type: logNetworkFailure */
|
|
139
|
+
|
|
140
|
+
/* Excluded from this release type: MessageType2 */
|
|
141
|
+
|
|
142
|
+
/* Excluded from this release type: NetworkErrorBasic */
|
|
143
|
+
|
|
144
|
+
/* Excluded from this release type: NonRetryableError */
|
|
145
|
+
|
|
146
|
+
/* Excluded from this release type: OnlineStatus */
|
|
147
|
+
|
|
148
|
+
/* Excluded from this release type: ParallelRequests */
|
|
149
|
+
|
|
150
|
+
/* Excluded from this release type: PrefetchDocumentStorageService */
|
|
151
|
+
|
|
152
|
+
/* Excluded from this release type: Queue */
|
|
153
|
+
|
|
154
|
+
/* Excluded from this release type: RateLimiter */
|
|
155
|
+
|
|
156
|
+
/* Excluded from this release type: readAndParse */
|
|
157
|
+
|
|
158
|
+
/* Excluded from this release type: requestOps */
|
|
159
|
+
|
|
160
|
+
/* Excluded from this release type: RetryableError */
|
|
161
|
+
|
|
162
|
+
/* Excluded from this release type: runWithRetry */
|
|
163
|
+
|
|
164
|
+
/* Excluded from this release type: streamFromMessages */
|
|
165
|
+
|
|
166
|
+
/* Excluded from this release type: streamObserver */
|
|
167
|
+
|
|
168
|
+
/* Excluded from this release type: SummaryCompressionAlgorithm */
|
|
169
|
+
|
|
170
|
+
/* Excluded from this release type: ThrottlingError */
|
|
171
|
+
|
|
172
|
+
/* Excluded from this release type: TreeTreeEntry */
|
|
173
|
+
|
|
174
|
+
/* Excluded from this release type: UsageError */
|
|
175
|
+
|
|
176
|
+
export { }
|
|
@@ -0,0 +1,176 @@
|
|
|
1
|
+
import { FetchSource } from '@fluidframework/driver-definitions';
|
|
2
|
+
import { IAttachment } from '@fluidframework/protocol-definitions';
|
|
3
|
+
import { IAuthorizationError } from '@fluidframework/driver-definitions';
|
|
4
|
+
import { IBlob } from '@fluidframework/protocol-definitions';
|
|
5
|
+
import { ICommittedProposal } from '@fluidframework/protocol-definitions';
|
|
6
|
+
import { ICreateBlobResponse } from '@fluidframework/protocol-definitions';
|
|
7
|
+
import { IDeltasFetchResult } from '@fluidframework/driver-definitions';
|
|
8
|
+
import { IDocumentAttributes } from '@fluidframework/protocol-definitions';
|
|
9
|
+
import { IDocumentMessage } from '@fluidframework/protocol-definitions';
|
|
10
|
+
import { IDocumentServiceFactory } from '@fluidframework/driver-definitions';
|
|
11
|
+
import { IDocumentStorageService } from '@fluidframework/driver-definitions';
|
|
12
|
+
import { IDocumentStorageServicePolicies } from '@fluidframework/driver-definitions';
|
|
13
|
+
import { IDriverErrorBase } from '@fluidframework/driver-definitions';
|
|
14
|
+
import { IFluidErrorBase } from '@fluidframework/telemetry-utils';
|
|
15
|
+
import { ILocationRedirectionError } from '@fluidframework/driver-definitions';
|
|
16
|
+
import { IRequest } from '@fluidframework/core-interfaces';
|
|
17
|
+
import { IResolvedUrl } from '@fluidframework/driver-definitions';
|
|
18
|
+
import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
|
|
19
|
+
import { ISnapshotTree } from '@fluidframework/protocol-definitions';
|
|
20
|
+
import { IStream } from '@fluidframework/driver-definitions';
|
|
21
|
+
import { IStreamResult } from '@fluidframework/driver-definitions';
|
|
22
|
+
import { ISummaryContext } from '@fluidframework/driver-definitions';
|
|
23
|
+
import { ISummaryHandle } from '@fluidframework/protocol-definitions';
|
|
24
|
+
import { ISummaryTree } from '@fluidframework/protocol-definitions';
|
|
25
|
+
import { ITelemetryErrorEvent } from '@fluidframework/core-interfaces';
|
|
26
|
+
import { ITelemetryLoggerExt } from '@fluidframework/telemetry-utils';
|
|
27
|
+
import { ITelemetryProperties } from '@fluidframework/core-interfaces';
|
|
28
|
+
import { IThrottlingWarning } from '@fluidframework/driver-definitions';
|
|
29
|
+
import { ITree } from '@fluidframework/protocol-definitions';
|
|
30
|
+
import { ITreeEntry } from '@fluidframework/protocol-definitions';
|
|
31
|
+
import { IUrlResolver } from '@fluidframework/driver-definitions';
|
|
32
|
+
import { IVersion } from '@fluidframework/protocol-definitions';
|
|
33
|
+
import { LoaderCachingPolicy } from '@fluidframework/driver-definitions';
|
|
34
|
+
import { LoggingError } from '@fluidframework/telemetry-utils';
|
|
35
|
+
|
|
36
|
+
/* Excluded from this release type: applyStorageCompression */
|
|
37
|
+
|
|
38
|
+
/* Excluded from this release type: AttachmentTreeEntry */
|
|
39
|
+
|
|
40
|
+
/* Excluded from this release type: AuthorizationError */
|
|
41
|
+
|
|
42
|
+
/* Excluded from this release type: blobHeadersBlobName */
|
|
43
|
+
|
|
44
|
+
/* Excluded from this release type: BlobTreeEntry */
|
|
45
|
+
|
|
46
|
+
/* Excluded from this release type: buildSnapshotTree */
|
|
47
|
+
|
|
48
|
+
/* Excluded from this release type: calculateMaxWaitTime */
|
|
49
|
+
|
|
50
|
+
/* Excluded from this release type: canBeCoalescedByService */
|
|
51
|
+
|
|
52
|
+
/* Excluded from this release type: canRetryOnError */
|
|
53
|
+
|
|
54
|
+
/* Excluded from this release type: CombinedAppAndProtocolSummary */
|
|
55
|
+
|
|
56
|
+
/* Excluded from this release type: convertSummaryTreeToSnapshotITree */
|
|
57
|
+
|
|
58
|
+
/* Excluded from this release type: createGenericNetworkError */
|
|
59
|
+
|
|
60
|
+
/* Excluded from this release type: createWriteError */
|
|
61
|
+
|
|
62
|
+
/* Excluded from this release type: DeltaStreamConnectionForbiddenError */
|
|
63
|
+
|
|
64
|
+
/* Excluded from this release type: DocumentStorageServiceProxy */
|
|
65
|
+
|
|
66
|
+
/* Excluded from this release type: DriverErrorTelemetryProps */
|
|
67
|
+
|
|
68
|
+
/* Excluded from this release type: emptyMessageStream */
|
|
69
|
+
|
|
70
|
+
/* Excluded from this release type: FetchSource */
|
|
71
|
+
|
|
72
|
+
/* Excluded from this release type: FluidInvalidSchemaError */
|
|
73
|
+
|
|
74
|
+
/* Excluded from this release type: GenericNetworkError */
|
|
75
|
+
|
|
76
|
+
/* Excluded from this release type: getDocAttributesFromProtocolSummary */
|
|
77
|
+
|
|
78
|
+
/* Excluded from this release type: getQuorumValuesFromProtocolSummary */
|
|
79
|
+
|
|
80
|
+
/* Excluded from this release type: getRetryDelayFromError */
|
|
81
|
+
|
|
82
|
+
/* Excluded from this release type: getRetryDelaySecondsFromError */
|
|
83
|
+
|
|
84
|
+
/* Excluded from this release type: IAuthorizationError */
|
|
85
|
+
|
|
86
|
+
/* Excluded from this release type: ICompressionStorageConfig */
|
|
87
|
+
|
|
88
|
+
/* Excluded from this release type: IDeltasFetchResult */
|
|
89
|
+
|
|
90
|
+
/* Excluded from this release type: IDocumentServiceFactory */
|
|
91
|
+
|
|
92
|
+
/* Excluded from this release type: IDocumentStorageService */
|
|
93
|
+
|
|
94
|
+
/* Excluded from this release type: IDocumentStorageServicePolicies */
|
|
95
|
+
|
|
96
|
+
/* Excluded from this release type: IDriverErrorBase */
|
|
97
|
+
|
|
98
|
+
/* Excluded from this release type: IFluidErrorBase */
|
|
99
|
+
|
|
100
|
+
/* Excluded from this release type: ILocationRedirectionError */
|
|
101
|
+
|
|
102
|
+
/* Excluded from this release type: InsecureUrlResolver */
|
|
103
|
+
|
|
104
|
+
/* Excluded from this release type: IProgress */
|
|
105
|
+
|
|
106
|
+
/* Excluded from this release type: IRequest */
|
|
107
|
+
|
|
108
|
+
/* Excluded from this release type: IResolvedUrl */
|
|
109
|
+
|
|
110
|
+
/* Excluded from this release type: isCombinedAppAndProtocolSummary */
|
|
111
|
+
|
|
112
|
+
/* Excluded from this release type: isOnline */
|
|
113
|
+
|
|
114
|
+
/* Excluded from this release type: isRuntimeMessage */
|
|
115
|
+
|
|
116
|
+
/* Excluded from this release type: IStream */
|
|
117
|
+
|
|
118
|
+
/* Excluded from this release type: IStreamResult */
|
|
119
|
+
|
|
120
|
+
/* Excluded from this release type: ISummaryContext */
|
|
121
|
+
|
|
122
|
+
/* Excluded from this release type: ITelemetryErrorEvent */
|
|
123
|
+
|
|
124
|
+
/* Excluded from this release type: ITelemetryLoggerExt */
|
|
125
|
+
|
|
126
|
+
/* Excluded from this release type: ITelemetryProperties */
|
|
127
|
+
|
|
128
|
+
/* Excluded from this release type: IThrottlingWarning */
|
|
129
|
+
|
|
130
|
+
/* Excluded from this release type: IUrlResolver */
|
|
131
|
+
|
|
132
|
+
/* Excluded from this release type: LoaderCachingPolicy */
|
|
133
|
+
|
|
134
|
+
/* Excluded from this release type: LocationRedirectionError */
|
|
135
|
+
|
|
136
|
+
/* Excluded from this release type: LoggingError */
|
|
137
|
+
|
|
138
|
+
/* Excluded from this release type: logNetworkFailure */
|
|
139
|
+
|
|
140
|
+
/* Excluded from this release type: MessageType2 */
|
|
141
|
+
|
|
142
|
+
/* Excluded from this release type: NetworkErrorBasic */
|
|
143
|
+
|
|
144
|
+
/* Excluded from this release type: NonRetryableError */
|
|
145
|
+
|
|
146
|
+
/* Excluded from this release type: OnlineStatus */
|
|
147
|
+
|
|
148
|
+
/* Excluded from this release type: ParallelRequests */
|
|
149
|
+
|
|
150
|
+
/* Excluded from this release type: PrefetchDocumentStorageService */
|
|
151
|
+
|
|
152
|
+
/* Excluded from this release type: Queue */
|
|
153
|
+
|
|
154
|
+
/* Excluded from this release type: RateLimiter */
|
|
155
|
+
|
|
156
|
+
/* Excluded from this release type: readAndParse */
|
|
157
|
+
|
|
158
|
+
/* Excluded from this release type: requestOps */
|
|
159
|
+
|
|
160
|
+
/* Excluded from this release type: RetryableError */
|
|
161
|
+
|
|
162
|
+
/* Excluded from this release type: runWithRetry */
|
|
163
|
+
|
|
164
|
+
/* Excluded from this release type: streamFromMessages */
|
|
165
|
+
|
|
166
|
+
/* Excluded from this release type: streamObserver */
|
|
167
|
+
|
|
168
|
+
/* Excluded from this release type: SummaryCompressionAlgorithm */
|
|
169
|
+
|
|
170
|
+
/* Excluded from this release type: ThrottlingError */
|
|
171
|
+
|
|
172
|
+
/* Excluded from this release type: TreeTreeEntry */
|
|
173
|
+
|
|
174
|
+
/* Excluded from this release type: UsageError */
|
|
175
|
+
|
|
176
|
+
export { }
|