-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Messages are not propagated when only some nodes subscribe a topic #149
Comments
I'm curious how this scenario works using go-libp2p. It seems C won't send the message to B because nodes only send messages to peers which have subscribed to the topic (or direct peers). As far as I know, publishing a message follows something like this:
|
@wemeetagain I also noticed that, both in go code and spec. This is strange though, while I understand that the real world scenarios are bigger topologies, I would expect this to work. What do you think? I did a small test with go daemon and it has the same behaviour and the other peer does not receive messages https://github.com/libp2p/interop/blob/chore/try-3-go-gossipsub-with-hop/test/pubsub/gossipsub/go2go2go.js |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. |
This issue or pull request has been automatically been closed due to inactivity. |
is this still an issue? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. |
Please re-open if current version still causes this issue. The publish logic has been modified |
Let's consider a simple network with 3 peers {A, B, C}, with 2 connections established A<->B and B<->C
In this scenario, if A subscribes to a given topic and C publishes messages to that topic, A should be able to receive the messages.
It seems to me that https://github.com/ChainSafe/js-libp2p-gossipsub/blob/v0.8.0/ts/index.ts#L1034 this should not break here, otherwise we will not grab fanout peers. However, this does not seem to fix the issue, as I tried to do a small hacking in the code but messages were not sent to the peer.
Other than that, should we make
canRelayMessage
options to be true by default? I would expect the default behaviour to relay messages, but users might turn that off if they like.Test scenario to test: libp2p/js-libp2p-interfaces#83 (use this branch as a dep)
@wemeetagain any ideas on what is wrong here?
cc @Gozala
The text was updated successfully, but these errors were encountered: