mirror of
https://github.com/vacp2p/nim-libp2p.git
synced 2026-01-10 12:58:05 -05:00
Compare commits
9 Commits
quic-large
...
dev/etan/z
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
65d57c0aff | ||
|
|
1ac8cf9010 | ||
|
|
280bcc519f | ||
|
|
0011a5e720 | ||
|
|
be26c88311 | ||
|
|
13870b2ae6 | ||
|
|
1b8a7d2713 | ||
|
|
87d2322622 | ||
|
|
4379fabd8a |
@@ -566,7 +566,7 @@ method publish*(g: GossipSub,
|
||||
trace "Publishing message on topic", data = data.shortLog
|
||||
|
||||
if topic.len <= 0: # data could be 0/empty
|
||||
debug "Empty topic, skipping publish"
|
||||
info "Empty topic, skipping publish"
|
||||
return 0
|
||||
|
||||
var peers: HashSet[PubSubPeer]
|
||||
@@ -617,9 +617,9 @@ method publish*(g: GossipSub,
|
||||
|
||||
if peers.len == 0:
|
||||
let topicPeers = g.gossipsub.getOrDefault(topic).toSeq()
|
||||
debug "No peers for topic, skipping publish", peersOnTopic = topicPeers.len,
|
||||
connectedPeers = topicPeers.filterIt(it.connected).len,
|
||||
topic
|
||||
info "No peers for topic, skipping publish", peersOnTopic = topicPeers.len,
|
||||
connectedPeers = topicPeers.filterIt(it.connected).len,
|
||||
topic
|
||||
libp2p_gossipsub_failed_publish.inc()
|
||||
return 0
|
||||
|
||||
@@ -631,7 +631,7 @@ method publish*(g: GossipSub,
|
||||
inc g.msgSeqno
|
||||
Message.init(some(g.peerInfo), data, topic, some(g.msgSeqno), g.sign)
|
||||
msgId = g.msgIdProvider(msg).valueOr:
|
||||
trace "Error generating message id, skipping publish",
|
||||
info "Error generating message id, skipping publish",
|
||||
error = error
|
||||
libp2p_gossipsub_failed_publish.inc()
|
||||
return 0
|
||||
@@ -642,7 +642,7 @@ method publish*(g: GossipSub,
|
||||
|
||||
if g.addSeen(msgId):
|
||||
# custom msgid providers might cause this
|
||||
trace "Dropping already-seen message"
|
||||
info "Dropping already-seen message"
|
||||
return 0
|
||||
|
||||
g.mcache.put(msgId, msg)
|
||||
|
||||
Reference in New Issue
Block a user