@dxos/client-services 0.6.3-main.9e4e207 → 0.6.3-main.b88405e

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.
@@ -30,7 +30,7 @@ __export(testing_exports, {
30
30
  sanitizeInvitation: () => sanitizeInvitation
31
31
  });
32
32
  module.exports = __toCommonJS(testing_exports);
33
- var import_chunk_MMUSO27N = require("../../chunk-MMUSO27N.cjs");
33
+ var import_chunk_5M2VEOKD = require("../../chunk-5M2VEOKD.cjs");
34
34
  var import_credentials = require("@dxos/credentials");
35
35
  var import_keys = require("@dxos/keys");
36
36
  var import_async = require("@dxos/async");
@@ -227,7 +227,7 @@ var createInvitation = async (host, options) => {
227
227
  authMethod: import_services.Invitation.AuthMethod.NONE,
228
228
  ...options ?? {}
229
229
  };
230
- if (host instanceof import_chunk_MMUSO27N.ServiceContext) {
230
+ if (host instanceof import_chunk_5M2VEOKD.ServiceContext) {
231
231
  return host.invitationsManager.createInvitation({
232
232
  kind: import_services.Invitation.Kind.SPACE,
233
233
  ...options
@@ -237,7 +237,7 @@ var createInvitation = async (host, options) => {
237
237
  };
238
238
  var acceptInvitation = (guest, invitation, guestDeviceProfile) => {
239
239
  invitation = sanitizeInvitation(invitation);
240
- if (guest instanceof import_chunk_MMUSO27N.ServiceContext) {
240
+ if (guest instanceof import_chunk_5M2VEOKD.ServiceContext) {
241
241
  return guest.invitationsManager.acceptInvitation({
242
242
  invitation,
243
243
  deviceProfile: guestDeviceProfile
@@ -247,7 +247,7 @@ var acceptInvitation = (guest, invitation, guestDeviceProfile) => {
247
247
  };
248
248
  var __dxlog_file2 = "/home/runner/work/dxos/dxos/packages/sdk/client-services/src/packlets/testing/test-builder.ts";
249
249
  var createServiceHost = (config, signalManagerContext) => {
250
- return new import_chunk_MMUSO27N.ClientServicesHost({
250
+ return new import_chunk_5M2VEOKD.ClientServicesHost({
251
251
  config,
252
252
  signalManager: new import_messaging.MemorySignalManager(signalManagerContext),
253
253
  transportFactory: import_network_manager.MemoryTransportFactory
@@ -263,7 +263,7 @@ var createServiceContext = async ({ signalContext = new import_messaging.MemoryS
263
263
  });
264
264
  const level = (0, import_testing.createTestLevel)();
265
265
  await level.open();
266
- return new import_chunk_MMUSO27N.ServiceContext(storage, level, networkManager, signalManager, {
266
+ return new import_chunk_5M2VEOKD.ServiceContext(storage, level, networkManager, signalManager, {
267
267
  invitationConnectionDefaultParams: {
268
268
  controlHeartbeatInterval: 200
269
269
  },
@@ -370,12 +370,12 @@ var TestPeer = class {
370
370
  });
371
371
  }
372
372
  get dataSpaceManager() {
373
- return this._props.dataSpaceManager ??= new import_chunk_MMUSO27N.DataSpaceManager(this.spaceManager, this.metadataStore, this.keyring, this.identity, this.feedStore, this.echoHost, this.invitationsManager, this._opts.dataSpaceParams);
373
+ return this._props.dataSpaceManager ??= new import_chunk_5M2VEOKD.DataSpaceManager(this.spaceManager, this.metadataStore, this.keyring, this.identity, this.feedStore, this.echoHost, this.invitationsManager, this._opts.dataSpaceParams);
374
374
  }
375
375
  get invitationsManager() {
376
- return this._props.invitationsManager ??= new import_chunk_MMUSO27N.InvitationsManager(new import_chunk_MMUSO27N.InvitationsHandler(this.networkManager), (invitation) => {
376
+ return this._props.invitationsManager ??= new import_chunk_5M2VEOKD.InvitationsManager(new import_chunk_5M2VEOKD.InvitationsHandler(this.networkManager), (invitation) => {
377
377
  if (invitation.kind === import_services2.Invitation.Kind.SPACE) {
378
- return new import_chunk_MMUSO27N.SpaceInvitationProtocol(this.dataSpaceManager, this.identity, this.keyring, invitation.spaceKey);
378
+ return new import_chunk_5M2VEOKD.SpaceInvitationProtocol(this.dataSpaceManager, this.identity, this.keyring, invitation.spaceKey);
379
379
  } else {
380
380
  throw new Error("not implemented");
381
381
  }
@@ -1,2 +1,2 @@
1
- export declare const DXOS_VERSION = "0.6.3-main.9e4e207";
1
+ export declare const DXOS_VERSION = "0.6.3-main.b88405e";
2
2
  //# sourceMappingURL=version.d.ts.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/client-services",
3
- "version": "0.6.3-main.9e4e207",
3
+ "version": "0.6.3-main.b88405e",
4
4
  "description": "DXOS client services implementation",
5
5
  "homepage": "https://dxos.org",
6
6
  "bugs": "https://github.com/dxos/dxos/issues",
@@ -23,45 +23,45 @@
23
23
  ],
24
24
  "dependencies": {
25
25
  "platform": "^1.3.6",
26
- "@dxos/async": "0.6.3-main.9e4e207",
27
- "@dxos/client-protocol": "0.6.3-main.9e4e207",
28
- "@dxos/context": "0.6.3-main.9e4e207",
29
- "@dxos/codec-protobuf": "0.6.3-main.9e4e207",
30
- "@dxos/automerge": "0.6.3-main.9e4e207",
31
- "@dxos/config": "0.6.3-main.9e4e207",
32
- "@dxos/credentials": "0.6.3-main.9e4e207",
33
- "@dxos/crypto": "0.6.3-main.9e4e207",
34
- "@dxos/debug": "0.6.3-main.9e4e207",
35
- "@dxos/echo-db": "0.6.3-main.9e4e207",
36
- "@dxos/echo-protocol": "0.6.3-main.9e4e207",
37
- "@dxos/echo-pipeline": "0.6.3-main.9e4e207",
38
- "@dxos/echo-schema": "0.6.3-main.9e4e207",
39
- "@dxos/feed-store": "0.6.3-main.9e4e207",
40
- "@dxos/indexing": "0.6.3-main.9e4e207",
41
- "@dxos/invariant": "0.6.3-main.9e4e207",
42
- "@dxos/keyring": "0.6.3-main.9e4e207",
43
- "@dxos/keys": "0.6.3-main.9e4e207",
44
- "@dxos/kv-store": "0.6.3-main.9e4e207",
45
- "@dxos/messaging": "0.6.3-main.9e4e207",
46
- "@dxos/lock-file": "0.6.3-main.9e4e207",
47
- "@dxos/log": "0.6.3-main.9e4e207",
48
- "@dxos/network-manager": "0.6.3-main.9e4e207",
49
- "@dxos/node-std": "0.6.3-main.9e4e207",
50
- "@dxos/protocols": "0.6.3-main.9e4e207",
51
- "@dxos/random-access-storage": "0.6.3-main.9e4e207",
52
- "@dxos/rpc": "0.6.3-main.9e4e207",
53
- "@dxos/teleport": "0.6.3-main.9e4e207",
54
- "@dxos/teleport-extension-gossip": "0.6.3-main.9e4e207",
55
- "@dxos/teleport-extension-object-sync": "0.6.3-main.9e4e207",
56
- "@dxos/timeframe": "0.6.3-main.9e4e207",
57
- "@dxos/util": "0.6.3-main.9e4e207",
58
- "@dxos/websocket-rpc": "0.6.3-main.9e4e207",
59
- "@dxos/tracing": "0.6.3-main.9e4e207"
26
+ "@dxos/async": "0.6.3-main.b88405e",
27
+ "@dxos/client-protocol": "0.6.3-main.b88405e",
28
+ "@dxos/automerge": "0.6.3-main.b88405e",
29
+ "@dxos/codec-protobuf": "0.6.3-main.b88405e",
30
+ "@dxos/config": "0.6.3-main.b88405e",
31
+ "@dxos/context": "0.6.3-main.b88405e",
32
+ "@dxos/credentials": "0.6.3-main.b88405e",
33
+ "@dxos/crypto": "0.6.3-main.b88405e",
34
+ "@dxos/echo-db": "0.6.3-main.b88405e",
35
+ "@dxos/debug": "0.6.3-main.b88405e",
36
+ "@dxos/echo-pipeline": "0.6.3-main.b88405e",
37
+ "@dxos/echo-schema": "0.6.3-main.b88405e",
38
+ "@dxos/feed-store": "0.6.3-main.b88405e",
39
+ "@dxos/echo-protocol": "0.6.3-main.b88405e",
40
+ "@dxos/indexing": "0.6.3-main.b88405e",
41
+ "@dxos/keys": "0.6.3-main.b88405e",
42
+ "@dxos/invariant": "0.6.3-main.b88405e",
43
+ "@dxos/keyring": "0.6.3-main.b88405e",
44
+ "@dxos/kv-store": "0.6.3-main.b88405e",
45
+ "@dxos/lock-file": "0.6.3-main.b88405e",
46
+ "@dxos/log": "0.6.3-main.b88405e",
47
+ "@dxos/messaging": "0.6.3-main.b88405e",
48
+ "@dxos/node-std": "0.6.3-main.b88405e",
49
+ "@dxos/network-manager": "0.6.3-main.b88405e",
50
+ "@dxos/protocols": "0.6.3-main.b88405e",
51
+ "@dxos/random-access-storage": "0.6.3-main.b88405e",
52
+ "@dxos/rpc": "0.6.3-main.b88405e",
53
+ "@dxos/teleport": "0.6.3-main.b88405e",
54
+ "@dxos/teleport-extension-object-sync": "0.6.3-main.b88405e",
55
+ "@dxos/teleport-extension-gossip": "0.6.3-main.b88405e",
56
+ "@dxos/timeframe": "0.6.3-main.b88405e",
57
+ "@dxos/util": "0.6.3-main.b88405e",
58
+ "@dxos/tracing": "0.6.3-main.b88405e",
59
+ "@dxos/websocket-rpc": "0.6.3-main.b88405e"
60
60
  },
61
61
  "devDependencies": {
62
62
  "@types/platform": "^1.3.4",
63
63
  "@types/readable-stream": "^2.3.9",
64
- "@dxos/signal": "0.6.3-main.9e4e207"
64
+ "@dxos/signal": "0.6.3-main.b88405e"
65
65
  },
66
66
  "publishConfig": {
67
67
  "access": "public"
@@ -73,7 +73,7 @@ export class InvitationsHandler {
73
73
  protocol: InvitationProtocol,
74
74
  invitation: Invitation,
75
75
  ): void {
76
- metrics.increment('invitation.created');
76
+ metrics.increment('dxos.invitation.created');
77
77
  const guardedState = this._createGuardedState(ctx, invitation, stream);
78
78
  // Called for every connecting peer.
79
79
  const createExtension = (): InvitationHostExtension => {
@@ -120,7 +120,7 @@ export class InvitationsHandler {
120
120
  const deviceKey = await extension.completedTrigger.wait({ timeout: invitation.timeout });
121
121
  log('admitted guest', { guest: deviceKey, ...protocol.toJSON() });
122
122
  guardedState.set(extension, Invitation.State.SUCCESS);
123
- metrics.increment('invitation.success');
123
+ metrics.increment('dxos.invitation.success');
124
124
  log.trace('dxos.sdk.invitations-handler.host.onOpen', trace.end({ id: traceId }));
125
125
  admitted = true;
126
126
 
@@ -130,12 +130,12 @@ export class InvitationsHandler {
130
130
  } catch (err: any) {
131
131
  if (err instanceof TimeoutError) {
132
132
  if (guardedState.set(extension, Invitation.State.TIMEOUT)) {
133
- metrics.increment('invitation.timeout');
133
+ metrics.increment('dxos.invitation.timeout');
134
134
  log('timeout', { ...protocol.toJSON() });
135
135
  }
136
136
  } else {
137
137
  if (guardedState.error(extension, err)) {
138
- metrics.increment('invitation.failed');
138
+ metrics.increment('dxos.invitation.failed');
139
139
  log.error('failed', err);
140
140
  }
141
141
  }
@@ -152,12 +152,12 @@ export class InvitationsHandler {
152
152
  }
153
153
  if (err instanceof TimeoutError) {
154
154
  if (guardedState.set(extension, Invitation.State.TIMEOUT)) {
155
- metrics.increment('invitation.timeout');
155
+ metrics.increment('dxos.invitation.timeout');
156
156
  log('timeout', { err });
157
157
  }
158
158
  } else {
159
159
  if (guardedState.error(extension, err)) {
160
- metrics.increment('invitation.failed');
160
+ metrics.increment('dxos.invitation.failed');
161
161
  log.error('failed', err);
162
162
  }
163
163
  }
@@ -177,7 +177,7 @@ export class InvitationsHandler {
177
177
  // ensure the swarm is closed before changing state and closing the stream.
178
178
  await swarmConnection.close();
179
179
  guardedState.set(null, Invitation.State.EXPIRED);
180
- metrics.increment('invitation.expired');
180
+ metrics.increment('dxos.invitation.expired');
181
181
  await ctx.dispose();
182
182
  },
183
183
  invitation.created.getTime() + invitation.lifetime * 1000 - Date.now(),
@@ -324,7 +324,7 @@ export class SpacesServiceImpl implements SpacesService {
324
324
  const dataSpaceManager = await this._getDataSpaceManager();
325
325
  const identity = this._identityManager.identity?.identityKey.truncate();
326
326
  if (identity) {
327
- trace.metrics.gauge('echo.space.count', dataSpaceManager.spaces.size, {
327
+ trace.metrics.gauge('dxos.echo.space.count', dataSpaceManager.spaces.size, {
328
328
  tags: { identity },
329
329
  });
330
330
  }
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const DXOS_VERSION = "0.6.3-main.9e4e207";
1
+ export const DXOS_VERSION = "0.6.3-main.b88405e";