@fluidframework/local-driver 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.
Files changed (117) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/README.md +1 -2
  3. package/api-extractor-lint.json +13 -0
  4. package/api-extractor.json +3 -3
  5. package/api-report/local-driver.api.md +9 -9
  6. package/dist/{auth.js → auth.cjs} +1 -1
  7. package/dist/auth.cjs.map +1 -0
  8. package/dist/{index.js → index.cjs} +8 -8
  9. package/dist/index.cjs.map +1 -0
  10. package/dist/local-driver-alpha.d.ts +108 -0
  11. package/dist/local-driver-beta.d.ts +81 -0
  12. package/dist/local-driver-public.d.ts +81 -0
  13. package/dist/local-driver-untrimmed.d.ts +224 -0
  14. package/dist/{localCreateDocument.js → localCreateDocument.cjs} +1 -1
  15. package/dist/localCreateDocument.cjs.map +1 -0
  16. package/dist/{localDeltaStorageService.js → localDeltaStorageService.cjs} +2 -1
  17. package/dist/localDeltaStorageService.cjs.map +1 -0
  18. package/dist/localDeltaStorageService.d.ts +1 -0
  19. package/dist/localDeltaStorageService.d.ts.map +1 -1
  20. package/dist/{localDocumentDeltaConnection.js → localDocumentDeltaConnection.cjs} +2 -1
  21. package/dist/localDocumentDeltaConnection.cjs.map +1 -0
  22. package/dist/localDocumentDeltaConnection.d.ts +1 -0
  23. package/dist/localDocumentDeltaConnection.d.ts.map +1 -1
  24. package/dist/{localDocumentService.js → localDocumentService.cjs} +6 -4
  25. package/dist/localDocumentService.cjs.map +1 -0
  26. package/dist/localDocumentService.d.ts +2 -0
  27. package/dist/localDocumentService.d.ts.map +1 -1
  28. package/dist/{localDocumentServiceFactory.js → localDocumentServiceFactory.cjs} +4 -3
  29. package/dist/localDocumentServiceFactory.cjs.map +1 -0
  30. package/dist/localDocumentServiceFactory.d.ts +1 -0
  31. package/dist/localDocumentServiceFactory.d.ts.map +1 -1
  32. package/dist/{localDocumentStorageService.js → localDocumentStorageService.cjs} +5 -2
  33. package/dist/localDocumentStorageService.cjs.map +1 -0
  34. package/dist/localDocumentStorageService.d.ts +3 -0
  35. package/dist/localDocumentStorageService.d.ts.map +1 -1
  36. package/dist/{localResolver.js → localResolver.cjs} +6 -2
  37. package/dist/localResolver.cjs.map +1 -0
  38. package/dist/localResolver.d.ts +4 -0
  39. package/dist/localResolver.d.ts.map +1 -1
  40. package/dist/{localSessionStorageDb.js → localSessionStorageDb.cjs} +2 -1
  41. package/dist/localSessionStorageDb.cjs.map +1 -0
  42. package/dist/localSessionStorageDb.d.ts +1 -0
  43. package/dist/localSessionStorageDb.d.ts.map +1 -1
  44. package/dist/tsdoc-metadata.json +1 -1
  45. package/lib/auth.d.ts.map +1 -1
  46. package/lib/{auth.js → auth.mjs} +1 -1
  47. package/lib/auth.mjs.map +1 -0
  48. package/lib/index.d.ts +7 -7
  49. package/lib/index.d.ts.map +1 -1
  50. package/lib/{index.js → index.mjs} +8 -8
  51. package/lib/index.mjs.map +1 -0
  52. package/lib/local-driver-alpha.d.ts +108 -0
  53. package/lib/local-driver-beta.d.ts +81 -0
  54. package/lib/local-driver-public.d.ts +81 -0
  55. package/lib/local-driver-untrimmed.d.ts +224 -0
  56. package/lib/localCreateDocument.d.ts.map +1 -1
  57. package/lib/{localCreateDocument.js → localCreateDocument.mjs} +1 -1
  58. package/lib/localCreateDocument.mjs.map +1 -0
  59. package/lib/localDeltaStorageService.d.ts +1 -0
  60. package/lib/localDeltaStorageService.d.ts.map +1 -1
  61. package/lib/{localDeltaStorageService.js → localDeltaStorageService.mjs} +2 -1
  62. package/lib/localDeltaStorageService.mjs.map +1 -0
  63. package/lib/localDocumentDeltaConnection.d.ts +1 -0
  64. package/lib/localDocumentDeltaConnection.d.ts.map +1 -1
  65. package/lib/{localDocumentDeltaConnection.js → localDocumentDeltaConnection.mjs} +2 -1
  66. package/lib/localDocumentDeltaConnection.mjs.map +1 -0
  67. package/lib/localDocumentService.d.ts +3 -1
  68. package/lib/localDocumentService.d.ts.map +1 -1
  69. package/lib/{localDocumentService.js → localDocumentService.mjs} +6 -4
  70. package/lib/localDocumentService.mjs.map +1 -0
  71. package/lib/localDocumentServiceFactory.d.ts +1 -0
  72. package/lib/localDocumentServiceFactory.d.ts.map +1 -1
  73. package/lib/{localDocumentServiceFactory.js → localDocumentServiceFactory.mjs} +4 -3
  74. package/lib/localDocumentServiceFactory.mjs.map +1 -0
  75. package/lib/localDocumentStorageService.d.ts +3 -0
  76. package/lib/localDocumentStorageService.d.ts.map +1 -1
  77. package/lib/{localDocumentStorageService.js → localDocumentStorageService.mjs} +5 -2
  78. package/lib/localDocumentStorageService.mjs.map +1 -0
  79. package/lib/localResolver.d.ts +4 -0
  80. package/lib/localResolver.d.ts.map +1 -1
  81. package/lib/{localResolver.js → localResolver.mjs} +6 -2
  82. package/lib/localResolver.mjs.map +1 -0
  83. package/lib/localSessionStorageDb.d.ts +1 -0
  84. package/lib/localSessionStorageDb.d.ts.map +1 -1
  85. package/lib/{localSessionStorageDb.js → localSessionStorageDb.mjs} +2 -5
  86. package/lib/localSessionStorageDb.mjs.map +1 -0
  87. package/package.json +47 -27
  88. package/src/localDeltaStorageService.ts +1 -0
  89. package/src/localDocumentDeltaConnection.ts +1 -0
  90. package/src/localDocumentService.ts +2 -0
  91. package/src/localDocumentServiceFactory.ts +1 -0
  92. package/src/localDocumentStorageService.ts +3 -0
  93. package/src/localResolver.ts +4 -0
  94. package/src/localSessionStorageDb.ts +1 -0
  95. package/tsc-multi.test.json +4 -0
  96. package/tsconfig.json +5 -3
  97. package/dist/auth.js.map +0 -1
  98. package/dist/index.js.map +0 -1
  99. package/dist/localCreateDocument.js.map +0 -1
  100. package/dist/localDeltaStorageService.js.map +0 -1
  101. package/dist/localDocumentDeltaConnection.js.map +0 -1
  102. package/dist/localDocumentService.js.map +0 -1
  103. package/dist/localDocumentServiceFactory.js.map +0 -1
  104. package/dist/localDocumentStorageService.js.map +0 -1
  105. package/dist/localResolver.js.map +0 -1
  106. package/dist/localSessionStorageDb.js.map +0 -1
  107. package/lib/auth.js.map +0 -1
  108. package/lib/index.js.map +0 -1
  109. package/lib/localCreateDocument.js.map +0 -1
  110. package/lib/localDeltaStorageService.js.map +0 -1
  111. package/lib/localDocumentDeltaConnection.js.map +0 -1
  112. package/lib/localDocumentService.js.map +0 -1
  113. package/lib/localDocumentServiceFactory.js.map +0 -1
  114. package/lib/localDocumentStorageService.js.map +0 -1
  115. package/lib/localResolver.js.map +0 -1
  116. package/lib/localSessionStorageDb.js.map +0 -1
  117. package/tsconfig.esnext.json +0 -7
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # @fluidframework/local-driver
2
2
 
