Skip to content
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

Peers join subclusters before being instructed to do so #905

Open
garth opened this issue Jan 30, 2024 · 0 comments
Open

Peers join subclusters before being instructed to do so #905

garth opened this issue Jan 30, 2024 · 0 comments

Comments

@garth
Copy link

garth commented Jan 30, 2024

If a peer has previously connected to a subcluster, the next time it starts it will re-join the subcluster after 30 seconds even though the application has not yet created the subcluster.

This causes a number of issues. When a peer comes online, other peers in the subcluster are notified and start sending messages, but since that peer has not yet joined the subcluster there are not event handlers configured for those messages. Also when the peer does decide to connect to the subcluster, peers are not notified since the #join event was already sent prematurely.

What OS are you using (uname -a, or Windows version)?

Darwin Garths-MacBook-Pro.local 23.2.0 Darwin Kernel Version 23.2.0: Wed Nov 15 21:53:18 PST 2023; root:xnu-10002.61.3~2/RELEASE_ARM64_T6000 arm64

What version Socket Runtime are you using?

0.5.4 (97fa3f7c)
Installation path: /Users/garth/Projects/socket-editor/node_modules/.pnpm/@[email protected]/node_modules/@socketsupply/socket-darwin-arm64/

I also tried this on the latest master branch but the results are the same.

0.5.4 (ef7fb555)
Installation path: /Users/garth/.local/share/socket/

What programming language are you using (C/C++/Go/Rust)?

node --version
v20.11.0

What did you expect to see and what you saw instead?

I would expect that subcluster peers are only notified of another peer joining when the peer actually connects to the subcluster and is ready to receive messages.

@garth garth changed the title Peers join subclusters when not instructed to do so Peers join subclusters before being instructed to do so Jan 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant