3 ms·
Depending on your traffic levels, this could be possible. But Kafka has storage limits based on time and disk, so things can fall off the queue over time. If yo
by Jemaclus 3y ago
Depending on your traffic levels, this could be possible. But Kafka has storage limits based on time and disk, so things can fall off the queue over time. If you have a small system, you can just have your consumer start from the beginning of the topic and consume everything in order to get the list. But that could be a lot of information to sift through to find nothing at all (maybe I don't have notifications, for example). Also keep in my Kafka is a distributed log, effectively, and not a database.
A more pragmatic and simple approach would be to have the consumer shove it into a database, then your app pulls from the DB. This is more persistent and is optimized for the kinds of queries you want to pull.