mirror of https://github.com/waku-org/nwaku.git
chore: bumping dependencies for 0.27.0 (#2572)
This commit is contained in:
parent
56dd47d868
commit
f68ac79248
|
@ -45,6 +45,7 @@ import
|
||||||
../../waku/node/peer_manager,
|
../../waku/node/peer_manager,
|
||||||
../../waku/factory/builder,
|
../../waku/factory/builder,
|
||||||
../../waku/common/utils/nat,
|
../../waku/common/utils/nat,
|
||||||
|
../../waku/waku_relay,
|
||||||
./config_chat2
|
./config_chat2
|
||||||
|
|
||||||
import libp2p/protocols/pubsub/rpc/messages, libp2p/protocols/pubsub/pubsub
|
import libp2p/protocols/pubsub/rpc/messages, libp2p/protocols/pubsub/pubsub
|
||||||
|
@ -522,7 +523,7 @@ proc processInput(rfd: AsyncFD, rng: ref HmacDrbgContext) {.async.} =
|
||||||
if msg.contentTopic == chat.contentTopic:
|
if msg.contentTopic == chat.contentTopic:
|
||||||
chat.printReceivedMessage(msg)
|
chat.printReceivedMessage(msg)
|
||||||
|
|
||||||
node.subscribe((kind: PubsubSub, topic: DefaultPubsubTopic), some(handler))
|
node.subscribe((kind: PubsubSub, topic: DefaultPubsubTopic), some(WakuRelayHandler(handler)))
|
||||||
|
|
||||||
if conf.rlnRelay:
|
if conf.rlnRelay:
|
||||||
info "WakuRLNRelay is enabled"
|
info "WakuRLNRelay is enabled"
|
||||||
|
|
|
@ -528,7 +528,7 @@ proc subscribeAndHandleMessages(
|
||||||
else:
|
else:
|
||||||
msgPerContentTopic[msg.contentTopic] = 1
|
msgPerContentTopic[msg.contentTopic] = 1
|
||||||
|
|
||||||
node.subscribe((kind: PubsubSub, topic: pubsubTopic), some(handler))
|
node.subscribe((kind: PubsubSub, topic: pubsubTopic), some(WakuRelayHandler(handler)))
|
||||||
|
|
||||||
when isMainModule:
|
when isMainModule:
|
||||||
# known issue: confutils.nim(775, 17) Error: can raise an unlisted exception: ref IOError
|
# known issue: confutils.nim(775, 17) Error: can raise an unlisted exception: ref IOError
|
||||||
|
|
|
@ -16,7 +16,8 @@ import
|
||||||
../../../waku/waku_node,
|
../../../waku/waku_node,
|
||||||
../../../waku/waku_enr,
|
../../../waku/waku_enr,
|
||||||
../../../waku/waku_discv5,
|
../../../waku/waku_discv5,
|
||||||
../../../waku/factory/builder
|
../../../waku/factory/builder,
|
||||||
|
../../../waku/waku_relay
|
||||||
|
|
||||||
# An accesible bootstrap node. See waku.sandbox fleets.status.im
|
# An accesible bootstrap node. See waku.sandbox fleets.status.im
|
||||||
const bootstrapNode =
|
const bootstrapNode =
|
||||||
|
@ -115,7 +116,7 @@ proc setupAndSubscribe(rng: ref HmacDrbgContext) {.async.} =
|
||||||
contentTopic = msg.contentTopic,
|
contentTopic = msg.contentTopic,
|
||||||
timestamp = msg.timestamp
|
timestamp = msg.timestamp
|
||||||
|
|
||||||
node.subscribe((kind: PubsubSub, topic: pubsubTopic), some(handler))
|
node.subscribe((kind: PubsubSub, topic: pubsubTopic), some(WakuRelayHandler(handler)))
|
||||||
|
|
||||||
when isMainModule:
|
when isMainModule:
|
||||||
let rng = crypto.newRng()
|
let rng = crypto.newRng()
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit 7640cc6aa859f6d4ad657c892f14c76dc1d34bd5
|
Subproject commit 86f212c6a5d76b52e20fad2e318cc5436d04fc26
|
|
@ -1 +1 @@
|
||||||
Subproject commit 7b02247ce74d5ad5630013334f2e347680b02f65
|
Subproject commit 8e49df14007e27370cd1ce77edb2843783b45e6d
|
|
@ -1 +1 @@
|
||||||
Subproject commit 8ff78919aa5a23aecaf4a647e23cfa8ecda6736a
|
Subproject commit 11b9d952a80ec87e2443405a6a5382f9daac51f8
|
|
@ -1 +1 @@
|
||||||
Subproject commit 7516a92eb8339f8fc1de7dd16cfa3d77bce87cd2
|
Subproject commit 1ac1d69f9512d55d15e8218a9dbdff129bf96ddb
|
|
@ -1 +1 @@
|
||||||
Subproject commit 008de2cd425cbca19f7d922e4e8b209d92313752
|
Subproject commit 66864ed4ae18d14a2b4acb4549561efd7755351f
|
|
@ -1 +1 @@
|
||||||
Subproject commit d08ce17144cabe2ac9925bd75a11ad88a607c04e
|
Subproject commit 09b3e11956459ad4c364b353b7f1067f42267997
|
|
@ -1 +1 @@
|
||||||
Subproject commit 223aadeb82d35b57e6dae99f0b325ec6345ce7ff
|
Subproject commit a9687dda1c3e20d5b066d42b33c2a63f018af93f
|
|
@ -1 +1 @@
|
||||||
Subproject commit 1662762c0144854db60632e4115fe596ffa67fca
|
Subproject commit a0c085a51fe4f2d82aa96173ac49b3bfe6043858
|
|
@ -1 +1 @@
|
||||||
Subproject commit 7bb0ccc7842577243edc3b8d61f75bf498551a7a
|
Subproject commit 3c238df6cd4b9c1f37a9f103383e7d2bbd420c13
|
|
@ -1 +1 @@
|
||||||
Subproject commit 04a154eee0b8a2ad313e24ba46a4e5b4e0b9036f
|
Subproject commit 3db16f8ece5d0eba310c8f1ed812c6ff5a21a34a
|
|
@ -1 +1 @@
|
||||||
Subproject commit b5028a44710f0317c5e710c80cec90127aa7e77c
|
Subproject commit e96f3215030cbfa13abc2f5827069b6f8ba87e38
|
|
@ -1 +1 @@
|
||||||
Subproject commit cf0c9cfa408189c6d428799bf2e9da8d0c0f7f08
|
Subproject commit d7e7f1044def3c62d0b4bcec60c0b53876e44d71
|
|
@ -60,58 +60,58 @@ const TopicParameters = TopicParams(
|
||||||
)
|
)
|
||||||
|
|
||||||
# see: https://rfc.vac.dev/spec/29/#gossipsub-v10-parameters
|
# see: https://rfc.vac.dev/spec/29/#gossipsub-v10-parameters
|
||||||
const GossipsubParameters = GossipSubParams(
|
const GossipsubParameters = GossipSubParams.init(
|
||||||
explicit: true,
|
explicit = true,
|
||||||
pruneBackoff: chronos.minutes(1),
|
pruneBackoff = chronos.minutes(1),
|
||||||
unsubscribeBackoff: chronos.seconds(5),
|
unsubscribeBackoff = chronos.seconds(5),
|
||||||
floodPublish: true,
|
floodPublish = true,
|
||||||
gossipFactor: 0.25,
|
gossipFactor = 0.25,
|
||||||
d: 6,
|
d = 6,
|
||||||
dLow: 4,
|
dLow = 4,
|
||||||
dHigh: 8,
|
dHigh = 8,
|
||||||
dScore: 6,
|
dScore = 6,
|
||||||
dOut: 3,
|
dOut = 3,
|
||||||
dLazy: 6,
|
dLazy = 6,
|
||||||
heartbeatInterval: chronos.seconds(1),
|
heartbeatInterval = chronos.seconds(1),
|
||||||
historyLength: 6,
|
historyLength = 6,
|
||||||
historyGossip: 3,
|
historyGossip = 3,
|
||||||
fanoutTTL: chronos.minutes(1),
|
fanoutTTL = chronos.minutes(1),
|
||||||
seenTTL: chronos.minutes(2),
|
seenTTL = chronos.minutes(2),
|
||||||
|
|
||||||
# no gossip is sent to peers below this score
|
# no gossip is sent to peers below this score
|
||||||
gossipThreshold: -100,
|
gossipThreshold = -100,
|
||||||
|
|
||||||
# no self-published msgs are sent to peers below this score
|
# no self-published msgs are sent to peers below this score
|
||||||
publishThreshold: -1000,
|
publishThreshold = -1000,
|
||||||
|
|
||||||
# used to trigger disconnections + ignore peer if below this score
|
# used to trigger disconnections + ignore peer if below this score
|
||||||
graylistThreshold: -10000,
|
graylistThreshold = -10000,
|
||||||
|
|
||||||
# grafts better peers if the mesh median score drops below this. unset.
|
# grafts better peers if the mesh median score drops below this. unset.
|
||||||
opportunisticGraftThreshold: 0,
|
opportunisticGraftThreshold = 0,
|
||||||
|
|
||||||
# how often peer scoring is updated
|
# how often peer scoring is updated
|
||||||
decayInterval: chronos.seconds(12),
|
decayInterval = chronos.seconds(12),
|
||||||
|
|
||||||
# below this we consider the parameter to be zero
|
# below this we consider the parameter to be zero
|
||||||
decayToZero: 0.01,
|
decayToZero = 0.01,
|
||||||
|
|
||||||
# remember peer score during x after it disconnects
|
# remember peer score during x after it disconnects
|
||||||
retainScore: chronos.minutes(10),
|
retainScore = chronos.minutes(10),
|
||||||
|
|
||||||
# p5: application specific, unset
|
# p5: application specific, unset
|
||||||
appSpecificWeight: 0.0,
|
appSpecificWeight = 0.0,
|
||||||
|
|
||||||
# p6: penalizes peers sharing more than threshold ips
|
# p6: penalizes peers sharing more than threshold ips
|
||||||
ipColocationFactorWeight: -50.0,
|
ipColocationFactorWeight = -50.0,
|
||||||
ipColocationFactorThreshold: 5.0,
|
ipColocationFactorThreshold = 5.0,
|
||||||
|
|
||||||
# p7: penalizes bad behaviour (weight and decay)
|
# p7: penalizes bad behaviour (weight and decay)
|
||||||
behaviourPenaltyWeight: -10.0,
|
behaviourPenaltyWeight = -10.0,
|
||||||
behaviourPenaltyDecay: 0.986,
|
behaviourPenaltyDecay = 0.986,
|
||||||
|
|
||||||
# triggers disconnections of bad peers aka score <graylistThreshold
|
# triggers disconnections of bad peers aka score <graylistThreshold
|
||||||
disconnectBadPeers: true,
|
disconnectBadPeers = true,
|
||||||
)
|
)
|
||||||
|
|
||||||
type
|
type
|
||||||
|
|
Loading…
Reference in New Issue