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

MixnetClient can send ClientRequests #5381

Open
wants to merge 4 commits into
base: develop
Choose a base branch
from
Open

MixnetClient can send ClientRequests #5381

wants to merge 4 commits into from

Conversation

durch
Copy link
Contributor

@durch durch commented Jan 22, 2025

Ended up adding another channel to the MixnetClient, so that it can signal to the MixTrafficController that can send a ClientRequest via its GatewayTransciver.

Had to add a sleep to the disconnect call as the socket would close before the channel message got processed, briefly considered adding an ack channel so that we can signal back when the message got sent, but opted for simplicity for now. I've also bumped the default timeout to 10 secs.

Looking at this code, I'm not sure if channels between MixnetClient and MixTrafficController are needed, since messages are processed serially, we might be able to pass an Arc<Mutex<MixTrafficController>> to MixnetClient and use it directly, remove a level of indirection from the code, nothing actionable now just shower thoughts...

This change is Reviewable

Copy link

vercel bot commented Jan 22, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

2 Skipped Deployments
Name Status Preview Comments Updated (UTC)
docs-nextra ⬜️ Ignored (Inspect) Visit Preview Jan 26, 2025 9:03pm
nym-next-explorer ⬜️ Ignored (Inspect) Visit Preview Jan 26, 2025 9:03pm

@durch durch added this to the Temporary Home milestone Jan 22, 2025
@durch durch requested a review from jstuczyn January 22, 2025 22:30
@durch durch enabled auto-merge (squash) January 23, 2025 07:09
@durch durch requested a review from octol as a code owner January 26, 2025 18:56
@durch durch changed the title Pre shutdown hooks into GatewayClient MixnetClient can send ClientRequests Jan 26, 2025
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.

1 participant