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

Investigate sending shared data through websockets #1

Open
adryzz opened this issue Jul 31, 2023 · 0 comments
Open

Investigate sending shared data through websockets #1

adryzz opened this issue Jul 31, 2023 · 0 comments
Assignees
Labels
enhancement New feature or request help wanted Extra attention is needed performance something that improves performance upstream An issue with an upstream dependency

Comments

@adryzz
Copy link
Owner

adryzz commented Jul 31, 2023

This server is supposed to have a lot of open websockets, and sending messages to thousands if not tens of thousands of clients through a websocket is an expensive operation, especially if a clone is involved.

axum uses tungstenite-rs as its default websocket implementation, which currently requires cloning data (no Arc<T> either). This is being tracked over at snapview/tungstenite-rs#96.

This would really speed things up, as there isn't THAT much more we can do to improve performance other than there, as shown by the flamegraph.
flamegraph

@adryzz adryzz added enhancement New feature or request help wanted Extra attention is needed performance something that improves performance upstream An issue with an upstream dependency labels Jul 31, 2023
@adryzz adryzz self-assigned this Jul 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed performance something that improves performance upstream An issue with an upstream dependency
Projects
None yet
Development

No branches or pull requests

1 participant