123 points · by nevodavid10 · 3y ago · 57 comments
Showing real-time updates of likes, upvotes, and reviews between clients.
Learn about your members through deep analytics.
Deal with an unlimited amount of clicks per second.
You can read the full article here:
https://links.github20k.com/click-vote
The open-source Library is here:
https://github.com/clickvote/clickvote
Please let me know your thoughts!
Am I building something useless?
I don't mean to criticize, but the complexity of this is what I'd expect for something handling hundreds if not thousands of qps. Even then I'd expect you could probably fine-tune a Redis Cluster setup and cross out 2/3 of that architecture diagram. Hell, you don't even need WebSockets: a system like this polling for an integer or two should be scalable to tens of thousands of qps.
I plan to have it as a managed service in the future, which means that it will hold a lot of clients - some big, some small.
But I think I should def make another smaller version without Kafka and Timescale.
Stripe relied entirely on Mongo for storage and queueing at a scale that you'll almost assuredly never reach. That's probably inadvisable today, but the point is that the more systems you have, the more systems you need to maintain and the more things that can break and the more places you'll eventually find bottlenecks.
Actually am I crazy to thing that wouldn’t be the worst thing in the world? Tracking people across multiple sites without their informed consent is of course totally unethical spying, but if it is clear that they are consciously interacting with UI like yours and they know it is shared, that doesn’t seem so bad. (?)
And it could be nice if Pandora would start suggesting soundtracks to movies I’ve upvoted on Amazon or something like that…
You handwaved the idea of consent by saying it's "clear" to the user. But if there isn't a way to opt out then consent isn't addressed at all.
But now sure what to do on failures.
Maybe if you’re running a “upvotes SaaS” the architecture makes sense but the given architecture diagram is more complicated than the production product I work on (https://notion.so).
Are real-time updates a feature users want here? I’ve never used a voting or rating site with real-time updates.
I also feel that your comment is slightly ironic, given the poor performance of Notion. I'm almost thinking (without having any clue about Notion's architecture) that Notion could benefit from a more complex architecture that prioritizes performance.
And yes - Twitter for example?
At least not the Kafka / Timescale feature. It would place nice if you were a bit bigger - a news website, a social media and so on.
It seems very clear to me that many of these sharks have never tried to implement a similar system.
https://media.discordapp.net/attachments/1062038639112097872...
Happy to get some feedback on the product also :)
Unless you're only running one instance of this, it probably makes sense to scale back immediately otherwise your costs are going to balloon. Even then the horizontal scaling requirements of some of the "parallel" subsystems will get incredibly expensive fast.
Horizontal scaling will happen in any way if I just use a simple message queue.
Are there any recommended good self-hosted alternatives? This looks nice but requires quite the stack of services.
It's something that I think about. It can be really great (in my opinion)
a much simpler build system that's easy for people to adopt might have a higher chance of getting initial traction, and then you can add the layers only when they're needed. See YAGNI (You Ain't Gonna Need It) https://martinfowler.com/bliki/Yagni.html
The moment that I need to have my own backend to manage some data, I can add the item rating data as well and your system becomes more complex than the built-in solution.