@dxos/client-services 0.4.10-main.3e0c8a5 → 0.4.10-main.41107c4
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-6GHZYBUW.mjs → chunk-B3ZAQ3MZ.mjs} +43 -37
- package/dist/lib/browser/{chunk-6GHZYBUW.mjs.map → chunk-B3ZAQ3MZ.mjs.map} +3 -3
- package/dist/lib/browser/index.mjs +1 -1
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/packlets/testing/index.mjs +1 -1
- package/dist/lib/node/{chunk-D5VK6MZQ.cjs → chunk-H3DVFUSA.cjs} +43 -37
- package/dist/lib/node/{chunk-D5VK6MZQ.cjs.map → chunk-H3DVFUSA.cjs.map} +3 -3
- package/dist/lib/node/index.cjs +37 -37
- package/dist/lib/node/meta.json +1 -1
- package/dist/lib/node/packlets/testing/index.cjs +6 -6
- package/dist/types/src/packlets/services/service-host.d.ts.map +1 -1
- package/dist/types/src/version.d.ts +1 -1
- package/package.json +34 -34
- package/src/packlets/services/service-host.ts +19 -11
- package/src/version.ts +1 -1
|
@@ -2769,7 +2769,7 @@ var getPlatform = () => {
|
|
|
2769
2769
|
};
|
|
2770
2770
|
|
|
2771
2771
|
// packages/sdk/client-services/src/version.ts
|
|
2772
|
-
var DXOS_VERSION = "0.4.10-main.
|
|
2772
|
+
var DXOS_VERSION = "0.4.10-main.41107c4";
|
|
2773
2773
|
|
|
2774
2774
|
// packages/sdk/client-services/src/packlets/services/diagnostics.ts
|
|
2775
2775
|
var __dxlog_file10 = "/home/runner/work/dxos/dxos/packages/sdk/client-services/src/packlets/services/diagnostics.ts";
|
|
@@ -4947,12 +4947,11 @@ var toStorageType = (type) => {
|
|
|
4947
4947
|
};
|
|
4948
4948
|
|
|
4949
4949
|
// packages/sdk/client-services/src/packlets/services/service-host.ts
|
|
4950
|
-
import { Event as Event9,
|
|
4951
|
-
import { clientServiceBundle, defaultKey
|
|
4950
|
+
import { Event as Event9, synchronized as synchronized3 } from "@dxos/async";
|
|
4951
|
+
import { Properties, clientServiceBundle, defaultKey } from "@dxos/client-protocol";
|
|
4952
4952
|
import { Context as Context11 } from "@dxos/context";
|
|
4953
|
-
import { DataServiceImpl } from "@dxos/echo-pipeline";
|
|
4953
|
+
import { DataServiceImpl, encodeReference } from "@dxos/echo-pipeline";
|
|
4954
4954
|
import * as E from "@dxos/echo-schema";
|
|
4955
|
-
import { createRawObjectDoc } from "@dxos/echo-schema";
|
|
4956
4955
|
import { IndexServiceImpl } from "@dxos/indexing";
|
|
4957
4956
|
import { invariant as invariant16 } from "@dxos/invariant";
|
|
4958
4957
|
import { PublicKey as PublicKey12 } from "@dxos/keys";
|
|
@@ -5359,7 +5358,7 @@ var ClientServicesHost = class {
|
|
|
5359
5358
|
initialize({ config, ...options }) {
|
|
5360
5359
|
invariant16(!this._open, "service host is open", {
|
|
5361
5360
|
F: __dxlog_file18,
|
|
5362
|
-
L:
|
|
5361
|
+
L: 179,
|
|
5363
5362
|
S: this,
|
|
5364
5363
|
A: [
|
|
5365
5364
|
"!this._open",
|
|
@@ -5368,14 +5367,14 @@ var ClientServicesHost = class {
|
|
|
5368
5367
|
});
|
|
5369
5368
|
log15("initializing...", void 0, {
|
|
5370
5369
|
F: __dxlog_file18,
|
|
5371
|
-
L:
|
|
5370
|
+
L: 180,
|
|
5372
5371
|
S: this,
|
|
5373
5372
|
C: (f, a) => f(...a)
|
|
5374
5373
|
});
|
|
5375
5374
|
if (config) {
|
|
5376
5375
|
invariant16(!this._config, "config already set", {
|
|
5377
5376
|
F: __dxlog_file18,
|
|
5378
|
-
L:
|
|
5377
|
+
L: 183,
|
|
5379
5378
|
S: this,
|
|
5380
5379
|
A: [
|
|
5381
5380
|
"!this._config",
|
|
@@ -5390,7 +5389,7 @@ var ClientServicesHost = class {
|
|
|
5390
5389
|
if (!options.signalManager) {
|
|
5391
5390
|
log15.warn("running signaling without telemetry metadata.", void 0, {
|
|
5392
5391
|
F: __dxlog_file18,
|
|
5393
|
-
L:
|
|
5392
|
+
L: 191,
|
|
5394
5393
|
S: this,
|
|
5395
5394
|
C: (f, a) => f(...a)
|
|
5396
5395
|
});
|
|
@@ -5401,7 +5400,7 @@ var ClientServicesHost = class {
|
|
|
5401
5400
|
this._signalManager = signalManager;
|
|
5402
5401
|
invariant16(!this._networkManager, "network manager already set", {
|
|
5403
5402
|
F: __dxlog_file18,
|
|
5404
|
-
L:
|
|
5403
|
+
L: 202,
|
|
5405
5404
|
S: this,
|
|
5406
5405
|
A: [
|
|
5407
5406
|
"!this._networkManager",
|
|
@@ -5415,7 +5414,7 @@ var ClientServicesHost = class {
|
|
|
5415
5414
|
});
|
|
5416
5415
|
log15("initialized", void 0, {
|
|
5417
5416
|
F: __dxlog_file18,
|
|
5418
|
-
L:
|
|
5417
|
+
L: 209,
|
|
5419
5418
|
S: this,
|
|
5420
5419
|
C: (f, a) => f(...a)
|
|
5421
5420
|
});
|
|
@@ -5429,13 +5428,13 @@ var ClientServicesHost = class {
|
|
|
5429
5428
|
id: traceId
|
|
5430
5429
|
}), {
|
|
5431
5430
|
F: __dxlog_file18,
|
|
5432
|
-
L:
|
|
5431
|
+
L: 220,
|
|
5433
5432
|
S: this,
|
|
5434
5433
|
C: (f, a) => f(...a)
|
|
5435
5434
|
});
|
|
5436
5435
|
invariant16(this._config, "config not set", {
|
|
5437
5436
|
F: __dxlog_file18,
|
|
5438
|
-
L:
|
|
5437
|
+
L: 222,
|
|
5439
5438
|
S: this,
|
|
5440
5439
|
A: [
|
|
5441
5440
|
"this._config",
|
|
@@ -5444,7 +5443,7 @@ var ClientServicesHost = class {
|
|
|
5444
5443
|
});
|
|
5445
5444
|
invariant16(this._storage, "storage not set", {
|
|
5446
5445
|
F: __dxlog_file18,
|
|
5447
|
-
L:
|
|
5446
|
+
L: 223,
|
|
5448
5447
|
S: this,
|
|
5449
5448
|
A: [
|
|
5450
5449
|
"this._storage",
|
|
@@ -5453,7 +5452,7 @@ var ClientServicesHost = class {
|
|
|
5453
5452
|
});
|
|
5454
5453
|
invariant16(this._signalManager, "signal manager not set", {
|
|
5455
5454
|
F: __dxlog_file18,
|
|
5456
|
-
L:
|
|
5455
|
+
L: 224,
|
|
5457
5456
|
S: this,
|
|
5458
5457
|
A: [
|
|
5459
5458
|
"this._signalManager",
|
|
@@ -5462,7 +5461,7 @@ var ClientServicesHost = class {
|
|
|
5462
5461
|
});
|
|
5463
5462
|
invariant16(this._networkManager, "network manager not set", {
|
|
5464
5463
|
F: __dxlog_file18,
|
|
5465
|
-
L:
|
|
5464
|
+
L: 225,
|
|
5466
5465
|
S: this,
|
|
5467
5466
|
A: [
|
|
5468
5467
|
"this._networkManager",
|
|
@@ -5474,7 +5473,7 @@ var ClientServicesHost = class {
|
|
|
5474
5473
|
lockKey: this._resourceLock?.lockKey
|
|
5475
5474
|
}, {
|
|
5476
5475
|
F: __dxlog_file18,
|
|
5477
|
-
L:
|
|
5476
|
+
L: 228,
|
|
5478
5477
|
S: this,
|
|
5479
5478
|
C: (f, a) => f(...a)
|
|
5480
5479
|
});
|
|
@@ -5508,7 +5507,7 @@ var ClientServicesHost = class {
|
|
|
5508
5507
|
await this._serviceContext.open(ctx);
|
|
5509
5508
|
invariant16(this.serviceRegistry.services.InvitationsService, void 0, {
|
|
5510
5509
|
F: __dxlog_file18,
|
|
5511
|
-
L:
|
|
5510
|
+
L: 289,
|
|
5512
5511
|
S: this,
|
|
5513
5512
|
A: [
|
|
5514
5513
|
"this.serviceRegistry.services.InvitationsService",
|
|
@@ -5520,7 +5519,7 @@ var ClientServicesHost = class {
|
|
|
5520
5519
|
count: loadedInvitations.invitations?.length
|
|
5521
5520
|
}, {
|
|
5522
5521
|
F: __dxlog_file18,
|
|
5523
|
-
L:
|
|
5522
|
+
L: 292,
|
|
5524
5523
|
S: this,
|
|
5525
5524
|
C: (f, a) => f(...a)
|
|
5526
5525
|
});
|
|
@@ -5542,7 +5541,7 @@ var ClientServicesHost = class {
|
|
|
5542
5541
|
deviceKey
|
|
5543
5542
|
}, {
|
|
5544
5543
|
F: __dxlog_file18,
|
|
5545
|
-
L:
|
|
5544
|
+
L: 309,
|
|
5546
5545
|
S: this,
|
|
5547
5546
|
C: (f, a) => f(...a)
|
|
5548
5547
|
});
|
|
@@ -5550,7 +5549,7 @@ var ClientServicesHost = class {
|
|
|
5550
5549
|
id: traceId
|
|
5551
5550
|
}), {
|
|
5552
5551
|
F: __dxlog_file18,
|
|
5553
|
-
L:
|
|
5552
|
+
L: 310,
|
|
5554
5553
|
S: this,
|
|
5555
5554
|
C: (f, a) => f(...a)
|
|
5556
5555
|
});
|
|
@@ -5564,7 +5563,7 @@ var ClientServicesHost = class {
|
|
|
5564
5563
|
deviceKey
|
|
5565
5564
|
}, {
|
|
5566
5565
|
F: __dxlog_file18,
|
|
5567
|
-
L:
|
|
5566
|
+
L: 321,
|
|
5568
5567
|
S: this,
|
|
5569
5568
|
C: (f, a) => f(...a)
|
|
5570
5569
|
});
|
|
@@ -5580,7 +5579,7 @@ var ClientServicesHost = class {
|
|
|
5580
5579
|
deviceKey
|
|
5581
5580
|
}, {
|
|
5582
5581
|
F: __dxlog_file18,
|
|
5583
|
-
L:
|
|
5582
|
+
L: 328,
|
|
5584
5583
|
S: this,
|
|
5585
5584
|
C: (f, a) => f(...a)
|
|
5586
5585
|
});
|
|
@@ -5591,13 +5590,13 @@ var ClientServicesHost = class {
|
|
|
5591
5590
|
id: traceId
|
|
5592
5591
|
}), {
|
|
5593
5592
|
F: __dxlog_file18,
|
|
5594
|
-
L:
|
|
5593
|
+
L: 333,
|
|
5595
5594
|
S: this,
|
|
5596
5595
|
C: (f, a) => f(...a)
|
|
5597
5596
|
});
|
|
5598
5597
|
log15("resetting...", void 0, {
|
|
5599
5598
|
F: __dxlog_file18,
|
|
5600
|
-
L:
|
|
5599
|
+
L: 335,
|
|
5601
5600
|
S: this,
|
|
5602
5601
|
C: (f, a) => f(...a)
|
|
5603
5602
|
});
|
|
@@ -5605,7 +5604,7 @@ var ClientServicesHost = class {
|
|
|
5605
5604
|
await this._storage.reset();
|
|
5606
5605
|
log15("reset", void 0, {
|
|
5607
5606
|
F: __dxlog_file18,
|
|
5608
|
-
L:
|
|
5607
|
+
L: 338,
|
|
5609
5608
|
S: this,
|
|
5610
5609
|
C: (f, a) => f(...a)
|
|
5611
5610
|
});
|
|
@@ -5613,7 +5612,7 @@ var ClientServicesHost = class {
|
|
|
5613
5612
|
id: traceId
|
|
5614
5613
|
}), {
|
|
5615
5614
|
F: __dxlog_file18,
|
|
5616
|
-
L:
|
|
5615
|
+
L: 339,
|
|
5617
5616
|
S: this,
|
|
5618
5617
|
C: (f, a) => f(...a)
|
|
5619
5618
|
});
|
|
@@ -5626,7 +5625,7 @@ var ClientServicesHost = class {
|
|
|
5626
5625
|
const automergeIndex = space.automergeSpaceState.rootUrl;
|
|
5627
5626
|
invariant16(automergeIndex, void 0, {
|
|
5628
5627
|
F: __dxlog_file18,
|
|
5629
|
-
L:
|
|
5628
|
+
L: 351,
|
|
5630
5629
|
S: this,
|
|
5631
5630
|
A: [
|
|
5632
5631
|
"automergeIndex",
|
|
@@ -5635,18 +5634,25 @@ var ClientServicesHost = class {
|
|
|
5635
5634
|
});
|
|
5636
5635
|
const document = await this._serviceContext.automergeHost.repo.find(automergeIndex);
|
|
5637
5636
|
await document.whenReady();
|
|
5638
|
-
const
|
|
5639
|
-
|
|
5640
|
-
|
|
5641
|
-
|
|
5642
|
-
|
|
5637
|
+
const properties = {
|
|
5638
|
+
system: {
|
|
5639
|
+
type: encodeReference(E.getTypeReference(Properties))
|
|
5640
|
+
},
|
|
5641
|
+
data: {
|
|
5642
|
+
[defaultKey]: identity.identityKey.toHex()
|
|
5643
|
+
},
|
|
5644
|
+
meta: {
|
|
5645
|
+
keys: []
|
|
5646
|
+
}
|
|
5647
|
+
};
|
|
5648
|
+
const propertiesId = PublicKey12.random().toHex();
|
|
5643
5649
|
document.change((doc) => {
|
|
5644
5650
|
assignDeep2(doc, [
|
|
5645
5651
|
"objects",
|
|
5646
|
-
|
|
5647
|
-
],
|
|
5652
|
+
propertiesId
|
|
5653
|
+
], properties);
|
|
5648
5654
|
});
|
|
5649
|
-
await
|
|
5655
|
+
await this._serviceContext.automergeHost.repo.flush();
|
|
5650
5656
|
return identity;
|
|
5651
5657
|
}
|
|
5652
5658
|
};
|
|
@@ -5702,4 +5708,4 @@ export {
|
|
|
5702
5708
|
createStorageObjects,
|
|
5703
5709
|
ClientServicesHost
|
|
5704
5710
|
};
|
|
5705
|
-
//# sourceMappingURL=chunk-
|
|
5711
|
+
//# sourceMappingURL=chunk-B3ZAQ3MZ.mjs.map
|