Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support producing messages at specific offset #230

Open
technicalpickles opened this issue Jan 10, 2025 · 0 comments
Open

Support producing messages at specific offset #230

technicalpickles opened this issue Jan 10, 2025 · 0 comments
Assignees
Labels
enhancement New feature or request

Comments

@technicalpickles
Copy link

Is your feature request related to a problem? Please describe.

I am porting ruby-kafka consumers to karafka, and some of our consumers make use of the consumed messages offset. Specifically, we store that as metadata on logs, errors, etc

The current implementation doesn't expose the offset at all. Messages use the current size of the messages produced so far, so the first one gets 0, 1, etc.

Describe the solution you'd like

karafka.produce(message_value, key: key) should support an offset option.

Describe alternatives you've considered

It might be enough to be able to set the initial offset offset, ie start from 1337 + number of messages, isntead of just the number of messages

Additional context

https://karafka-io.slack.com/archives/C027C6M2B0U/p1736529486973089

@mensfeld mensfeld self-assigned this Jan 13, 2025
@mensfeld mensfeld added the enhancement New feature or request label Jan 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Development

No branches or pull requests

2 participants