(no title)
ikornaselur | 1 year ago
Notiflux (https://github.com/ikornaselur/notiflux): a small WebSocket broadcast server, the idea being that clients connect with WebSocket (such as a website) and then any source can send a POST request to the API to broadcast messages, allowing for real-time functionality from servers that don't support WebSockets, or you might have multiple sources that each might broadcast messages.
Auth is done by Notiflux having a public key and the sources have the corresponding private key, JWT tokens signed with the private key include topics and scope (subscribe or broadcast to the topics). Clients would auth with an API for example, get a JWT with maybe a 10 second expiry, use it to subscribe to the topics that the API would then broadcast to through Notiflux.
It was an excuse as well to play with WebSocket in Rust and learn a little bit about the Actor Pattern.
If I would continue I'd want to explore how well it scales, how much traffic it could handle and look into horizontal scaling, but I feel like it's complete enough as a toy project.
No comments yet.