@dxos/network-manager 0.4.10-main.ec8b427 → 0.4.10-main.f68a1ca
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-KEN4UCZF.mjs → chunk-2QQJJZJQ.mjs} +31 -31
- package/dist/lib/browser/{chunk-KEN4UCZF.mjs.map → chunk-2QQJJZJQ.mjs.map} +2 -2
- 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-5D3NBEP2.cjs → chunk-IWG3IC7H.cjs} +34 -34
- package/dist/lib/node/{chunk-5D3NBEP2.cjs.map → chunk-IWG3IC7H.cjs.map} +2 -2
- package/dist/lib/node/index.cjs +27 -27
- package/dist/lib/node/index.cjs.map +1 -1
- package/dist/lib/node/meta.json +1 -1
- package/dist/lib/node/testing/index.cjs +18 -18
- package/dist/types/src/swarm/swarm.d.ts.map +1 -1
- package/package.json +17 -17
- package/src/swarm/swarm.ts +1 -0
|
@@ -1343,7 +1343,7 @@ var Swarm = class {
|
|
|
1343
1343
|
}
|
|
1344
1344
|
}), {
|
|
1345
1345
|
F: __dxlog_file4,
|
|
1346
|
-
L:
|
|
1346
|
+
L: 89,
|
|
1347
1347
|
S: this,
|
|
1348
1348
|
C: (f, a) => f(...a)
|
|
1349
1349
|
});
|
|
@@ -1351,7 +1351,7 @@ var Swarm = class {
|
|
|
1351
1351
|
peerId: _ownPeerId
|
|
1352
1352
|
}, {
|
|
1353
1353
|
F: __dxlog_file4,
|
|
1354
|
-
L:
|
|
1354
|
+
L: 93,
|
|
1355
1355
|
S: this,
|
|
1356
1356
|
C: (f, a) => f(...a)
|
|
1357
1357
|
});
|
|
@@ -1366,7 +1366,7 @@ var Swarm = class {
|
|
|
1366
1366
|
id: this._instanceId
|
|
1367
1367
|
}), {
|
|
1368
1368
|
F: __dxlog_file4,
|
|
1369
|
-
L:
|
|
1369
|
+
L: 102,
|
|
1370
1370
|
S: this,
|
|
1371
1371
|
C: (f, a) => f(...a)
|
|
1372
1372
|
});
|
|
@@ -1389,7 +1389,7 @@ var Swarm = class {
|
|
|
1389
1389
|
async open() {
|
|
1390
1390
|
invariant4(!this._listeningHandle, void 0, {
|
|
1391
1391
|
F: __dxlog_file4,
|
|
1392
|
-
L:
|
|
1392
|
+
L: 129,
|
|
1393
1393
|
S: this,
|
|
1394
1394
|
A: [
|
|
1395
1395
|
"!this._listeningHandle",
|
|
@@ -1404,7 +1404,7 @@ var Swarm = class {
|
|
|
1404
1404
|
err
|
|
1405
1405
|
}, {
|
|
1406
1406
|
F: __dxlog_file4,
|
|
1407
|
-
L:
|
|
1407
|
+
L: 137,
|
|
1408
1408
|
S: this,
|
|
1409
1409
|
C: (f, a) => f(...a)
|
|
1410
1410
|
}));
|
|
@@ -1414,7 +1414,7 @@ var Swarm = class {
|
|
|
1414
1414
|
async destroy() {
|
|
1415
1415
|
log4("destroying...", void 0, {
|
|
1416
1416
|
F: __dxlog_file4,
|
|
1417
|
-
L:
|
|
1417
|
+
L: 143,
|
|
1418
1418
|
S: this,
|
|
1419
1419
|
C: (f, a) => f(...a)
|
|
1420
1420
|
});
|
|
@@ -1425,7 +1425,7 @@ var Swarm = class {
|
|
|
1425
1425
|
await Promise.all(Array.from(this._peers.keys()).map((key) => this._destroyPeer(key, "swarm destroyed")));
|
|
1426
1426
|
log4("destroyed", void 0, {
|
|
1427
1427
|
F: __dxlog_file4,
|
|
1428
|
-
L:
|
|
1428
|
+
L: 150,
|
|
1429
1429
|
S: this,
|
|
1430
1430
|
C: (f, a) => f(...a)
|
|
1431
1431
|
});
|
|
@@ -1433,7 +1433,7 @@ var Swarm = class {
|
|
|
1433
1433
|
async setTopology(topology) {
|
|
1434
1434
|
invariant4(!this._ctx.disposed, "Swarm is offline", {
|
|
1435
1435
|
F: __dxlog_file4,
|
|
1436
|
-
L:
|
|
1436
|
+
L: 154,
|
|
1437
1437
|
S: this,
|
|
1438
1438
|
A: [
|
|
1439
1439
|
"!this._ctx.disposed",
|
|
@@ -1448,7 +1448,7 @@ var Swarm = class {
|
|
|
1448
1448
|
topology: getClassName(topology)
|
|
1449
1449
|
}, {
|
|
1450
1450
|
F: __dxlog_file4,
|
|
1451
|
-
L:
|
|
1451
|
+
L: 158,
|
|
1452
1452
|
S: this,
|
|
1453
1453
|
C: (f, a) => f(...a)
|
|
1454
1454
|
});
|
|
@@ -1462,14 +1462,14 @@ var Swarm = class {
|
|
|
1462
1462
|
swarmEvent
|
|
1463
1463
|
}, {
|
|
1464
1464
|
F: __dxlog_file4,
|
|
1465
|
-
L:
|
|
1465
|
+
L: 171,
|
|
1466
1466
|
S: this,
|
|
1467
1467
|
C: (f, a) => f(...a)
|
|
1468
1468
|
});
|
|
1469
1469
|
if (this._ctx.disposed) {
|
|
1470
1470
|
log4("swarm event ignored for disposed swarm", void 0, {
|
|
1471
1471
|
F: __dxlog_file4,
|
|
1472
|
-
L:
|
|
1472
|
+
L: 174,
|
|
1473
1473
|
S: this,
|
|
1474
1474
|
C: (f, a) => f(...a)
|
|
1475
1475
|
});
|
|
@@ -1481,7 +1481,7 @@ var Swarm = class {
|
|
|
1481
1481
|
peerId
|
|
1482
1482
|
}, {
|
|
1483
1483
|
F: __dxlog_file4,
|
|
1484
|
-
L:
|
|
1484
|
+
L: 180,
|
|
1485
1485
|
S: this,
|
|
1486
1486
|
C: (f, a) => f(...a)
|
|
1487
1487
|
});
|
|
@@ -1496,7 +1496,7 @@ var Swarm = class {
|
|
|
1496
1496
|
if (peer.connection?.state !== ConnectionState.CONNECTED) {
|
|
1497
1497
|
void this._destroyPeer(peer.id, "peer left").catch((err) => log4.catch(err, void 0, {
|
|
1498
1498
|
F: __dxlog_file4,
|
|
1499
|
-
L:
|
|
1499
|
+
L: 191,
|
|
1500
1500
|
S: this,
|
|
1501
1501
|
C: (f, a) => f(...a)
|
|
1502
1502
|
}));
|
|
@@ -1506,7 +1506,7 @@ var Swarm = class {
|
|
|
1506
1506
|
peer: swarmEvent.peerLeft.peer
|
|
1507
1507
|
}, {
|
|
1508
1508
|
F: __dxlog_file4,
|
|
1509
|
-
L:
|
|
1509
|
+
L: 194,
|
|
1510
1510
|
S: this,
|
|
1511
1511
|
C: (f, a) => f(...a)
|
|
1512
1512
|
});
|
|
@@ -1519,14 +1519,14 @@ var Swarm = class {
|
|
|
1519
1519
|
message
|
|
1520
1520
|
}, {
|
|
1521
1521
|
F: __dxlog_file4,
|
|
1522
|
-
L:
|
|
1522
|
+
L: 203,
|
|
1523
1523
|
S: this,
|
|
1524
1524
|
C: (f, a) => f(...a)
|
|
1525
1525
|
});
|
|
1526
1526
|
if (this._ctx.disposed) {
|
|
1527
1527
|
log4("ignored for disposed swarm", void 0, {
|
|
1528
1528
|
F: __dxlog_file4,
|
|
1529
|
-
L:
|
|
1529
|
+
L: 205,
|
|
1530
1530
|
S: this,
|
|
1531
1531
|
C: (f, a) => f(...a)
|
|
1532
1532
|
});
|
|
@@ -1536,7 +1536,7 @@ var Swarm = class {
|
|
|
1536
1536
|
}
|
|
1537
1537
|
invariant4(message.author, void 0, {
|
|
1538
1538
|
F: __dxlog_file4,
|
|
1539
|
-
L:
|
|
1539
|
+
L: 210,
|
|
1540
1540
|
S: this,
|
|
1541
1541
|
A: [
|
|
1542
1542
|
"message.author",
|
|
@@ -1548,7 +1548,7 @@ var Swarm = class {
|
|
|
1548
1548
|
message
|
|
1549
1549
|
}, {
|
|
1550
1550
|
F: __dxlog_file4,
|
|
1551
|
-
L:
|
|
1551
|
+
L: 212,
|
|
1552
1552
|
S: this,
|
|
1553
1553
|
C: (f, a) => f(...a)
|
|
1554
1554
|
});
|
|
@@ -1561,7 +1561,7 @@ var Swarm = class {
|
|
|
1561
1561
|
message
|
|
1562
1562
|
}, {
|
|
1563
1563
|
F: __dxlog_file4,
|
|
1564
|
-
L:
|
|
1564
|
+
L: 216,
|
|
1565
1565
|
S: this,
|
|
1566
1566
|
C: (f, a) => f(...a)
|
|
1567
1567
|
});
|
|
@@ -1579,14 +1579,14 @@ var Swarm = class {
|
|
|
1579
1579
|
message
|
|
1580
1580
|
}, {
|
|
1581
1581
|
F: __dxlog_file4,
|
|
1582
|
-
L:
|
|
1582
|
+
L: 227,
|
|
1583
1583
|
S: this,
|
|
1584
1584
|
C: (f, a) => f(...a)
|
|
1585
1585
|
});
|
|
1586
1586
|
if (this._ctx.disposed) {
|
|
1587
1587
|
log4.info("ignored for offline swarm", void 0, {
|
|
1588
1588
|
F: __dxlog_file4,
|
|
1589
|
-
L:
|
|
1589
|
+
L: 229,
|
|
1590
1590
|
S: this,
|
|
1591
1591
|
C: (f, a) => f(...a)
|
|
1592
1592
|
});
|
|
@@ -1594,7 +1594,7 @@ var Swarm = class {
|
|
|
1594
1594
|
}
|
|
1595
1595
|
invariant4(message.recipient?.equals(this._ownPeerId), `Invalid signal peer id expected=${this.ownPeerId}, actual=${message.recipient}`, {
|
|
1596
1596
|
F: __dxlog_file4,
|
|
1597
|
-
L:
|
|
1597
|
+
L: 232,
|
|
1598
1598
|
S: this,
|
|
1599
1599
|
A: [
|
|
1600
1600
|
"message.recipient?.equals(this._ownPeerId)",
|
|
@@ -1603,7 +1603,7 @@ var Swarm = class {
|
|
|
1603
1603
|
});
|
|
1604
1604
|
invariant4(message.topic?.equals(this._topic), void 0, {
|
|
1605
1605
|
F: __dxlog_file4,
|
|
1606
|
-
L:
|
|
1606
|
+
L: 236,
|
|
1607
1607
|
S: this,
|
|
1608
1608
|
A: [
|
|
1609
1609
|
"message.topic?.equals(this._topic)",
|
|
@@ -1612,7 +1612,7 @@ var Swarm = class {
|
|
|
1612
1612
|
});
|
|
1613
1613
|
invariant4(message.author, void 0, {
|
|
1614
1614
|
F: __dxlog_file4,
|
|
1615
|
-
L:
|
|
1615
|
+
L: 237,
|
|
1616
1616
|
S: this,
|
|
1617
1617
|
A: [
|
|
1618
1618
|
"message.author",
|
|
@@ -1656,7 +1656,7 @@ var Swarm = class {
|
|
|
1656
1656
|
peerId
|
|
1657
1657
|
}, {
|
|
1658
1658
|
F: __dxlog_file4,
|
|
1659
|
-
L:
|
|
1659
|
+
L: 286,
|
|
1660
1660
|
S: this,
|
|
1661
1661
|
C: (f, a) => f(...a)
|
|
1662
1662
|
});
|
|
@@ -1680,7 +1680,7 @@ var Swarm = class {
|
|
|
1680
1680
|
async _destroyPeer(peerId, reason) {
|
|
1681
1681
|
invariant4(this._peers.has(peerId), void 0, {
|
|
1682
1682
|
F: __dxlog_file4,
|
|
1683
|
-
L:
|
|
1683
|
+
L: 308,
|
|
1684
1684
|
S: this,
|
|
1685
1685
|
A: [
|
|
1686
1686
|
"this._peers.has(peerId)",
|
|
@@ -1707,7 +1707,7 @@ var Swarm = class {
|
|
|
1707
1707
|
} catch (err) {
|
|
1708
1708
|
log4("initiation error", err, {
|
|
1709
1709
|
F: __dxlog_file4,
|
|
1710
|
-
L:
|
|
1710
|
+
L: 334,
|
|
1711
1711
|
S: this,
|
|
1712
1712
|
C: (f, a) => f(...a)
|
|
1713
1713
|
});
|
|
@@ -1735,7 +1735,7 @@ var Swarm = class {
|
|
|
1735
1735
|
remoteId
|
|
1736
1736
|
}, {
|
|
1737
1737
|
F: __dxlog_file4,
|
|
1738
|
-
L:
|
|
1738
|
+
L: 361,
|
|
1739
1739
|
S: this,
|
|
1740
1740
|
C: (f, a) => f(...a)
|
|
1741
1741
|
});
|
|
@@ -1752,7 +1752,7 @@ var Swarm = class {
|
|
|
1752
1752
|
remoteId
|
|
1753
1753
|
}, {
|
|
1754
1754
|
F: __dxlog_file4,
|
|
1755
|
-
L:
|
|
1755
|
+
L: 375,
|
|
1756
1756
|
S: this,
|
|
1757
1757
|
C: (f, a) => f(...a)
|
|
1758
1758
|
});
|
|
@@ -1762,7 +1762,7 @@ var Swarm = class {
|
|
|
1762
1762
|
remoteId
|
|
1763
1763
|
}, {
|
|
1764
1764
|
F: __dxlog_file4,
|
|
1765
|
-
L:
|
|
1765
|
+
L: 378,
|
|
1766
1766
|
S: this,
|
|
1767
1767
|
C: (f, a) => f(...a)
|
|
1768
1768
|
});
|
|
@@ -3952,4 +3952,4 @@ export {
|
|
|
3952
3952
|
TcpTransport,
|
|
3953
3953
|
createTeleportProtocolFactory
|
|
3954
3954
|
};
|
|
3955
|
-
//# sourceMappingURL=chunk-
|
|
3955
|
+
//# sourceMappingURL=chunk-2QQJJZJQ.mjs.map
|