3
+ ## 2.0.0-internal.7.4.0
4
+
5
+ Dependency updates only.
6
+
7
+ ## 2.0.0-internal.7.3.0
8
+
9
+ Dependency updates only.
10
+
3
11
  ## 2.0.0-internal.7.2.0
4
12
 
5
13
  Dependency updates only.
package/README.md CHANGED
@@ -30,8 +30,7 @@ package for more information including tools to convert between version schemes.
30
30
 
31
31
  This project may contain Microsoft trademarks or logos for Microsoft projects, products, or services.
32
32
 
33
- Use of these trademarks or logos must follow Microsoft's [Trademark & Brand
34
- Guidelines](https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks/usage/general).
33
+ Use of these trademarks or logos must follow Microsoft's [Trademark & Brand Guidelines](https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks/usage/general).
35
34
 
36
35
  Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship.
37
36
 
@@ -0,0 +1,13 @@
1
+ {
2
+ "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
3
+ "extends": "../../../common/build/build-common/api-extractor-lint.json",
4
+ "messages": {
5
+ "extractorMessageReporting": {
6
+ // TODO: remove once base config has this enabled as an error
7
+ "ae-incompatible-release-tags": {
8
+ "logLevel": "error",
9
+ "addToApiReportFile": false
10
+ }
11
+ }
12
+ }
13
+ }
@@ -1,10 +1,10 @@
1
1
  {
2
2
  "$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
3
- "extends": "@fluidframework/build-common/api-extractor-base.json",
3
+ "extends": "../../../common/build/build-common/api-extractor-base.json",
4
4
  "messages": {
5
5
  "extractorMessageReporting": {
6
- "ae-missing-release-tag": {
7
- // TODO: Fix violations and remove this rule override
6
+ // TODO: Add missing documentation and remove this rule override
7
+ "ae-undocumented": {
8
8
  "logLevel": "none"
9
9
  }
10
10
  }
@@ -36,20 +36,20 @@ import { IWebSocketServer } from '@fluidframework/server-services-core';
36
36
  import { NackErrorType } from '@fluidframework/protocol-definitions';
37
37
  import type { Socket } from 'socket.io-client';
38
38
 
39
- // @public
39
+ // @internal
40
40
  export function createLocalDocumentService(resolvedUrl: IResolvedUrl, localDeltaConnectionServer: ILocalDeltaConnectionServer, tokenProvider: ITokenProvider, tenantId: string, documentId: string, documentDeltaConnectionsMap: Map<string, LocalDocumentDeltaConnection>, policies?: IDocumentServicePolicies, innerDocumentService?: IDocumentService, logger?: ITelemetryBaseLogger): IDocumentService;
41
41
 
42
- // @public (undocumented)
42
+ // @alpha (undocumented)
43
43
  export function createLocalResolverCreateNewRequest(documentId: string): IRequest;
44
44
 
45
- // @public
45
+ // @internal
46
46
  export class LocalDeltaStorageService implements IDocumentDeltaStorageService {
47
47
  constructor(tenantId: string, id: string, databaseManager: IDatabaseManager);
48
48
  // (undocumented)
49
49
  fetchMessages(from: number, to: number | undefined, abortSignal?: AbortSignal, cachedOnly?: boolean): IStream<ISequencedDocumentMessage[]>;
50
50
  }
51
51
 
52
- // @public
52
+ // @internal
53
53
  export class LocalDocumentDeltaConnection extends DocumentDeltaConnection {
54
54
  constructor(socket: Socket, documentId: string, logger?: ITelemetryBaseLogger);
55
55
  static create(tenantId: string, id: string, token: string, client: IClient, webSocketServer: IWebSocketServer, timeoutMs?: number, logger?: ITelemetryBaseLogger): Promise<LocalDocumentDeltaConnection>;
@@ -59,7 +59,7 @@ export class LocalDocumentDeltaConnection extends DocumentDeltaConnection {
59
59
  submitSignal(message: any): void;
60
60
  }
61
61
 
62
- // @public
62
+ // @internal
63
63
  export class LocalDocumentService implements IDocumentService {
64
64
  constructor(resolvedUrl: IResolvedUrl, localDeltaConnectionServer: ILocalDeltaConnectionServer, tokenProvider: ITokenProvider, tenantId: string, documentId: string, documentDeltaConnectionsMap: Map<string, LocalDocumentDeltaConnection>, policies?: IDocumentServicePolicies, innerDocumentService?: IDocumentService | undefined, logger?: ITelemetryBaseLogger | undefined);
65
65
  connectToDeltaStorage(): Promise<IDocumentDeltaStorageService>;
@@ -73,7 +73,7 @@ export class LocalDocumentService implements IDocumentService {
73
73
  readonly resolvedUrl: IResolvedUrl;
74
74
  }
75
75
 
76
- // @public
76
+ // @alpha
77
77
  export class LocalDocumentServiceFactory implements IDocumentServiceFactory {
78
78
  constructor(localDeltaConnectionServer: ILocalDeltaConnectionServer, policies?: IDocumentServicePolicies | undefined, innerDocumentService?: IDocumentService | undefined);
79
79
  // (undocumented)
@@ -83,7 +83,7 @@ export class LocalDocumentServiceFactory implements IDocumentServiceFactory {
83
83
  nackClient(clientId: string, code?: number, type?: NackErrorType, message?: any): void;
84
84
  }
85
85
 
86
- // @public (undocumented)
86
+ // @internal (undocumented)
87
87
  export class LocalDocumentStorageService implements IDocumentStorageService {
88
88
  constructor(id: string, manager: GitManager, policies: IDocumentStorageServicePolicies, localDeltaConnectionServer?: ILocalDeltaConnectionServer | undefined, resolvedUrl?: IResolvedUrl | undefined);
89
89
  // (undocumented)
@@ -106,7 +106,7 @@ export class LocalDocumentStorageService implements IDocumentStorageService {
106
106
  uploadSummaryWithContext(summary: ISummaryTree, context: ISummaryContext): Promise<string>;
107
107
  }
108
108
 
109
- // @public
109
+ // @alpha
110
110
  export class LocalResolver implements IUrlResolver {
111
111
  constructor();
112
112
  // (undocumented)
@@ -116,7 +116,7 @@ export class LocalResolver implements IUrlResolver {
116
116
  resolve(request: IRequest): Promise<IResolvedUrl>;
117
117
  }
118
118
 
119
- // @public
119
+ // @internal
120
120
  export class LocalSessionStorageDbFactory implements ITestDbFactory {
121
121
  // (undocumented)
122
122
  connect(): Promise<IDb>;
@@ -42,4 +42,4 @@ function generateUser() {
42
42
  return randomUser;
43
43
  }
44
44
  exports.generateUser = generateUser;
45
- //# sourceMappingURL=auth.js.map
45
+ //# sourceMappingURL=auth.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"auth.cjs","sourceRoot":"","sources":["../src/auth.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAGH,yCAA8C;AAC9C,+BAAkC;AAElC;;;GAGG;AACH,SAAgB,aAAa,CAC5B,QAAgB,EAChB,UAAkB,EAClB,GAAW,EACX,MAAmB,EACnB,IAAY,EACZ,WAAmB,EAAE,GAAG,EAAE,EAC1B,MAAc,KAAK;IAEnB,IAAI,SAAS,GAAG,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,YAAY,EAAE,CAAC;IAC7C,IAAI,SAAS,CAAC,EAAE,KAAK,EAAE,IAAI,SAAS,CAAC,EAAE,KAAK,SAAS,EAAE;QACtD,SAAS,GAAG,YAAY,EAAE,CAAC;KAC3B;IAED,0BAA0B;IAC1B,MAAM,GAAG,GAAG,IAAI,CAAC,KAAK,CAAC,IAAI,IAAI,EAAE,CAAC,OAAO,EAAE,GAAG,IAAI,CAAC,CAAC;IAEpD,MAAM,MAAM,GAAiB;QAC5B,UAAU;QACV,MAAM;QACN,QAAQ;QACR,IAAI,EAAE,SAAS;QACf,GAAG,EAAE,GAAG;QACR,GAAG,EAAE,GAAG,GAAG,QAAQ;QACnB,GAAG;KACH,CAAC;IAEF,MAAM,OAAO,GAAG,EAAE,IAAI,EAAE,GAAG,EAAE,CAAC;IAC9B,OAAO,gBAAS,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,CAC5B,IAAI,EACJ,IAAI,CAAC,SAAS,CAAC,EAAE,GAAG,EAAE,OAAO,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC,EAC5C,MAAM,EACN,OAAO,CACP,CAAC;AACH,CAAC;AAlCD,sCAkCC;AAED,SAAgB,YAAY;IAC3B,MAAM,MAAM,GAAG,IAAA,SAAI,GAAE,CAAC;IACtB,MAAM,KAAK,GAAG,MAAM,CAAC,KAAK,CAAC,4BAA4B,CAAC,CAAC;IACzD,MAAM,QAAQ,GAAG,KAAK,KAAK,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,uEAAuE;IAE5H,MAAM,UAAU,GAAG;QAClB,EAAE,EAAE,MAAM;QACV,IAAI,EAAE,QAAQ;KACd,CAAC;IAEF,OAAO,UAAU,CAAC;AACnB,CAAC;AAXD,oCAWC","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nimport { ITokenClaims, IUser, ScopeType } from \"@fluidframework/protocol-definitions\";\nimport { KJUR as jsrsasign } from \"jsrsasign\";\nimport { v4 as uuid } from \"uuid\";\n\n/**\n * Generates a JWT token to authorize against. We do not use the implementation in\n * services-client since it cannot run in the browser without polyfills.\n */\nexport function generateToken(\n\ttenantId: string,\n\tdocumentId: string,\n\tkey: string,\n\tscopes: ScopeType[],\n\tuser?: IUser,\n\tlifetime: number = 60 * 60,\n\tver: string = \"1.0\",\n): string {\n\tlet userClaim = user ? user : generateUser();\n\tif (userClaim.id === \"\" || userClaim.id === undefined) {\n\t\tuserClaim = generateUser();\n\t}\n\n\t// Current time in seconds\n\tconst now = Math.round(new Date().getTime() / 1000);\n\n\tconst claims: ITokenClaims = {\n\t\tdocumentId,\n\t\tscopes,\n\t\ttenantId,\n\t\tuser: userClaim,\n\t\tiat: now,\n\t\texp: now + lifetime,\n\t\tver,\n\t};\n\n\tconst utf8Key = { utf8: key };\n\treturn jsrsasign.jws.JWS.sign(\n\t\tnull,\n\t\tJSON.stringify({ alg: \"HS256\", typ: \"JWT\" }),\n\t\tclaims,\n\t\tutf8Key,\n\t);\n}\n\nexport function generateUser(): IUser {\n\tconst userId = uuid();\n\tconst match = userId.match(/^([\\da-f]{8})-([\\da-f]{4})/);\n\tconst userName = match !== null ? match[0] : userId; // Just use the first two segments of the (fake) userId as a fake name.\n\n\tconst randomUser = {\n\t\tid: userId,\n\t\tname: userName,\n\t};\n\n\treturn randomUser;\n}\n"]}
@@ -5,20 +5,20 @@
5
5
  */
6
6
  Object.defineProperty(exports, "__esModule", { value: true });
7
7
  exports.LocalSessionStorageDbFactory = exports.LocalResolver = exports.createLocalResolverCreateNewRequest = exports.LocalDocumentStorageService = exports.LocalDocumentServiceFactory = exports.LocalDocumentService = exports.createLocalDocumentService = exports.LocalDocumentDeltaConnection = exports.LocalDeltaStorageService = void 0;
8
- var localDeltaStorageService_1 = require("./localDeltaStorageService");
8
+ var localDeltaStorageService_1 = require("./localDeltaStorageService.cjs");
9
9
  Object.defineProperty(exports, "LocalDeltaStorageService", { enumerable: true, get: function () { return localDeltaStorageService_1.LocalDeltaStorageService; } });
10
- var localDocumentDeltaConnection_1 = require("./localDocumentDeltaConnection");
10
+ var localDocumentDeltaConnection_1 = require("./localDocumentDeltaConnection.cjs");
11
11
  Object.defineProperty(exports, "LocalDocumentDeltaConnection", { enumerable: true, get: function () { return localDocumentDeltaConnection_1.LocalDocumentDeltaConnection; } });
12
- var localDocumentService_1 = require("./localDocumentService");
12
+ var localDocumentService_1 = require("./localDocumentService.cjs");
13
13
  Object.defineProperty(exports, "createLocalDocumentService", { enumerable: true, get: function () { return localDocumentService_1.createLocalDocumentService; } });
14
14
  Object.defineProperty(exports, "LocalDocumentService", { enumerable: true, get: function () { return localDocumentService_1.LocalDocumentService; } });
15
- var localDocumentServiceFactory_1 = require("./localDocumentServiceFactory");
15
+ var localDocumentServiceFactory_1 = require("./localDocumentServiceFactory.cjs");
16
16
  Object.defineProperty(exports, "LocalDocumentServiceFactory", { enumerable: true, get: function () { return localDocumentServiceFactory_1.LocalDocumentServiceFactory; } });
17
- var localDocumentStorageService_1 = require("./localDocumentStorageService");
17
+ var localDocumentStorageService_1 = require("./localDocumentStorageService.cjs");
18
18
  Object.defineProperty(exports, "LocalDocumentStorageService", { enumerable: true, get: function () { return localDocumentStorageService_1.LocalDocumentStorageService; } });
19
- var localResolver_1 = require("./localResolver");
19
+ var localResolver_1 = require("./localResolver.cjs");
20
20
  Object.defineProperty(exports, "createLocalResolverCreateNewRequest", { enumerable: true, get: function () { return localResolver_1.createLocalResolverCreateNewRequest; } });
21
21
  Object.defineProperty(exports, "LocalResolver", { enumerable: true, get: function () { return localResolver_1.LocalResolver; } });
22
- var localSessionStorageDb_1 = require("./localSessionStorageDb");
22
+ var localSessionStorageDb_1 = require("./localSessionStorageDb.cjs");
23
23
  Object.defineProperty(exports, "LocalSessionStorageDbFactory", { enumerable: true, get: function () { return localSessionStorageDb_1.LocalSessionStorageDbFactory; } });
24
- //# sourceMappingURL=index.js.map
24
+ //# sourceMappingURL=index.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;AAEH,2EAAsE;AAA7D,oIAAA,wBAAwB,OAAA;AACjC,mFAA8E;AAArE,4IAAA,4BAA4B,OAAA;AACrC,mEAA0F;AAAjF,kIAAA,0BAA0B,OAAA;AAAE,4HAAA,oBAAoB,OAAA;AACzD,iFAA4E;AAAnE,0IAAA,2BAA2B,OAAA;AACpC,iFAA4E;AAAnE,0IAAA,2BAA2B,OAAA;AACpC,qDAAqF;AAA5E,oIAAA,mCAAmC,OAAA;AAAE,8GAAA,aAAa,OAAA;AAC3D,qEAAuE;AAA9D,qIAAA,4BAA4B,OAAA","sourcesContent":["/*!\n * Copyright (c) Microsoft Corporation and contributors. All rights reserved.\n * Licensed under the MIT License.\n */\n\nexport { LocalDeltaStorageService } from \"./localDeltaStorageService\";\nexport { LocalDocumentDeltaConnection } from \"./localDocumentDeltaConnection\";\nexport { createLocalDocumentService, LocalDocumentService } from \"./localDocumentService\";\nexport { LocalDocumentServiceFactory } from \"./localDocumentServiceFactory\";\nexport { LocalDocumentStorageService } from \"./localDocumentStorageService\";\nexport { createLocalResolverCreateNewRequest, LocalResolver } from \"./localResolver\";\nexport { LocalSessionStorageDbFactory } from \"./localSessionStorageDb\";\n"]}
@@ -0,0 +1,108 @@
1
+ import { DocumentDeltaConnection } from '@fluidframework/driver-base';
2
+ import { GitManager } from '@fluidframework/server-services-client';
3
+ import { IClient } from '@fluidframework/protocol-definitions';
4
+ import { ICreateBlobResponse } from '@fluidframework/protocol-definitions';
5
+ import { IDatabaseManager } from '@fluidframework/server-services-core';
6
+ import { IDb } from '@fluidframework/server-services-core';
7
+ import { IDocumentDeltaConnection } from '@fluidframework/driver-definitions';
8
+ import { IDocumentDeltaStorageService } from '@fluidframework/driver-definitions';
9
+ import { IDocumentMessage } from '@fluidframework/protocol-definitions';
10
+ import { IDocumentService } from '@fluidframework/driver-definitions';
11
+ import { IDocumentServiceFactory } from '@fluidframework/driver-definitions';
12
+ import { IDocumentServicePolicies } from '@fluidframework/driver-definitions';
13
+ import { IDocumentStorageService } from '@fluidframework/driver-definitions';
14
+ import { IDocumentStorageServicePolicies } from '@fluidframework/driver-definitions';
15
+ import { ILocalDeltaConnectionServer } from '@fluidframework/server-local-server';
16
+ import { IRequest } from '@fluidframework/core-interfaces';
17
+ import { IResolvedUrl } from '@fluidframework/driver-definitions';
18
+ import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
19
+ import { ISnapshotTreeEx } from '@fluidframework/protocol-definitions';
20
+ import { IStream } from '@fluidframework/driver-definitions';
21
+ import { ISummaryContext } from '@fluidframework/driver-definitions';
22
+ import { ISummaryHandle } from '@fluidframework/protocol-definitions';
23
+ import { ISummaryTree } from '@fluidframework/protocol-definitions';
24
+ import { ITelemetryBaseLogger } from '@fluidframework/core-interfaces';
25
+ import { ITestDbFactory } from '@fluidframework/server-test-utils';
26
+ import { ITokenProvider } from '@fluidframework/routerlicious-driver';
27
+ import { IUrlResolver } from '@fluidframework/driver-definitions';
28
+ import { IVersion } from '@fluidframework/protocol-definitions';
29
+ import { IWebSocketServer } from '@fluidframework/server-services-core';
30
+ import { NackErrorType } from '@fluidframework/protocol-definitions';
31
+ import type { Socket } from 'socket.io-client';
32
+
33
+ /* Excluded from this release type: createLocalDocumentService */
34
+
35
+ /**
36
+ * @alpha
37
+ */
38
+ export declare function createLocalResolverCreateNewRequest(documentId: string): IRequest;
39
+
40
+ /* Excluded from this release type: DocumentDeltaConnection */
41
+
42
+ /* Excluded from this release type: LocalDeltaStorageService */
43
+
44
+ /* Excluded from this release type: LocalDocumentDeltaConnection */
45
+
46
+ /* Excluded from this release type: LocalDocumentService */
47
+
48
+ /**
49
+ * Implementation of document service factory for local use.
50
+ * @alpha
51
+ */
52
+ export declare class LocalDocumentServiceFactory implements IDocumentServiceFactory {
53
+ private readonly localDeltaConnectionServer;
54
+ private readonly policies?;
55
+ private readonly innerDocumentService?;
56
+ private readonly documentDeltaConnectionsMap;
57
+ /**
58
+ * @param localDeltaConnectionServer - delta connection server for ops
59
+ */
60
+ constructor(localDeltaConnectionServer: ILocalDeltaConnectionServer, policies?: IDocumentServicePolicies | undefined, innerDocumentService?: IDocumentService | undefined);
61
+ createContainer(createNewSummary: ISummaryTree | undefined, resolvedUrl: IResolvedUrl, logger?: ITelemetryBaseLogger, clientIsSummarizer?: boolean): Promise<IDocumentService>;
62
+ /**
63
+ * Creates and returns a document service for testing using the given resolved
64
+ * URL for the tenant ID, document ID, and token.
65
+ * @param resolvedUrl - resolved URL of document
66
+ */
67
+ createDocumentService(resolvedUrl: IResolvedUrl, logger?: ITelemetryBaseLogger, clientIsSummarizer?: boolean): Promise<IDocumentService>;
68
+ /**
69
+ * Gets the document delta connection for the clientId and asks it to disconnect the client.
70
+ * @param clientId - The ID of the client to be disconnected.
71
+ * @param disconnectReason - The reason of the disconnection.
72
+ */
73
+ disconnectClient(clientId: string, disconnectReason: string): void;
74
+ /**
75
+ * Gets the document delta connection for the clientId and asks it to nack the client.
76
+ * @param clientId - The ID of the client to be Nack'd.
77
+ * @param code - An error code number that represents the error. It will be a valid HTTP error code.
78
+ * @param type - Type of the Nack.
79
+ * @param message - A message about the nack for debugging/logging/telemetry purposes.
80
+ */
81
+ nackClient(clientId: string, code?: number, type?: NackErrorType, message?: any): void;
82
+ }
83
+
84
+ /* Excluded from this release type: LocalDocumentStorageService */
85
+
86
+ /**
87
+ * Resolves URLs by providing fake URLs which succeed with the other
88
+ * related local classes.
89
+ * @alpha
90
+ */
91
+ export declare class LocalResolver implements IUrlResolver {
92
+ private readonly tenantId;
93
+ private readonly tokenKey;
94
+ constructor();
95
+ /**
96
+ * Resolves URL requests by providing fake URLs with an actually generated
97
+ * token from constant test strings. The root of the URL is fake, but the
98
+ * remaining relative URL can still be parsed.
99
+ * @param request - request to handle
100
+ */
101
+ resolve(request: IRequest): Promise<IResolvedUrl>;
102
+ getAbsoluteUrl(resolvedUrl: IResolvedUrl, relativeUrl: string): Promise<string>;
103
+ createCreateNewRequest(documentId: string): IRequest;
104
+ }
105
+
106
+ /* Excluded from this release type: LocalSessionStorageDbFactory */
107
+
108
+ export { }
@@ -0,0 +1,81 @@
1
+ import { DocumentDeltaConnection } from '@fluidframework/driver-base';
2
+ import { GitManager } from '@fluidframework/server-services-client';
3
+ import { IClient } from '@fluidframework/protocol-definitions';
4
+ import { ICreateBlobResponse } from '@fluidframework/protocol-definitions';
5
+ import { IDatabaseManager } from '@fluidframework/server-services-core';
6
+ import { IDb } from '@fluidframework/server-services-core';
7
+ import { IDocumentDeltaConnection } from '@fluidframework/driver-definitions';
8
+ import { IDocumentDeltaStorageService } from '@fluidframework/driver-definitions';
9
+ import { IDocumentMessage } from '@fluidframework/protocol-definitions';
10
+ import { IDocumentService } from '@fluidframework/driver-definitions';
11
+ import { IDocumentServiceFactory } from '@fluidframework/driver-definitions';
12
+ import { IDocumentServicePolicies } from '@fluidframework/driver-definitions';
13
+ import { IDocumentStorageService } from '@fluidframework/driver-definitions';
14
+ import { IDocumentStorageServicePolicies } from '@fluidframework/driver-definitions';
15
+ import { ILocalDeltaConnectionServer } from '@fluidframework/server-local-server';
16
+ import { IRequest } from '@fluidframework/core-interfaces';
17
+ import { IResolvedUrl } from '@fluidframework/driver-definitions';
18
+ import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
19
+ import { ISnapshotTreeEx } from '@fluidframework/protocol-definitions';
20
+ import { IStream } from '@fluidframework/driver-definitions';
21
+ import { ISummaryContext } from '@fluidframework/driver-definitions';
22
+ import { ISummaryHandle } from '@fluidframework/protocol-definitions';
23
+ import { ISummaryTree } from '@fluidframework/protocol-definitions';
24
+ import { ITelemetryBaseLogger } from '@fluidframework/core-interfaces';
25
+ import { ITestDbFactory } from '@fluidframework/server-test-utils';
26
+ import { ITokenProvider } from '@fluidframework/routerlicious-driver';
27
+ import { IUrlResolver } from '@fluidframework/driver-definitions';
28
+ import { IVersion } from '@fluidframework/protocol-definitions';
29
+ import { IWebSocketServer } from '@fluidframework/server-services-core';
30
+ import { NackErrorType } from '@fluidframework/protocol-definitions';
31
+ import type { Socket } from 'socket.io-client';
32
+
33
+ /* Excluded from this release type: createLocalDocumentService */
34
+
35
+ /* Excluded from this release type: createLocalResolverCreateNewRequest */
36
+
37
+ /* Excluded from this release type: DocumentDeltaConnection */
38
+
39
+ /* Excluded from this release type: IDocumentDeltaConnection */
40
+
41
+ /* Excluded from this release type: IDocumentDeltaStorageService */
42
+
43
+ /* Excluded from this release type: IDocumentService */
44
+
45
+ /* Excluded from this release type: IDocumentServiceFactory */
46
+
47
+ /* Excluded from this release type: IDocumentServicePolicies */
48
+
49
+ /* Excluded from this release type: IDocumentStorageService */
50
+
51
+ /* Excluded from this release type: IDocumentStorageServicePolicies */
52
+
53
+ /* Excluded from this release type: IRequest */
54
+
55
+ /* Excluded from this release type: IResolvedUrl */
56
+
57
+ /* Excluded from this release type: IStream */
58
+
59
+ /* Excluded from this release type: ISummaryContext */
60
+
61
+ /* Excluded from this release type: ITelemetryBaseLogger */
62
+
63
+ /* Excluded from this release type: ITokenProvider */
64
+
65
+ /* Excluded from this release type: IUrlResolver */
66
+
67
+ /* Excluded from this release type: LocalDeltaStorageService */
68
+
69
+ /* Excluded from this release type: LocalDocumentDeltaConnection */
70
+
71
+ /* Excluded from this release type: LocalDocumentService */
72
+
73
+ /* Excluded from this release type: LocalDocumentServiceFactory */
74
+
75
+ /* Excluded from this release type: LocalDocumentStorageService */
76
+
77
+ /* Excluded from this release type: LocalResolver */
78
+
79
+ /* Excluded from this release type: LocalSessionStorageDbFactory */
80
+
81
+ export { }
@@ -0,0 +1,81 @@
1
+ import { DocumentDeltaConnection } from '@fluidframework/driver-base';
2
+ import { GitManager } from '@fluidframework/server-services-client';
3
+ import { IClient } from '@fluidframework/protocol-definitions';
4
+ import { ICreateBlobResponse } from '@fluidframework/protocol-definitions';
5
+ import { IDatabaseManager } from '@fluidframework/server-services-core';
6
+ import { IDb } from '@fluidframework/server-services-core';
7
+ import { IDocumentDeltaConnection } from '@fluidframework/driver-definitions';
8
+ import { IDocumentDeltaStorageService } from '@fluidframework/driver-definitions';
9
+ import { IDocumentMessage } from '@fluidframework/protocol-definitions';
10
+ import { IDocumentService } from '@fluidframework/driver-definitions';
11
+ import { IDocumentServiceFactory } from '@fluidframework/driver-definitions';
12
+ import { IDocumentServicePolicies } from '@fluidframework/driver-definitions';
13
+ import { IDocumentStorageService } from '@fluidframework/driver-definitions';
14
+ import { IDocumentStorageServicePolicies } from '@fluidframework/driver-definitions';
15
+ import { ILocalDeltaConnectionServer } from '@fluidframework/server-local-server';
16
+ import { IRequest } from '@fluidframework/core-interfaces';
17
+ import { IResolvedUrl } from '@fluidframework/driver-definitions';
18
+ import { ISequencedDocumentMessage } from '@fluidframework/protocol-definitions';
19
+ import { ISnapshotTreeEx } from '@fluidframework/protocol-definitions';
20
+ import { IStream } from '@fluidframework/driver-definitions';
21
+ import { ISummaryContext } from '@fluidframework/driver-definitions';
22
+ import { ISummaryHandle } from '@fluidframework/protocol-definitions';
23
+ import { ISummaryTree } from '@fluidframework/protocol-definitions';
24
+ import { ITelemetryBaseLogger } from '@fluidframework/core-interfaces';
25
+ import { ITestDbFactory } from '@fluidframework/server-test-utils';
26
+ import { ITokenProvider } from '@fluidframework/routerlicious-driver';
27
+ import { IUrlResolver } from '@fluidframework/driver-definitions';
28
+ import { IVersion } from '@fluidframework/protocol-definitions';
29
+ import { IWebSocketServer } from '@fluidframework/server-services-core';
30
+ import { NackErrorType } from '@fluidframework/protocol-definitions';
31
+ import type { Socket } from 'socket.io-client';
32
+
33
+ /* Excluded from this release type: createLocalDocumentService */
34
+
35
+ /* Excluded from this release type: createLocalResolverCreateNewRequest */
36
+
37
+ /* Excluded from this release type: DocumentDeltaConnection */
38
+
39
+ /* Excluded from this release type: IDocumentDeltaConnection */
40
+
41
+ /* Excluded from this release type: IDocumentDeltaStorageService */
42
+
43
+ /* Excluded from this release type: IDocumentService */
44
+
45
+ /* Excluded from this release type: IDocumentServiceFactory */
46
+
47
+ /* Excluded from this release type: IDocumentServicePolicies */
48
+
49
+ /* Excluded from this release type: IDocumentStorageService */
50
+
51
+ /* Excluded from this release type: IDocumentStorageServicePolicies */
52
+
53
+ /* Excluded from this release type: IRequest */
54
+
55
+ /* Excluded from this release type: IResolvedUrl */
56
+
57
+ /* Excluded from this release type: IStream */
58
+
59
+ /* Excluded from this release type: ISummaryContext */
60
+
61
+ /* Excluded from this release type: ITelemetryBaseLogger */
62
+
63
+ /* Excluded from this release type: ITokenProvider */
64
+
65
+ /* Excluded from this release type: IUrlResolver */
66
+
67
+ /* Excluded from this release type: LocalDeltaStorageService */
68
+
69
+ /* Excluded from this release type: LocalDocumentDeltaConnection */
70
+
71
+ /* Excluded from this release type: LocalDocumentService */
72
+
73
+ /* Excluded from this release type: LocalDocumentServiceFactory */
74
+
75
+ /* Excluded from this release type: LocalDocumentStorageService */
76
+
77
+ /* Excluded from this release type: LocalResolver */
78
+
79
+ /* Excluded from this release type: LocalSessionStorageDbFactory */
80
+
81
+ export { }