@dxos/client-services 0.7.2 → 0.7.3-main.2dd075e
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/dist/lib/browser/{chunk-K5O5LV2R.mjs → chunk-5GKWY67F.mjs} +340 -422
- package/dist/lib/browser/chunk-5GKWY67F.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +1 -1
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/testing/index.mjs +1 -1
- package/dist/lib/node/{chunk-SPLKKUM4.cjs → chunk-RVO5327U.cjs} +329 -411
- package/dist/lib/node/chunk-RVO5327U.cjs.map +7 -0
- package/dist/lib/node/index.cjs +47 -47
- package/dist/lib/node/meta.json +1 -1
- package/dist/lib/node/testing/index.cjs +8 -8
- package/dist/lib/node-esm/{chunk-NSCBFSXO.mjs → chunk-LMUKPYXE.mjs} +334 -416
- package/dist/lib/node-esm/chunk-LMUKPYXE.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +1 -1
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/testing/index.mjs +1 -1
- package/dist/types/src/packlets/agents/edge-agent-service.d.ts +5 -2
- package/dist/types/src/packlets/agents/edge-agent-service.d.ts.map +1 -1
- package/dist/types/src/packlets/identity/identity-service.d.ts +1 -0
- package/dist/types/src/packlets/identity/identity-service.d.ts.map +1 -1
- package/dist/types/src/packlets/services/service-context.d.ts.map +1 -1
- package/dist/types/src/packlets/spaces/data-space-manager.d.ts.map +1 -1
- package/dist/types/src/packlets/spaces/epoch-migrations.d.ts.map +1 -1
- package/dist/types/src/version.d.ts +1 -1
- package/dist/types/src/version.d.ts.map +1 -1
- package/package.json +38 -38
- package/src/packlets/agents/edge-agent-service.ts +28 -3
- package/src/packlets/identity/identity-service.ts +16 -1
- package/src/packlets/services/service-context.ts +4 -1
- package/src/packlets/services/service-host.ts +1 -1
- package/src/packlets/spaces/data-space-manager.ts +4 -13
- package/src/packlets/spaces/epoch-migrations.ts +3 -84
- package/src/version.ts +1 -5
- package/dist/lib/browser/chunk-K5O5LV2R.mjs.map +0 -7
- package/dist/lib/node/chunk-SPLKKUM4.cjs.map +0 -7
- package/dist/lib/node-esm/chunk-NSCBFSXO.mjs.map +0 -7
|
@@ -32,7 +32,7 @@ __export(testing_exports, {
|
|
|
32
32
|
sanitizeInvitation: () => sanitizeInvitation
|
|
33
33
|
});
|
|
34
34
|
module.exports = __toCommonJS(testing_exports);
|
|
35
|
-
var
|
|
35
|
+
var import_chunk_RVO5327U = require("../chunk-RVO5327U.cjs");
|
|
36
36
|
var import_credentials = require("@dxos/credentials");
|
|
37
37
|
var import_keys = require("@dxos/keys");
|
|
38
38
|
var import_async = require("@dxos/async");
|
|
@@ -235,7 +235,7 @@ var createInvitation = async (host, options) => {
|
|
|
235
235
|
authMethod: import_services.Invitation.AuthMethod.NONE,
|
|
236
236
|
...options ?? {}
|
|
237
237
|
};
|
|
238
|
-
if (host instanceof
|
|
238
|
+
if (host instanceof import_chunk_RVO5327U.ServiceContext) {
|
|
239
239
|
return host.invitationsManager.createInvitation({
|
|
240
240
|
kind: import_services.Invitation.Kind.SPACE,
|
|
241
241
|
...options
|
|
@@ -245,7 +245,7 @@ var createInvitation = async (host, options) => {
|
|
|
245
245
|
};
|
|
246
246
|
var acceptInvitation = (guest, invitation, guestDeviceProfile) => {
|
|
247
247
|
invitation = sanitizeInvitation(invitation);
|
|
248
|
-
if (guest instanceof
|
|
248
|
+
if (guest instanceof import_chunk_RVO5327U.ServiceContext) {
|
|
249
249
|
return guest.invitationsManager.acceptInvitation({
|
|
250
250
|
invitation,
|
|
251
251
|
deviceProfile: guestDeviceProfile
|
|
@@ -255,7 +255,7 @@ var acceptInvitation = (guest, invitation, guestDeviceProfile) => {
|
|
|
255
255
|
};
|
|
256
256
|
var __dxlog_file2 = "/home/runner/work/dxos/dxos/packages/sdk/client-services/src/packlets/testing/test-builder.ts";
|
|
257
257
|
var createServiceHost = (config, signalManagerContext) => {
|
|
258
|
-
return new
|
|
258
|
+
return new import_chunk_RVO5327U.ClientServicesHost({
|
|
259
259
|
config,
|
|
260
260
|
signalManager: new import_messaging.MemorySignalManager(signalManagerContext),
|
|
261
261
|
transportFactory: import_network_manager.MemoryTransportFactory
|
|
@@ -274,7 +274,7 @@ var createServiceContext = async ({ signalManagerFactory = async () => {
|
|
|
274
274
|
});
|
|
275
275
|
const level = (0, import_testing.createTestLevel)();
|
|
276
276
|
await level.open();
|
|
277
|
-
return new
|
|
277
|
+
return new import_chunk_RVO5327U.ServiceContext(storage, level, networkManager, signalManager, void 0, void 0, {
|
|
278
278
|
invitationConnectionDefaultParams: {
|
|
279
279
|
teleport: {
|
|
280
280
|
controlHeartbeatInterval: 200
|
|
@@ -385,7 +385,7 @@ var TestPeer = class {
|
|
|
385
385
|
return this._props.meshEchoReplicator ??= new import_echo_pipeline.MeshEchoReplicator();
|
|
386
386
|
}
|
|
387
387
|
get dataSpaceManager() {
|
|
388
|
-
return this._props.dataSpaceManager ??= new
|
|
388
|
+
return this._props.dataSpaceManager ??= new import_chunk_RVO5327U.DataSpaceManager({
|
|
389
389
|
spaceManager: this.spaceManager,
|
|
390
390
|
metadataStore: this.metadataStore,
|
|
391
391
|
keyring: this.keyring,
|
|
@@ -400,9 +400,9 @@ var TestPeer = class {
|
|
|
400
400
|
});
|
|
401
401
|
}
|
|
402
402
|
get invitationsManager() {
|
|
403
|
-
return this._props.invitationsManager ??= new
|
|
403
|
+
return this._props.invitationsManager ??= new import_chunk_RVO5327U.InvitationsManager(new import_chunk_RVO5327U.InvitationsHandler(this.networkManager), (invitation) => {
|
|
404
404
|
if (invitation.kind === import_services2.Invitation.Kind.SPACE) {
|
|
405
|
-
return new
|
|
405
|
+
return new import_chunk_RVO5327U.SpaceInvitationProtocol(this.dataSpaceManager, this.identity, this.keyring, invitation.spaceKey);
|
|
406
406
|
} else {
|
|
407
407
|
throw new Error("not implemented");
|
|
408
408
|
}
|