Databases · Flashcard

Which requirement genuinely calls for Kafka rather than a queue table in PostgreSQL?

  • AIndependent consumer groups replaying a retained, ordered log at sustained high throughput
  • BA single worker pool draining tasks reliably, where each task must be handled exactly once
  • CA handful of background jobs that have to run in order and survive an application restart
  • DA flow where the producer needs to learn whether a consumer finished handling its message

Why this is the answer

The distinguishing features are retention and independent offsets: several consumers reading the same stream at their own pace, replaying history after a bug, at a volume a single database cannot sustain. Exactly-once handling by one worker pool, a few ordered durable jobs, and request/response style completion are all comfortable for a queue table with SKIP LOCKED.

Official docs
Study in Gnoseed →