kafka-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Karthikeyan Annamalai <kannama...@owler.com>
Subject Re: Retrieving last message offset in high level consumer
Date Fri, 02 Oct 2015 02:44:08 GMT
If i am not wrong, the auto commit might have happened so, when you start
the consumer it should work fine. Also keep it in mind that Kafka works on
at least one delivery model so we should expect redundant message while
restarting the consumer.
On Oct 2, 2015 4:06 AM, "eugene miretsky" <eugene.miretsky@gmail.com> wrote:

> Hi,
>
> We would like to log the offset of a Kafka message if we fail to process it
> (so we can try to re-process it later). Is it possible to get the offset
> using the high level consumer?
>
> I took a quick look at the code, and:
>
>    - It seems like the offset it private in the current Scala consumer
>    (ConsumerIterator.scala)
>    - The offset is exposed by the API of the new Java consumer
>    (KafkaConsumer.java)
>
>
> Would it make sense to expose the offset in the  Scala consumer as well?
>
> Cheers,
> Eugene
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message