Hacker News new | past | comments | ask | show | jobs | submit login

Here's just a few examples from my experience:

1. Huge number of messages from test system were accidentally inserted into production.

Queue solution: disable consumers, move messages to a temporary queue while filtering them, move messages back to the old queue, enable consumers

DB solution: just delete rogue messages

2. We want to store some of the messages, but we're not ready to process them yet

Queue solution: create a separate queue for each message type, insert messages to different queues, manually move them when you're ready to process them (and keep in mind that not every queue can persist messages forever, SQS for example can't hold messages longer than 14 days)

DB solution: just skip those messages while processing

3. Consumers went down and the queue now contains a big number of duplicate messages. While it was fine to just wait a couple hours to let it stabilize, a whale customer started complaining

Queue solution: none (any hacky solution would take longer than it takes for the system to naturally stabilize)

DB solution: move whale customer messages to the front of the queue




1. Kafka isn't a message queue, but advance consumer offsets past bad data. Hit person who inserted test data into prod with a cricket bat and then hit person who designed a system where they could do that with the same cricket bat, but harder.

2. Kafka - do what you did with your DB consumers.

3. Kafka - consumers going down can't cause duplicates, what's even going on with your queue?


> what's even going on with your queue?

A message with the latest state of an object gets pushed into queue. When noone is consuming those, you essentially get duplicates: queue contains all of the updates, but you only care about the most recent one.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: