@dxos/client-services 0.3.3-main.44bdbf7 → 0.3.3-main.619fab4

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.
@@ -2489,21 +2489,9 @@ var SpaceInvitationProtocol = class {
2489
2489
  var import_codec_protobuf9 = require("@dxos/codec-protobuf");
2490
2490
  var import_debug3 = require("@dxos/debug");
2491
2491
  var import_rpc = require("@dxos/rpc");
2492
- var import_tracing3 = require("@dxos/tracing");
2493
- function _ts_decorate3(decorators, target, key, desc) {
2494
- var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2495
- if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
2496
- r = Reflect.decorate(decorators, target, key, desc);
2497
- else
2498
- for (var i = decorators.length - 1; i >= 0; i--)
2499
- if (d = decorators[i])
2500
- r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2501
- return c > 3 && r && Object.defineProperty(target, key, r), r;
2502
- }
2503
- var ClientRpcServer = class ClientRpcServer2 {
2492
+ var ClientRpcServer = class {
2504
2493
  constructor(params) {
2505
2494
  this._handlerCache = /* @__PURE__ */ new Map();
2506
- this._callMetrics = new import_tracing3.MapCounter();
2507
2495
  const { serviceRegistry, handleCall, handleStream, ...rpcOptions } = params;
2508
2496
  this._handleCall = handleCall;
2509
2497
  this._handleStream = handleStream;
@@ -2513,7 +2501,6 @@ var ClientRpcServer = class ClientRpcServer2 {
2513
2501
  callHandler: (method, params2) => {
2514
2502
  const [serviceName, methodName] = (0, import_rpc.parseMethodName)(method);
2515
2503
  const handler = (method2, params3) => this._getServiceHandler(serviceName).call(method2, params3);
2516
- this._callMetrics.inc(`${serviceName}.${methodName} request`);
2517
2504
  if (this._handleCall) {
2518
2505
  return this._handleCall(methodName, params2, handler);
2519
2506
  } else {
@@ -2523,21 +2510,14 @@ var ClientRpcServer = class ClientRpcServer2 {
2523
2510
  streamHandler: (method, params2) => {
2524
2511
  const [serviceName, methodName] = (0, import_rpc.parseMethodName)(method);
2525
2512
  const handler = (method2, params3) => this._getServiceHandler(serviceName).callStream(method2, params3);
2526
- this._callMetrics.inc(`${serviceName}.${methodName} request stream`);
2527
2513
  if (this._handleStream) {
2528
- return import_codec_protobuf9.Stream.map(import_codec_protobuf9.Stream.unwrapPromise(this._handleStream(methodName, params2, handler)), (data) => {
2529
- this._callMetrics.inc(`${serviceName}.${methodName} response stream`);
2530
- return data;
2531
- });
2514
+ return import_codec_protobuf9.Stream.unwrapPromise(this._handleStream(methodName, params2, handler));
2532
2515
  } else {
2533
2516
  return handler(methodName, params2);
2534
2517
  }
2535
2518
  }
2536
2519
  });
2537
2520
  }
2538
- get _services() {
2539
- return Object.keys(this._serviceRegistry.services);
2540
- }
2541
2521
  async open() {
2542
2522
  await this._rpcPeer.open();
2543
2523
  }
@@ -2556,15 +2536,6 @@ var ClientRpcServer = class ClientRpcServer2 {
2556
2536
  return this._handlerCache.get(serviceName);
2557
2537
  }
2558
2538
  };
2559
- _ts_decorate3([
2560
- import_tracing3.trace.metricsCounter()
2561
- ], ClientRpcServer.prototype, "_callMetrics", void 0);
2562
- _ts_decorate3([
2563
- import_tracing3.trace.info()
2564
- ], ClientRpcServer.prototype, "_services", null);
2565
- ClientRpcServer = _ts_decorate3([
2566
- import_tracing3.trace.resource()
2567
- ], ClientRpcServer);
2568
2539
 
2569
2540
  // packages/sdk/client-services/src/packlets/services/diagnostics.ts
2570
2541
  var import_async10 = require("@dxos/async");
@@ -2606,7 +2577,7 @@ var getPlatform = () => {
2606
2577
  };
2607
2578
 
2608
2579
  // packages/sdk/client-services/src/version.ts
2609
- var DXOS_VERSION = "0.3.3-main.44bdbf7";
2580
+ var DXOS_VERSION = "0.3.3-main.619fab4";
2610
2581
 
2611
2582
  // packages/sdk/client-services/src/packlets/services/diagnostics.ts
2612
2583
  var __dxlog_file10 = "/home/runner/work/dxos/dxos/packages/sdk/client-services/src/packlets/services/diagnostics.ts";
@@ -2753,7 +2724,7 @@ var import_log13 = require("@dxos/log");
2753
2724
  var import_protocols10 = require("@dxos/protocols");
2754
2725
  var import_services10 = require("@dxos/protocols/proto/dxos/client/services");
2755
2726
  var import_teleport_extension_object_sync = require("@dxos/teleport-extension-object-sync");
2756
- var import_tracing5 = require("@dxos/tracing");
2727
+ var import_tracing4 = require("@dxos/tracing");
2757
2728
  var import_util7 = require("@dxos/util");
2758
2729
 
2759
2730
  // packages/sdk/client-services/src/packlets/spaces/data-space-manager.ts
@@ -2780,7 +2751,7 @@ var import_protocols7 = require("@dxos/protocols");
2780
2751
  var import_services7 = require("@dxos/protocols/proto/dxos/client/services");
2781
2752
  var import_credentials10 = require("@dxos/protocols/proto/dxos/halo/credentials");
2782
2753
  var import_timeframe2 = require("@dxos/timeframe");
2783
- var import_tracing4 = require("@dxos/tracing");
2754
+ var import_tracing3 = require("@dxos/tracing");
2784
2755
  var import_util5 = require("@dxos/util");
2785
2756
 
2786
2757
  // packages/sdk/client-services/src/packlets/spaces/notarization-plugin.ts
@@ -3052,7 +3023,7 @@ var NotarizationTeleportExtension = class extends import_teleport2.RpcExtension
3052
3023
  };
3053
3024
 
3054
3025
  // packages/sdk/client-services/src/packlets/spaces/data-space.ts
3055
- function _ts_decorate4(decorators, target, key, desc) {
3026
+ function _ts_decorate3(decorators, target, key, desc) {
3056
3027
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3057
3028
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3058
3029
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3384,32 +3355,32 @@ var DataSpace = class DataSpace2 {
3384
3355
  this.stateUpdate.emit();
3385
3356
  }
3386
3357
  };
3387
- _ts_decorate4([
3358
+ _ts_decorate3([
3388
3359
  import_async12.synchronized
3389
3360
  ], DataSpace.prototype, "open", null);
3390
- _ts_decorate4([
3361
+ _ts_decorate3([
3391
3362
  import_async12.synchronized
3392
3363
  ], DataSpace.prototype, "close", null);
3393
- _ts_decorate4([
3394
- import_tracing4.trace.span({
3364
+ _ts_decorate3([
3365
+ import_tracing3.trace.span({
3395
3366
  showInBrowserTimeline: true
3396
3367
  })
3397
3368
  ], DataSpace.prototype, "initializeDataPipeline", null);
3398
- _ts_decorate4([
3399
- import_tracing4.trace.span({
3369
+ _ts_decorate3([
3370
+ import_tracing3.trace.span({
3400
3371
  showInBrowserTimeline: true
3401
3372
  })
3402
3373
  ], DataSpace.prototype, "_initializeAndReadControlPipeline", null);
3403
- _ts_decorate4([
3374
+ _ts_decorate3([
3404
3375
  (0, import_debug4.timed)(1e4)
3405
3376
  ], DataSpace.prototype, "_createWritableFeeds", null);
3406
- _ts_decorate4([
3377
+ _ts_decorate3([
3407
3378
  import_async12.synchronized
3408
3379
  ], DataSpace.prototype, "activate", null);
3409
- _ts_decorate4([
3380
+ _ts_decorate3([
3410
3381
  import_async12.synchronized
3411
3382
  ], DataSpace.prototype, "deactivate", null);
3412
- DataSpace = _ts_decorate4([
3383
+ DataSpace = _ts_decorate3([
3413
3384
  (0, import_async12.trackLeaks)("open", "close")
3414
3385
  ], DataSpace);
3415
3386
 
@@ -3483,7 +3454,7 @@ var spaceGenesis = async (keyring, signingContext, space) => {
3483
3454
  };
3484
3455
 
3485
3456
  // packages/sdk/client-services/src/packlets/spaces/data-space-manager.ts
3486
- function _ts_decorate5(decorators, target, key, desc) {
3457
+ function _ts_decorate4(decorators, target, key, desc) {
3487
3458
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3488
3459
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3489
3460
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3799,19 +3770,19 @@ var DataSpaceManager = class DataSpaceManager2 {
3799
3770
  return dataSpace;
3800
3771
  }
3801
3772
  };
3802
- _ts_decorate5([
3773
+ _ts_decorate4([
3803
3774
  import_async13.synchronized
3804
3775
  ], DataSpaceManager.prototype, "open", null);
3805
- _ts_decorate5([
3776
+ _ts_decorate4([
3806
3777
  import_async13.synchronized
3807
3778
  ], DataSpaceManager.prototype, "close", null);
3808
- _ts_decorate5([
3779
+ _ts_decorate4([
3809
3780
  import_async13.synchronized
3810
3781
  ], DataSpaceManager.prototype, "createSpace", null);
3811
- _ts_decorate5([
3782
+ _ts_decorate4([
3812
3783
  import_async13.synchronized
3813
3784
  ], DataSpaceManager.prototype, "acceptSpace", null);
3814
- DataSpaceManager = _ts_decorate5([
3785
+ DataSpaceManager = _ts_decorate4([
3815
3786
  (0, import_async13.trackLeaks)("open", "close")
3816
3787
  ], DataSpaceManager);
3817
3788
 
@@ -4037,7 +4008,7 @@ var SpacesServiceImpl = class {
4037
4008
  var getChannelId = (channel) => `user-channel/${channel}`;
4038
4009
 
4039
4010
  // packages/sdk/client-services/src/packlets/services/service-context.ts
4040
- function _ts_decorate6(decorators, target, key, desc) {
4011
+ function _ts_decorate5(decorators, target, key, desc) {
4041
4012
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4042
4013
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
4043
4014
  r = Reflect.decorate(decorators, target, key, desc);
@@ -4271,15 +4242,15 @@ var ServiceContext = class ServiceContext2 {
4271
4242
  await identity.space.spaceState.addCredentialProcessor(this._deviceSpaceSync);
4272
4243
  }
4273
4244
  };
4274
- _ts_decorate6([
4275
- import_tracing5.trace.span()
4245
+ _ts_decorate5([
4246
+ import_tracing4.trace.span()
4276
4247
  ], ServiceContext.prototype, "open", null);
4277
- _ts_decorate6([
4278
- import_tracing5.trace.span()
4248
+ _ts_decorate5([
4249
+ import_tracing4.trace.span()
4279
4250
  ], ServiceContext.prototype, "_initialize", null);
4280
- ServiceContext = _ts_decorate6([
4251
+ ServiceContext = _ts_decorate5([
4281
4252
  (0, import_util7.safeInstanceof)("dxos.client-services.ServiceContext"),
4282
- import_tracing5.trace.resource()
4253
+ import_tracing4.trace.resource()
4283
4254
  ], ServiceContext);
4284
4255
 
4285
4256
  // packages/sdk/client-services/src/packlets/services/service-host.ts
@@ -4298,7 +4269,7 @@ var import_network_manager2 = require("@dxos/network-manager");
4298
4269
  var import_protocols12 = require("@dxos/protocols");
4299
4270
  var import_services14 = require("@dxos/protocols/proto/dxos/client/services");
4300
4271
  var import_text_model = require("@dxos/text-model");
4301
- var import_tracing6 = require("@dxos/tracing");
4272
+ var import_tracing5 = require("@dxos/tracing");
4302
4273
  var import_websocket_rpc = require("@dxos/websocket-rpc");
4303
4274
 
4304
4275
  // packages/sdk/client-services/src/packlets/services/service-registry.ts
@@ -4373,7 +4344,7 @@ var DevicesServiceImpl = class {
4373
4344
  var import_invariant14 = require("@dxos/invariant");
4374
4345
  var import_lock_file = require("@dxos/lock-file");
4375
4346
  var import_log14 = require("@dxos/log");
4376
- function _ts_decorate7(decorators, target, key, desc) {
4347
+ function _ts_decorate6(decorators, target, key, desc) {
4377
4348
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4378
4349
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
4379
4350
  r = Reflect.decorate(decorators, target, key, desc);
@@ -4423,7 +4394,7 @@ var Lock = class {
4423
4394
  await import_lock_file.LockFile.release(this._fileHandle);
4424
4395
  }
4425
4396
  };
4426
- _ts_decorate7([
4397
+ _ts_decorate6([
4427
4398
  import_log14.logInfo
4428
4399
  ], Lock.prototype, "lockKey", null);
4429
4400
  var isLocked = (lockPath) => import_lock_file.LockFile.isLocked(lockPath);
@@ -4681,7 +4652,7 @@ var SystemServiceImpl = class {
4681
4652
  };
4682
4653
 
4683
4654
  // packages/sdk/client-services/src/packlets/services/service-host.ts
4684
- function _ts_decorate8(decorators, target, key, desc) {
4655
+ function _ts_decorate7(decorators, target, key, desc) {
4685
4656
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4686
4657
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
4687
4658
  r = Reflect.decorate(decorators, target, key, desc);
@@ -4718,7 +4689,7 @@ var ClientServicesHost = class ClientServicesHost2 {
4718
4689
  lockKey,
4719
4690
  callbacks
4720
4691
  } = {}) {
4721
- this._tracingService = import_tracing6.TRACE_PROCESSOR.createTraceSender();
4692
+ this._tracingService = import_tracing5.TRACE_PROCESSOR.createTraceSender();
4722
4693
  this._statusUpdate = new import_async18.Event();
4723
4694
  this._opening = false;
4724
4695
  this._open = false;
@@ -5043,22 +5014,22 @@ var ClientServicesHost = class ClientServicesHost2 {
5043
5014
  return identity;
5044
5015
  }
5045
5016
  };
5046
- _ts_decorate8([
5047
- import_tracing6.trace.info()
5017
+ _ts_decorate7([
5018
+ import_tracing5.trace.info()
5048
5019
  ], ClientServicesHost.prototype, "_opening", void 0);
5049
- _ts_decorate8([
5050
- import_tracing6.trace.info()
5020
+ _ts_decorate7([
5021
+ import_tracing5.trace.info()
5051
5022
  ], ClientServicesHost.prototype, "_open", void 0);
5052
- _ts_decorate8([
5023
+ _ts_decorate7([
5053
5024
  import_async18.synchronized,
5054
- import_tracing6.trace.span()
5025
+ import_tracing5.trace.span()
5055
5026
  ], ClientServicesHost.prototype, "open", null);
5056
- _ts_decorate8([
5027
+ _ts_decorate7([
5057
5028
  import_async18.synchronized,
5058
- import_tracing6.trace.span()
5029
+ import_tracing5.trace.span()
5059
5030
  ], ClientServicesHost.prototype, "close", null);
5060
- ClientServicesHost = _ts_decorate8([
5061
- import_tracing6.trace.resource()
5031
+ ClientServicesHost = _ts_decorate7([
5032
+ import_tracing5.trace.resource()
5062
5033
  ], ClientServicesHost);
5063
5034
 
5064
5035
  // packages/sdk/client-services/src/packlets/vault/iframe-host-runtime.ts
@@ -5139,7 +5110,7 @@ var ShellRuntimeImpl = class {
5139
5110
  };
5140
5111
 
5141
5112
  // packages/sdk/client-services/src/packlets/vault/iframe-host-runtime.ts
5142
- function _ts_decorate9(decorators, target, key, desc) {
5113
+ function _ts_decorate8(decorators, target, key, desc) {
5143
5114
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
5144
5115
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
5145
5116
  r = Reflect.decorate(decorators, target, key, desc);
@@ -5252,7 +5223,7 @@ var IFrameHostRuntime = class {
5252
5223
  });
5253
5224
  }
5254
5225
  };
5255
- _ts_decorate9([
5226
+ _ts_decorate8([
5256
5227
  import_log17.logInfo
5257
5228
  ], IFrameHostRuntime.prototype, "origin", void 0);
5258
5229
 
@@ -5346,7 +5317,7 @@ var import_invariant17 = require("@dxos/invariant");
5346
5317
  var import_log19 = require("@dxos/log");
5347
5318
  var import_rpc4 = require("@dxos/rpc");
5348
5319
  var import_util13 = require("@dxos/util");
5349
- function _ts_decorate10(decorators, target, key, desc) {
5320
+ function _ts_decorate9(decorators, target, key, desc) {
5350
5321
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
5351
5322
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
5352
5323
  r = Reflect.decorate(decorators, target, key, desc);
@@ -5502,10 +5473,10 @@ var WorkerSession = class {
5502
5473
  }).then(callback);
5503
5474
  }
5504
5475
  };
5505
- _ts_decorate10([
5476
+ _ts_decorate9([
5506
5477
  import_log19.logInfo
5507
5478
  ], WorkerSession.prototype, "origin", void 0);
5508
- _ts_decorate10([
5479
+ _ts_decorate9([
5509
5480
  import_log19.logInfo
5510
5481
  ], WorkerSession.prototype, "lockKey", void 0);
5511
5482