Skip to content

Commit 0f2b3a8

Browse files
committed
Add keepAlive to pub server
1 parent 2e0c79e commit 0f2b3a8

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

pub.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ if (!+argv.l) {
2121
}
2222

2323
const conf = {}
24+
conf.keepAlive = 5000
2425

2526
if (argv.seed) {
2627
conf.seed = argv.seed
@@ -51,7 +52,7 @@ const debug = argv.debug
5152

5253
const seed = Buffer.from(conf.seed, 'hex')
5354

54-
const dht = new HyperDHT()
55+
const dht = new HyperDHT({ connectionKeepAlive: conf.keepAlive })
5556
const keyPair = HyperDHT.keyPair(seed)
5657

5758
const stats = { cid: 0 }

0 commit comments

Comments
 (0)