A malformed sanitation-route event repeatedly crashes a parser in the main Kafka consumer group. What handling approach keeps the healthy stream moving?
Select an answer to reveal the explanation.
Short Explanation
One rotten apple should not stop the whole truck. Park the bad event on a dead-letter side path, fix it later, and let good sanitation messages keep flowing. That is poison-message hygiene for city buses.
Full Explanation
Poison or malformed sanitation-route events that crash parsers should be routed to a dead-letter path so the main consumer group keeps processing healthy messages. Isolating bad payloads protects citywide stream progress while preserving the failing event for inspection, replay, or producer remediation. That handling approach is standard operational resilience for municipal Kafka pipelines.
Halting the entire topic until every historical message is manually perfect converts one bad record into a denial of service against all consumers. Increasing partition count alone does not isolate a bad payload; the crashing consumer can still hit the poison message and stall progress on its assigned partitions. Deleting the consumer group and hoping producers stop sending bad data abandons offsets and offers no systematic quarantine or repair path.
Exam caveat: dead-letter routes need retention, alerting, and ownership—otherwise poison messages silently accumulate without fixing the producer schema or validation bug. Operational check: inject a deliberately malformed test event, confirm the main consumer continues, verify the event lands in the dead-letter path with enough metadata to identify the producer, and page the owning team.