Hi everyone!

This is my first post in the mailing list, so bear with me.

I have a backend service written in PHP. This service pushes messages to
Apache Kafka (over the topic "posts") when posts are created, read and
removed. I also have a backend service written in Java. This service
consumes messages from Apache Kafka (for the "posts" topic) and push them
out over WebSockets to whoever is listening. This works out great.

The problem I have is as follows. Say, for some reason, the WebSocket
client timeout and because of this he or she does not get some of the
messages. The messages are still being consumed but the client isn't there
to acknowledge them. Now, the client want "rewind" and get all the messages
that they missed may have missed. This is where I'm stuck.

Ideally, the client would provide a timestamp for when they last got a
message and I'd then use that timestamp to get messages from that point and
onwards. I'm not sure if this is even possible, it's just my thoughts.

Currently, I consume messages using the high level API in Java.

Any help in this matter would be truly appreciated!

Cheers,

-- 
Kevin Sjöberg

-- 
Du skapar din faktura, vi skickar den och ser till att kunden betalar. Vi 
sköter allt, hela vägen tills fakturan är betald! 
Läs om Nox Finans här 
<https://www.fortnox.se/nox/?utm_source=signature&utm_medium=email&utm_campaign=noxfinans&utm_term=fakturahantering>
.

Reply via email to