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

Extend Chat Example w/ Gossip Based Backend #1120

Merged
merged 9 commits into from
May 1, 2024

Conversation

rohitkulshreshtha
Copy link
Contributor

Added a gossip-based backend for the chat example.

The implementation is based on "Epidemic algorithms for replicated database maintenance". Specifically, it implements push-based "rumor-mongering" with a blind-coin removal process.

Copy link

cloudflare-pages bot commented Mar 26, 2024

Deploying hydroflow with  Cloudflare Pages  Cloudflare Pages

Latest commit: 7271227
Status: ✅  Deploy successful!
Preview URL: https://9126cf52.hydroflow.pages.dev
Branch Preview URL: https://rohit-randomized-gossip.hydroflow.pages.dev

View logs

@rohitkulshreshtha rohitkulshreshtha marked this pull request as ready for review March 26, 2024 21:41
Copy link
Member

@MingweiSamuel MingweiSamuel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

First thought is that it would be best to have separate regular vs gossip version of chat, what do you think?

Copy link
Contributor

@jhellerstein jhellerstein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Can you augment the README to discuss the different roles and how they work?

@rohitkulshreshtha
Copy link
Contributor Author

First thought is that it would be best to have separate regular vs gossip version of chat, what do you think?

In one of the stand-ups, Joe suggested interop with the existing client as a goal. This seems like the easiest way to do that. What'd you have in mind?

Copy link
Member

@MingweiSamuel MingweiSamuel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok, sounds good to me then

hydroflow/examples/chat/main.rs Show resolved Hide resolved
hydroflow/examples/chat/main.rs Outdated Show resolved Hide resolved
hydroflow/examples/chat/randomized_gossiping_server.rs Outdated Show resolved Hide resolved
@jhellerstein
Copy link
Contributor

First thought is that it would be best to have separate regular vs gossip version of chat, what do you think?

In one of the stand-ups, Joe suggested interop with the existing client as a goal. This seems like the easiest way to do that. What'd you have in mind?

The current code supports letting readers see the distinction between single-server vs gossiping-server, and run either one from the command line. The README.md should talk that through in a bit more detail is all.

@rohitkulshreshtha
Copy link
Contributor Author

The current code supports letting readers see the distinction between single-server vs gossiping-server, and run either one from the command line. The README.md should talk that through in a bit more detail is all.

This is done. The new readme can also be run straight from the IDE (at least IntelliJ at the moment, unsure what vscode does with shell code blocks.

Copy link
Contributor

@jhellerstein jhellerstein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Added a gossip-based backend for the chat example.

The implementation is based on ["Epidemic algorithms for
replicated database maintenance"](https://dl.acm.org/doi/epdf/10.1145/41840.41841).
Specifically, it implements push-based "rumor-mongering"
with a blind-coin removal process.
Also added a test for the gossip server.
@rohitkulshreshtha
Copy link
Contributor Author

Only conventional commits didn't pass, so squashing and merging. Wondering if we should configure that check differently.

@rohitkulshreshtha rohitkulshreshtha merged commit 55051e1 into main May 1, 2024
10 of 11 checks passed
@rohitkulshreshtha rohitkulshreshtha deleted the rohit_randomized_gossip branch May 21, 2024 16:43
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

Successfully merging this pull request may close these issues.

None yet

3 participants