Can I use exactly-once delivery semantic for mongo source kafka connector?

I want to know if there is a way to change the default delivery semantic of mongo source kafka connector which by default is At-least once, I want to use exactly-once delivery semantic.

Exactly once is not possible today.

1 Like

Why? because even before your application can receive the data, tcp may have already re-transmit the data behind the scenes for multiple times.

That being said, there can only be idempotent processing.

1 Like

Okay…Got it…thanks for the explanation…

My above comment is from low level. From high level, say your app does following:

  1. receive the event
  2. do the thing based on event.
  3. ack to the sender.

No.3 is needed for obvious reason, but no.2 and no.3 is not atomic operation. So what if your app crashes in between? in that case the event has to be resent.

So no exactly once delivery from both low level and high level.

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.