@libp2p/kad-dht 14.2.8 → 14.2.9-5b084e968
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/index.min.js +2 -2
- package/dist/src/constants.js +4 -4
- package/dist/src/constants.js.map +1 -1
- package/dist/src/index.d.ts +1 -1
- package/dist/src/record/selectors.js +2 -2
- package/dist/src/record/selectors.js.map +1 -1
- package/dist/src/record/validators.js +2 -2
- package/dist/src/routing-table/refresh.js +7 -7
- package/dist/src/routing-table/refresh.js.map +1 -1
- package/package.json +12 -12
- package/src/constants.ts +4 -4
- package/src/index.ts +1 -1
- package/src/message/dht.proto +2 -2
- package/src/record/selectors.ts +2 -2
- package/src/record/validators.ts +2 -2
- package/src/routing-table/refresh.ts +7 -7
- package/dist/typedoc-urls.json +0 -59
package/dist/src/constants.js
CHANGED
|
@@ -15,7 +15,7 @@ export const REPROVIDE_THRESHOLD = 24 * hour;
|
|
|
15
15
|
export const REPROVIDE_CONCURRENCY = 10;
|
|
16
16
|
// How long to let the reprovide queue grow before we wait for capacity
|
|
17
17
|
export const REPROVIDE_MAX_QUEUE_SIZE = 16_384;
|
|
18
|
-
// How often to check if records need
|
|
18
|
+
// How often to check if records need re-providing
|
|
19
19
|
export const REPROVIDE_INTERVAL = hour;
|
|
20
20
|
export const READ_MESSAGE_TIMEOUT = 10 * second;
|
|
21
21
|
// The number of records that will be retrieved on a call to getMany()
|
|
@@ -24,11 +24,11 @@ export const GET_MANY_RECORD_COUNT = 16;
|
|
|
24
24
|
export const K = 20;
|
|
25
25
|
// Alpha is the concurrency for asynchronous requests
|
|
26
26
|
export const ALPHA = 3;
|
|
27
|
-
// How often we look for our closest DHT
|
|
27
|
+
// How often we look for our closest DHT neighbors
|
|
28
28
|
export const QUERY_SELF_INTERVAL = 5 * minute;
|
|
29
|
-
// How often we look for the first set of our closest DHT
|
|
29
|
+
// How often we look for the first set of our closest DHT neighbors
|
|
30
30
|
export const QUERY_SELF_INITIAL_INTERVAL = second;
|
|
31
|
-
// How long to look for our closest DHT
|
|
31
|
+
// How long to look for our closest DHT neighbors for
|
|
32
32
|
export const QUERY_SELF_TIMEOUT = 5 * second;
|
|
33
33
|
// How often we try to find new peers
|
|
34
34
|
export const TABLE_REFRESH_INTERVAL = 5 * minute;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAE9C,MAAM,CAAC,MAAM,MAAM,GAAG,IAAI,CAAA;AAC1B,MAAM,CAAC,MAAM,MAAM,GAAG,EAAE,GAAG,MAAM,CAAA;AACjC,MAAM,CAAC,MAAM,IAAI,GAAG,EAAE,GAAG,MAAM,CAAA;AAE/B,MAAM,CAAC,MAAM,cAAc,GAAG,EAAE,GAAG,IAAI,CAAA;AAEvC,MAAM,CAAC,MAAM,QAAQ,GAAG,iBAAiB,CAAA;AAEzC;;GAEG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG,EAAE,GAAG,IAAI,CAAA;AAE3C,MAAM,CAAC,MAAM,0BAA0B,GAAG,IAAI,CAAA;AAE9C,6FAA6F;AAC7F,MAAM,CAAC,MAAM,mBAAmB,GAAG,EAAE,GAAG,IAAI,CAAA;AAE5C,+CAA+C;AAC/C,MAAM,CAAC,MAAM,qBAAqB,GAAG,EAAE,CAAA;AAEvC,uEAAuE;AACvE,MAAM,CAAC,MAAM,wBAAwB,GAAG,MAAM,CAAA;AAE9C,
|
|
1
|
+
{"version":3,"file":"constants.js","sourceRoot":"","sources":["../../src/constants.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAE9C,MAAM,CAAC,MAAM,MAAM,GAAG,IAAI,CAAA;AAC1B,MAAM,CAAC,MAAM,MAAM,GAAG,EAAE,GAAG,MAAM,CAAA;AACjC,MAAM,CAAC,MAAM,IA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,qBAAqB,GAAG,GAAG,GAAG,MAAM,CAAA;AAEjD,8DAA8D;AAC9D,MAAM,CAAC,MAAM,cAAc,GAAG,GAAG,UAAU,UAAU,CAAA"}
|
package/dist/src/index.d.ts
CHANGED
|
@@ -418,7 +418,7 @@ export interface KadDHTInit {
|
|
|
418
418
|
* After startup by default all queries will be paused until the initial
|
|
419
419
|
* self-query has run and there are some peers in the routing table.
|
|
420
420
|
*
|
|
421
|
-
* Pass true here to disable this
|
|
421
|
+
* Pass true here to disable this behavior.
|
|
422
422
|
*
|
|
423
423
|
* @default false
|
|
424
424
|
*/
|
|
@@ -27,10 +27,10 @@ export function bestRecord(selectors, k, records) {
|
|
|
27
27
|
* Simply returns the first record, as all valid public key
|
|
28
28
|
* records are equal
|
|
29
29
|
*/
|
|
30
|
-
function
|
|
30
|
+
function publicKey(k, records) {
|
|
31
31
|
return 0;
|
|
32
32
|
}
|
|
33
33
|
export const selectors = {
|
|
34
|
-
pk:
|
|
34
|
+
pk: publicKey
|
|
35
35
|
};
|
|
36
36
|
//# sourceMappingURL=selectors.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"selectors.js","sourceRoot":"","sources":["../../../src/record/selectors.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,sBAAsB,EAAE,MAAM,mBAAmB,CAAA;AAC1D,OAAO,EAAE,QAAQ,IAAI,kBAAkB,EAAE,MAAM,uBAAuB,CAAA;AACtE,OAAO,EAAE,oBAAoB,EAAE,MAAM,cAAc,CAAA;AAGnD;;GAEG;AACH,MAAM,UAAU,UAAU,CAAE,SAAoB,EAAE,CAAa,EAAE,OAAqB;IACpF,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACzB,MAAM,IAAI,sBAAsB,CAAC,kBAAkB,CAAC,CAAA;IACtD,CAAC;IAED,MAAM,IAAI,GAAG,kBAAkB,CAAC,CAAC,CAAC,CAAA;IAClC,MAAM,KAAK,GAAG,IAAI,CAAC,KAAK,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IAClF,CAAC;IAED,MAAM,QAAQ,GAAG,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAA;IAE/C,IAAI,QAAQ,IAAI,IAAI,EAAE,CAAC;QACrB,MAAM,IAAI,oBAAoB,CAAC,iDAAiD,KAAK,CAAC,CAAC,CAAC,GAAG,CAAC,CAAA;IAC9F,CAAC;IAED,IAAI,OAAO,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACzB,OAAO,CAAC,CAAA;IACV,CAAC;IAED,OAAO,QAAQ,CAAC,CAAC,EAAE,OAAO,CAAC,CAAA;AAC7B,CAAC;AAED;;;;GAIG;AACH,SAAS,SAAS,CAAE,CAAa,EAAE,OAAqB;IACtD,OAAO,CAAC,CAAA;AACV,CAAC;AAED,MAAM,CAAC,MAAM,SAAS,GAAc;IAClC,EAAE,EAAE,SAAS;CACd,CAAA"}
|
|
@@ -42,8 +42,8 @@ const validatePublicKeyRecord = async (key, publicKey) => {
|
|
|
42
42
|
throw new InvalidParametersError('key was not prefixed with /pk/');
|
|
43
43
|
}
|
|
44
44
|
const pubKey = publicKeyFromProtobuf(publicKey);
|
|
45
|
-
const
|
|
46
|
-
if (!uint8ArrayEquals(
|
|
45
|
+
const keyHash = key.slice(4);
|
|
46
|
+
if (!uint8ArrayEquals(keyHash, pubKey.toMultihash().bytes)) {
|
|
47
47
|
throw new InvalidParametersError('public key does not match passed in key');
|
|
48
48
|
}
|
|
49
49
|
};
|
|
@@ -51,29 +51,29 @@ export class RoutingTableRefresh {
|
|
|
51
51
|
refreshTable(force = false) {
|
|
52
52
|
this.log('refreshing routing table');
|
|
53
53
|
const prefixLength = this._maxCommonPrefix();
|
|
54
|
-
const
|
|
54
|
+
const refreshCommonPrefixLengths = this._getTrackedCommonPrefixLengthsForRefresh(prefixLength);
|
|
55
55
|
this.log(`max common prefix length ${prefixLength}`);
|
|
56
|
-
this.log(`tracked CPLs [ ${
|
|
56
|
+
this.log(`tracked CPLs [ ${refreshCommonPrefixLengths.map(date => date.toISOString()).join(', ')} ]`);
|
|
57
57
|
/**
|
|
58
58
|
* If we see a gap at a common prefix length in the Routing table, we ONLY refresh up until
|
|
59
59
|
* the maximum cpl we have in the Routing Table OR (2 * (Cpl+ 1) with the gap), whichever
|
|
60
60
|
* is smaller.
|
|
61
61
|
*
|
|
62
|
-
* This is to prevent refreshes for
|
|
63
|
-
* before a very high max
|
|
62
|
+
* This is to prevent refreshes for common-prefix-lengths that have no peers in the network but happen to be
|
|
63
|
+
* before a very high max common-prefix-length for which we do have peers in the network.
|
|
64
64
|
*
|
|
65
|
-
* The number of 2 * (
|
|
65
|
+
* The number of 2 * (common-prefix-length + 1) can be proved and a proof would have been written here if
|
|
66
66
|
* the programmer had paid more attention in the Math classes at university.
|
|
67
67
|
*
|
|
68
68
|
* So, please be patient and a doc explaining it will be published soon.
|
|
69
69
|
*
|
|
70
70
|
* https://github.com/libp2p/go-libp2p-kad-dht/commit/2851c88acb0a3f86bcfe3cfd0f4604a03db801d8#diff-ad45f4ba97ffbc4083c2eb87a4420c1157057b233f048030d67c6b551855ccf6R219
|
|
71
71
|
*/
|
|
72
|
-
Promise.all(
|
|
72
|
+
Promise.all(refreshCommonPrefixLengths.map(async (lastRefresh, index) => {
|
|
73
73
|
try {
|
|
74
74
|
await this._refreshCommonPrefixLength(index, lastRefresh, force);
|
|
75
75
|
if (this._numPeersForCpl(prefixLength) === 0) {
|
|
76
|
-
const lastCpl = Math.min(2 * (index + 1),
|
|
76
|
+
const lastCpl = Math.min(2 * (index + 1), refreshCommonPrefixLengths.length - 1);
|
|
77
77
|
for (let n = index + 1; n < lastCpl + 1; n++) {
|
|
78
78
|
try {
|
|
79
79
|
await this._refreshCommonPrefixLength(n, lastRefresh, force);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"refresh.js","sourceRoot":"","sources":["../../../src/routing-table/refresh.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,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AED,MAAM,YAAY,CAAA;QACpB,CAAC;IACH,CAAC;CACF"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@libp2p/kad-dht",
|
|
3
|
-
"version": "14.2.
|
|
3
|
+
"version": "14.2.9-5b084e968",
|
|
4
4
|
"description": "JavaScript implementation of the Kad-DHT for libp2p",
|
|
5
5
|
"license": "Apache-2.0 OR MIT",
|
|
6
6
|
"homepage": "https://github.com/libp2p/js-libp2p/tree/main/packages/kad-dht#readme",
|
|
@@ -57,13 +57,13 @@
|
|
|
57
57
|
"doc-check": "aegir doc-check"
|
|
58
58
|
},
|
|
59
59
|
"dependencies": {
|
|
60
|
-
"@libp2p/crypto": "
|
|
61
|
-
"@libp2p/interface": "
|
|
62
|
-
"@libp2p/interface-internal": "
|
|
63
|
-
"@libp2p/peer-collections": "
|
|
64
|
-
"@libp2p/peer-id": "
|
|
65
|
-
"@libp2p/record": "
|
|
66
|
-
"@libp2p/utils": "
|
|
60
|
+
"@libp2p/crypto": "5.0.12-5b084e968",
|
|
61
|
+
"@libp2p/interface": "2.6.0-5b084e968",
|
|
62
|
+
"@libp2p/interface-internal": "2.3.4-5b084e968",
|
|
63
|
+
"@libp2p/peer-collections": "6.0.20-5b084e968",
|
|
64
|
+
"@libp2p/peer-id": "5.0.13-5b084e968",
|
|
65
|
+
"@libp2p/record": "4.0.4-5b084e968",
|
|
66
|
+
"@libp2p/utils": "6.5.4-5b084e968",
|
|
67
67
|
"@multiformats/multiaddr": "^12.3.3",
|
|
68
68
|
"any-signal": "^4.1.1",
|
|
69
69
|
"interface-datastore": "^8.3.1",
|
|
@@ -83,15 +83,15 @@
|
|
|
83
83
|
"p-event": "^6.0.1",
|
|
84
84
|
"progress-events": "^1.0.1",
|
|
85
85
|
"protons-runtime": "^5.5.0",
|
|
86
|
-
"race-signal": "^1.1.
|
|
86
|
+
"race-signal": "^1.1.2",
|
|
87
87
|
"uint8-varint": "^2.0.4",
|
|
88
88
|
"uint8arraylist": "^2.4.8",
|
|
89
89
|
"uint8arrays": "^5.1.0"
|
|
90
90
|
},
|
|
91
91
|
"devDependencies": {
|
|
92
|
-
"@libp2p/interface-compliance-tests": "
|
|
93
|
-
"@libp2p/logger": "
|
|
94
|
-
"@libp2p/peer-store": "
|
|
92
|
+
"@libp2p/interface-compliance-tests": "6.3.4-5b084e968",
|
|
93
|
+
"@libp2p/logger": "5.1.9-5b084e968",
|
|
94
|
+
"@libp2p/peer-store": "11.0.20-5b084e968",
|
|
95
95
|
"@types/lodash.random": "^3.2.9",
|
|
96
96
|
"@types/lodash.range": "^3.2.9",
|
|
97
97
|
"@types/sinon": "^17.0.3",
|
package/src/constants.ts
CHANGED
|
@@ -24,7 +24,7 @@ export const REPROVIDE_CONCURRENCY = 10
|
|
|
24
24
|
// How long to let the reprovide queue grow before we wait for capacity
|
|
25
25
|
export const REPROVIDE_MAX_QUEUE_SIZE = 16_384
|
|
26
26
|
|
|
27
|
-
// How often to check if records need
|
|
27
|
+
// How often to check if records need re-providing
|
|
28
28
|
export const REPROVIDE_INTERVAL = hour
|
|
29
29
|
|
|
30
30
|
export const READ_MESSAGE_TIMEOUT = 10 * second
|
|
@@ -38,13 +38,13 @@ export const K = 20
|
|
|
38
38
|
// Alpha is the concurrency for asynchronous requests
|
|
39
39
|
export const ALPHA = 3
|
|
40
40
|
|
|
41
|
-
// How often we look for our closest DHT
|
|
41
|
+
// How often we look for our closest DHT neighbors
|
|
42
42
|
export const QUERY_SELF_INTERVAL = 5 * minute
|
|
43
43
|
|
|
44
|
-
// How often we look for the first set of our closest DHT
|
|
44
|
+
// How often we look for the first set of our closest DHT neighbors
|
|
45
45
|
export const QUERY_SELF_INITIAL_INTERVAL = second
|
|
46
46
|
|
|
47
|
-
// How long to look for our closest DHT
|
|
47
|
+
// How long to look for our closest DHT neighbors for
|
|
48
48
|
export const QUERY_SELF_TIMEOUT = 5 * second
|
|
49
49
|
|
|
50
50
|
// How often we try to find new peers
|
package/src/index.ts
CHANGED
|
@@ -471,7 +471,7 @@ export interface KadDHTInit {
|
|
|
471
471
|
* After startup by default all queries will be paused until the initial
|
|
472
472
|
* self-query has run and there are some peers in the routing table.
|
|
473
473
|
*
|
|
474
|
-
* Pass true here to disable this
|
|
474
|
+
* Pass true here to disable this behavior.
|
|
475
475
|
*
|
|
476
476
|
* @default false
|
|
477
477
|
*/
|
package/src/message/dht.proto
CHANGED
|
@@ -4,7 +4,7 @@ syntax = "proto3";
|
|
|
4
4
|
// import "record.proto";
|
|
5
5
|
|
|
6
6
|
message Record {
|
|
7
|
-
// adjusted for
|
|
7
|
+
// adjusted for JavaScript
|
|
8
8
|
optional bytes key = 1;
|
|
9
9
|
optional bytes value = 2;
|
|
10
10
|
optional bytes author = 3;
|
|
@@ -57,7 +57,7 @@ message Message {
|
|
|
57
57
|
|
|
58
58
|
// Used to specify the key associated with this message.
|
|
59
59
|
// PUT_VALUE, GET_VALUE, ADD_PROVIDER, GET_PROVIDERS
|
|
60
|
-
// adjusted for
|
|
60
|
+
// adjusted for JavaScript
|
|
61
61
|
optional bytes key = 2;
|
|
62
62
|
|
|
63
63
|
// Used to return a value
|
package/src/record/selectors.ts
CHANGED
|
@@ -36,10 +36,10 @@ export function bestRecord (selectors: Selectors, k: Uint8Array, records: Uint8A
|
|
|
36
36
|
* Simply returns the first record, as all valid public key
|
|
37
37
|
* records are equal
|
|
38
38
|
*/
|
|
39
|
-
function
|
|
39
|
+
function publicKey (k: Uint8Array, records: Uint8Array[]): number {
|
|
40
40
|
return 0
|
|
41
41
|
}
|
|
42
42
|
|
|
43
43
|
export const selectors: Selectors = {
|
|
44
|
-
pk:
|
|
44
|
+
pk: publicKey
|
|
45
45
|
}
|
package/src/record/validators.ts
CHANGED
|
@@ -54,9 +54,9 @@ const validatePublicKeyRecord = async (key: Uint8Array, publicKey: Uint8Array):
|
|
|
54
54
|
}
|
|
55
55
|
|
|
56
56
|
const pubKey = publicKeyFromProtobuf(publicKey)
|
|
57
|
-
const
|
|
57
|
+
const keyHash = key.slice(4)
|
|
58
58
|
|
|
59
|
-
if (!uint8ArrayEquals(
|
|
59
|
+
if (!uint8ArrayEquals(keyHash, pubKey.toMultihash().bytes)) {
|
|
60
60
|
throw new InvalidParametersError('public key does not match passed in key')
|
|
61
61
|
}
|
|
62
62
|
}
|
|
@@ -74,20 +74,20 @@ export class RoutingTableRefresh {
|
|
|
74
74
|
this.log('refreshing routing table')
|
|
75
75
|
|
|
76
76
|
const prefixLength = this._maxCommonPrefix()
|
|
77
|
-
const
|
|
77
|
+
const refreshCommonPrefixLengths = this._getTrackedCommonPrefixLengthsForRefresh(prefixLength)
|
|
78
78
|
|
|
79
79
|
this.log(`max common prefix length ${prefixLength}`)
|
|
80
|
-
this.log(`tracked CPLs [ ${
|
|
80
|
+
this.log(`tracked CPLs [ ${refreshCommonPrefixLengths.map(date => date.toISOString()).join(', ')} ]`)
|
|
81
81
|
|
|
82
82
|
/**
|
|
83
83
|
* If we see a gap at a common prefix length in the Routing table, we ONLY refresh up until
|
|
84
84
|
* the maximum cpl we have in the Routing Table OR (2 * (Cpl+ 1) with the gap), whichever
|
|
85
85
|
* is smaller.
|
|
86
86
|
*
|
|
87
|
-
* This is to prevent refreshes for
|
|
88
|
-
* before a very high max
|
|
87
|
+
* This is to prevent refreshes for common-prefix-lengths that have no peers in the network but happen to be
|
|
88
|
+
* before a very high max common-prefix-length for which we do have peers in the network.
|
|
89
89
|
*
|
|
90
|
-
* The number of 2 * (
|
|
90
|
+
* The number of 2 * (common-prefix-length + 1) can be proved and a proof would have been written here if
|
|
91
91
|
* the programmer had paid more attention in the Math classes at university.
|
|
92
92
|
*
|
|
93
93
|
* So, please be patient and a doc explaining it will be published soon.
|
|
@@ -95,12 +95,12 @@ export class RoutingTableRefresh {
|
|
|
95
95
|
* https://github.com/libp2p/go-libp2p-kad-dht/commit/2851c88acb0a3f86bcfe3cfd0f4604a03db801d8#diff-ad45f4ba97ffbc4083c2eb87a4420c1157057b233f048030d67c6b551855ccf6R219
|
|
96
96
|
*/
|
|
97
97
|
Promise.all(
|
|
98
|
-
|
|
98
|
+
refreshCommonPrefixLengths.map(async (lastRefresh, index) => {
|
|
99
99
|
try {
|
|
100
100
|
await this._refreshCommonPrefixLength(index, lastRefresh, force)
|
|
101
101
|
|
|
102
102
|
if (this._numPeersForCpl(prefixLength) === 0) {
|
|
103
|
-
const lastCpl = Math.min(2 * (index + 1),
|
|
103
|
+
const lastCpl = Math.min(2 * (index + 1), refreshCommonPrefixLengths.length - 1)
|
|
104
104
|
|
|
105
105
|
for (let n = index + 1; n < lastCpl + 1; n++) {
|
|
106
106
|
try {
|
package/dist/typedoc-urls.json
DELETED
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"codec": "https://libp2p.github.io/js-libp2p/functions/_libp2p_kad_dht.MessageType.codec.html",
|
|
3
|
-
"EventTypes": "https://libp2p.github.io/js-libp2p/enums/_libp2p_kad_dht.EventTypes.html",
|
|
4
|
-
".:EventTypes": "https://libp2p.github.io/js-libp2p/enums/_libp2p_kad_dht.EventTypes.html",
|
|
5
|
-
"MessageType": "https://libp2p.github.io/js-libp2p/enums/_libp2p_kad_dht.MessageType-1.html",
|
|
6
|
-
"AddPeerEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.AddPeerEvent.html",
|
|
7
|
-
".:AddPeerEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.AddPeerEvent.html",
|
|
8
|
-
"DHTRecord": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.DHTRecord.html",
|
|
9
|
-
".:DHTRecord": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.DHTRecord.html",
|
|
10
|
-
"DialPeerEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.DialPeerEvent.html",
|
|
11
|
-
".:DialPeerEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.DialPeerEvent.html",
|
|
12
|
-
"FinalPeerEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.FinalPeerEvent.html",
|
|
13
|
-
".:FinalPeerEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.FinalPeerEvent.html",
|
|
14
|
-
"KadDHT": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.KadDHT.html",
|
|
15
|
-
".:KadDHT": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.KadDHT.html",
|
|
16
|
-
"KadDHTComponents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.KadDHTComponents.html",
|
|
17
|
-
".:KadDHTComponents": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.KadDHTComponents.html",
|
|
18
|
-
"KadDHTInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.KadDHTInit.html",
|
|
19
|
-
".:KadDHTInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.KadDHTInit.html",
|
|
20
|
-
"PeerInfoMapper": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.PeerInfoMapper.html",
|
|
21
|
-
".:PeerInfoMapper": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.PeerInfoMapper.html",
|
|
22
|
-
"PeerResponseEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.PeerResponseEvent.html",
|
|
23
|
-
".:PeerResponseEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.PeerResponseEvent.html",
|
|
24
|
-
"ProviderEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ProviderEvent.html",
|
|
25
|
-
".:ProviderEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ProviderEvent.html",
|
|
26
|
-
"ProvidersInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ProvidersInit.html",
|
|
27
|
-
".:ProvidersInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ProvidersInit.html",
|
|
28
|
-
"QueryErrorEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.QueryErrorEvent.html",
|
|
29
|
-
".:QueryErrorEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.QueryErrorEvent.html",
|
|
30
|
-
"ReProvideInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ReProvideInit.html",
|
|
31
|
-
".:ReProvideInit": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ReProvideInit.html",
|
|
32
|
-
"RoutingTable": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.RoutingTable.html",
|
|
33
|
-
".:RoutingTable": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.RoutingTable.html",
|
|
34
|
-
"SelectFn": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.SelectFn.html",
|
|
35
|
-
".:SelectFn": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.SelectFn.html",
|
|
36
|
-
"SendQueryEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.SendQueryEvent.html",
|
|
37
|
-
".:SendQueryEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.SendQueryEvent.html",
|
|
38
|
-
"SingleKadDHT": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.SingleKadDHT.html",
|
|
39
|
-
".:SingleKadDHT": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.SingleKadDHT.html",
|
|
40
|
-
"ValidateFn": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ValidateFn.html",
|
|
41
|
-
".:ValidateFn": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ValidateFn.html",
|
|
42
|
-
"ValueEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ValueEvent.html",
|
|
43
|
-
".:ValueEvent": "https://libp2p.github.io/js-libp2p/interfaces/_libp2p_kad_dht.ValueEvent.html",
|
|
44
|
-
"DHTProgressEvents": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.DHTProgressEvents.html",
|
|
45
|
-
".:DHTProgressEvents": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.DHTProgressEvents.html",
|
|
46
|
-
"MessageName": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.MessageName.html",
|
|
47
|
-
".:MessageName": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.MessageName.html",
|
|
48
|
-
"QueryEvent": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.QueryEvent.html",
|
|
49
|
-
".:QueryEvent": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.QueryEvent.html",
|
|
50
|
-
"Selectors": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.Selectors.html",
|
|
51
|
-
".:Selectors": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.Selectors.html",
|
|
52
|
-
"Validators": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.Validators.html",
|
|
53
|
-
".:Validators": "https://libp2p.github.io/js-libp2p/types/_libp2p_kad_dht.Validators.html",
|
|
54
|
-
"kadDHT": "https://libp2p.github.io/js-libp2p/functions/_libp2p_kad_dht.kadDHT-1.html",
|
|
55
|
-
".:kadDHT": "https://libp2p.github.io/js-libp2p/functions/_libp2p_kad_dht.kadDHT-1.html",
|
|
56
|
-
"passthroughMapper": "https://libp2p.github.io/js-libp2p/functions/_libp2p_kad_dht.passthroughMapper.html",
|
|
57
|
-
"removePrivateAddressesMapper": "https://libp2p.github.io/js-libp2p/functions/_libp2p_kad_dht.removePrivateAddressesMapper.html",
|
|
58
|
-
"removePublicAddressesMapper": "https://libp2p.github.io/js-libp2p/functions/_libp2p_kad_dht.removePublicAddressesMapper.html"
|
|
59
|
-
}
|