Skip to content

Connection drop causes pubsub to stop working. #1496

@AlexMesser

Description

@AlexMesser
  • Version: 0.40.0
  • Platform: MacOS, Node v16.14.0
  • Subsystem: Pubsub, Relay, ConnectionManager

Severity: High

Description:

I have two peers - Alice and Bob, both connected to the same relay server and subscribed to the same topic.

I need to find all peers subscribed to a given topic, e.g. I call libp2p.pubsub.getSubscribers("my_topic") from the Alice side and expect to see Bob's peer id in response.

When we run both peers the first time, everything works as expected - peers sees each other in topic subscribers. But when some of the peers reconnects (doesn't matter Alice or Bob), they does not see each other anymore. But if I restart one of the peers manually, everything works as expected until next reconnect.

I am using gossibsub for pubsub, but also tried floodsub with the same result.

My issue is very similar to #658.

Steps to reproduce the error:

I created reproduction repository for better explanation.

Metadata

Metadata

Assignees

Labels

need/maintainer-inputNeeds input from the current maintainer(s)

Type

No type

Projects

Status

🎉Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions