@libp2p/kad-dht 15.1.2-b8600fce8 → 15.1.2-bb4ad31db
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 +1 -1
- package/dist/index.min.js.map +3 -3
- package/dist/src/index.d.ts +2 -1
- package/dist/src/index.d.ts.map +1 -1
- package/dist/src/index.js.map +1 -1
- package/dist/src/kad-dht.d.ts +2 -1
- package/dist/src/kad-dht.d.ts.map +1 -1
- package/dist/src/kad-dht.js +2 -1
- package/dist/src/kad-dht.js.map +1 -1
- package/dist/src/network.d.ts +1 -1
- package/dist/src/network.d.ts.map +1 -1
- package/dist/src/network.js +2 -1
- package/dist/src/network.js.map +1 -1
- package/dist/src/query/manager.js +1 -1
- package/dist/src/query/manager.js.map +1 -1
- package/dist/src/query-self.js +1 -1
- package/dist/src/query-self.js.map +1 -1
- package/dist/src/reprovider.d.ts +1 -1
- package/dist/src/reprovider.d.ts.map +1 -1
- package/dist/src/reprovider.js +1 -1
- package/dist/src/reprovider.js.map +1 -1
- package/dist/src/routing-table/index.d.ts +1 -1
- package/dist/src/routing-table/index.d.ts.map +1 -1
- package/dist/src/routing-table/index.js +2 -1
- package/dist/src/routing-table/index.js.map +1 -1
- package/dist/src/routing-table/refresh.js +1 -1
- package/dist/src/routing-table/refresh.js.map +1 -1
- package/dist/src/topology-listener.d.ts +1 -1
- package/dist/src/topology-listener.d.ts.map +1 -1
- package/dist/src/topology-listener.js +1 -1
- package/dist/src/topology-listener.js.map +1 -1
- package/package.json +13 -12
- package/src/index.ts +2 -1
- package/src/kad-dht.ts +2 -1
- package/src/network.ts +2 -1
- package/src/query/manager.ts +1 -1
- package/src/query-self.ts +1 -1
- package/src/reprovider.ts +1 -1
- package/src/routing-table/index.ts +2 -1
- package/src/routing-table/refresh.ts +1 -1
- package/src/topology-listener.ts +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@libp2p/kad-dht",
|
|
3
|
-
"version": "15.1.2-
|
|
3
|
+
"version": "15.1.2-bb4ad31db",
|
|
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",
|
|
@@ -47,14 +47,14 @@
|
|
|
47
47
|
"doc-check": "aegir doc-check"
|
|
48
48
|
},
|
|
49
49
|
"dependencies": {
|
|
50
|
-
"@libp2p/crypto": "5.1.4-
|
|
51
|
-
"@libp2p/interface": "2.10.2-
|
|
52
|
-
"@libp2p/interface-internal": "2.3.14-
|
|
53
|
-
"@libp2p/peer-collections": "6.0.30-
|
|
54
|
-
"@libp2p/peer-id": "5.1.5-
|
|
55
|
-
"@libp2p/ping": "2.0.32-
|
|
56
|
-
"@libp2p/record": "4.0.6-
|
|
57
|
-
"@libp2p/utils": "6.6.5-
|
|
50
|
+
"@libp2p/crypto": "5.1.4-bb4ad31db",
|
|
51
|
+
"@libp2p/interface": "2.10.2-bb4ad31db",
|
|
52
|
+
"@libp2p/interface-internal": "2.3.14-bb4ad31db",
|
|
53
|
+
"@libp2p/peer-collections": "6.0.30-bb4ad31db",
|
|
54
|
+
"@libp2p/peer-id": "5.1.5-bb4ad31db",
|
|
55
|
+
"@libp2p/ping": "2.0.32-bb4ad31db",
|
|
56
|
+
"@libp2p/record": "4.0.6-bb4ad31db",
|
|
57
|
+
"@libp2p/utils": "6.6.5-bb4ad31db",
|
|
58
58
|
"@multiformats/multiaddr": "^12.4.0",
|
|
59
59
|
"any-signal": "^4.1.1",
|
|
60
60
|
"interface-datastore": "^8.3.1",
|
|
@@ -68,6 +68,7 @@
|
|
|
68
68
|
"it-protobuf-stream": "^2.0.2",
|
|
69
69
|
"it-pushable": "^3.2.3",
|
|
70
70
|
"it-take": "^3.0.8",
|
|
71
|
+
"main-event": "^1.0.1",
|
|
71
72
|
"multiformats": "^13.3.6",
|
|
72
73
|
"p-defer": "^4.0.1",
|
|
73
74
|
"p-event": "^6.0.1",
|
|
@@ -79,9 +80,9 @@
|
|
|
79
80
|
"uint8arrays": "^5.1.0"
|
|
80
81
|
},
|
|
81
82
|
"devDependencies": {
|
|
82
|
-
"@libp2p/interface-compliance-tests": "6.4.8-
|
|
83
|
-
"@libp2p/logger": "5.1.18-
|
|
84
|
-
"@libp2p/peer-store": "11.2.2-
|
|
83
|
+
"@libp2p/interface-compliance-tests": "6.4.8-bb4ad31db",
|
|
84
|
+
"@libp2p/logger": "5.1.18-bb4ad31db",
|
|
85
|
+
"@libp2p/peer-store": "11.2.2-bb4ad31db",
|
|
85
86
|
"@types/lodash.random": "^3.2.9",
|
|
86
87
|
"@types/lodash.range": "^3.2.9",
|
|
87
88
|
"@types/sinon": "^17.0.4",
|
package/src/index.ts
CHANGED
|
@@ -135,11 +135,12 @@
|
|
|
135
135
|
import { KadDHT as KadDHTClass } from './kad-dht.js'
|
|
136
136
|
import { MessageType } from './message/dht.js'
|
|
137
137
|
import { removePrivateAddressesMapper, removePublicAddressesMapper, passthroughMapper } from './utils.js'
|
|
138
|
-
import type { Libp2pEvents, ComponentLogger,
|
|
138
|
+
import type { Libp2pEvents, ComponentLogger, Metrics, PeerId, PeerInfo, PeerStore, RoutingOptions, PrivateKey, AbortOptions } from '@libp2p/interface'
|
|
139
139
|
import type { AddressManager, ConnectionManager, Registrar } from '@libp2p/interface-internal'
|
|
140
140
|
import type { Ping } from '@libp2p/ping'
|
|
141
141
|
import type { AdaptiveTimeoutInit } from '@libp2p/utils/adaptive-timeout'
|
|
142
142
|
import type { Datastore } from 'interface-datastore'
|
|
143
|
+
import type { TypedEventTarget } from 'main-event'
|
|
143
144
|
import type { CID } from 'multiformats/cid'
|
|
144
145
|
import type { ProgressEvent } from 'progress-events'
|
|
145
146
|
|
package/src/kad-dht.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { NotFoundError,
|
|
1
|
+
import { NotFoundError, contentRoutingSymbol, peerDiscoverySymbol, peerRoutingSymbol, serviceCapabilities, serviceDependencies, start, stop } from '@libp2p/interface'
|
|
2
2
|
import drain from 'it-drain'
|
|
3
|
+
import { setMaxListeners, TypedEventEmitter } from 'main-event'
|
|
3
4
|
import pDefer from 'p-defer'
|
|
4
5
|
import { ALPHA, ON_PEER_CONNECT_TIMEOUT, PROTOCOL } from './constants.js'
|
|
5
6
|
import { ContentFetching } from './content-fetching/index.js'
|
package/src/network.ts
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { InvalidParametersError
|
|
1
|
+
import { InvalidParametersError } from '@libp2p/interface'
|
|
2
2
|
import { Libp2pRecord } from '@libp2p/record'
|
|
3
3
|
import { AdaptiveTimeout } from '@libp2p/utils/adaptive-timeout'
|
|
4
4
|
import { pbStream } from 'it-protobuf-stream'
|
|
5
|
+
import { TypedEventEmitter } from 'main-event'
|
|
5
6
|
import { Message } from './message/dht.js'
|
|
6
7
|
import { fromPbPeerInfo } from './message/utils.js'
|
|
7
8
|
import {
|
package/src/query/manager.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { setMaxListeners } from '@libp2p/interface'
|
|
2
1
|
import { createScalableCuckooFilter } from '@libp2p/utils/filters'
|
|
3
2
|
import { anySignal } from 'any-signal'
|
|
4
3
|
import merge from 'it-merge'
|
|
4
|
+
import { setMaxListeners } from 'main-event'
|
|
5
5
|
import { pEvent } from 'p-event'
|
|
6
6
|
import { raceSignal } from 'race-signal'
|
|
7
7
|
import { toString as uint8ArrayToString } from 'uint8arrays/to-string'
|
package/src/query-self.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { setMaxListeners } from '@libp2p/interface'
|
|
2
1
|
import { anySignal } from 'any-signal'
|
|
3
2
|
import length from 'it-length'
|
|
4
3
|
import { pipe } from 'it-pipe'
|
|
5
4
|
import take from 'it-take'
|
|
5
|
+
import { setMaxListeners } from 'main-event'
|
|
6
6
|
import pDefer from 'p-defer'
|
|
7
7
|
import { QUERY_SELF_INTERVAL, QUERY_SELF_TIMEOUT, K, QUERY_SELF_INITIAL_INTERVAL } from './constants.js'
|
|
8
8
|
import { timeOperationMethod } from './utils.js'
|
package/src/reprovider.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { TypedEventEmitter, setMaxListeners } from '@libp2p/interface'
|
|
2
1
|
import { AdaptiveTimeout } from '@libp2p/utils/adaptive-timeout'
|
|
3
2
|
import { Queue } from '@libp2p/utils/queue'
|
|
4
3
|
import drain from 'it-drain'
|
|
4
|
+
import { TypedEventEmitter, setMaxListeners } from 'main-event'
|
|
5
5
|
import { PROVIDERS_VALIDITY, REPROVIDE_CONCURRENCY, REPROVIDE_INTERVAL, REPROVIDE_MAX_QUEUE_SIZE, REPROVIDE_THRESHOLD, REPROVIDE_TIMEOUT } from './constants.js'
|
|
6
6
|
import { parseProviderKey, readProviderTime, timeOperationMethod } from './utils.js'
|
|
7
7
|
import type { ContentRouting } from './content-routing/index.js'
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { start, stop } from '@libp2p/interface'
|
|
2
2
|
import { AdaptiveTimeout } from '@libp2p/utils/adaptive-timeout'
|
|
3
3
|
import { PeerQueue } from '@libp2p/utils/peer-queue'
|
|
4
4
|
import { anySignal } from 'any-signal'
|
|
5
5
|
import parallel from 'it-parallel'
|
|
6
|
+
import { TypedEventEmitter, setMaxListeners } from 'main-event'
|
|
6
7
|
import * as utils from '../utils.js'
|
|
7
8
|
import { ClosestPeers } from './closest-peers.js'
|
|
8
9
|
import { KBucket, isLeafBucket } from './k-bucket.js'
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { randomBytes } from '@libp2p/crypto'
|
|
2
|
-
import { setMaxListeners } from '@libp2p/interface'
|
|
3
2
|
import { peerIdFromMultihash } from '@libp2p/peer-id'
|
|
4
3
|
import { anySignal } from 'any-signal'
|
|
5
4
|
import length from 'it-length'
|
|
5
|
+
import { setMaxListeners } from 'main-event'
|
|
6
6
|
import * as Digest from 'multiformats/hashes/digest'
|
|
7
7
|
import { sha256 } from 'multiformats/hashes/sha2'
|
|
8
8
|
import { xor as uint8ArrayXor } from 'uint8arrays/xor'
|
package/src/topology-listener.ts
CHANGED