slowlydev / f1-dash

A real-time F1 dashboard
https://f1-dash.com
GNU General Public License v3.0
412 stars 39 forks source link

refactor(rewrite): use server sent events #69

Closed simylein closed 4 months ago

simylein commented 4 months ago

This pr switches from web sockets to server sent events for performance reasons. It does however not rewrite the translation logic and therefore also not perform partial updates. I tested it locally and it seemed to work, please let me know if you need anything else.

vercel[bot] commented 4 months ago

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

Name Status Preview Comments Updated (UTC)
f1-dash ✅ Ready (Inspect) Visit Preview 💬 Add feedback Mar 4, 2024 5:12pm
simylein commented 4 months ago

Hello 👋🏻 Foremost, thanks for the rewrite to Server Sent Events, I appreciate a lot!

I made some comments on the socket about handling crashes and testing. Also, I see you added a lot of files, some of which I don't think are necessary, and I would prefer them being stripped to keep the code base small.

I am also not sure if it's necessary to log all the requests, responses and all logs. I mostly worry about performance while flushing is happening and If outbound traffic remains stable during it.

The logging is not necessary, but performance wise it can handle it with ease. I just like a robust logging system which we can look back to if things go south. I don't like being blind folded