Uploaded image for project: 'Flink'
  1. Flink
  2. FLINK-18865

Missing documentation of FlinkKafkaConsumer.setStartFromEarliest behavior when a partition offset becomes out of range

    XMLWordPrintableJSON

Details

    Description

      Flink documentation is missing a clear explanation of the Kafka consumer behavior configured with "setStartFromEarliest()" when a partition offset becomes out of range.

      We see the following log messages when running Flink application with Kafka topics with a configured retention period and Kafka consumer configured with "setStartFromEarliest()".

      org.apache.kafka.clients.consumer.internals.Fetcher.parseCompletedFetch(Fetcher.java:999)
      org.apache.kafka.clients.consumer.internals.Fetcher 
      [Consumer clientId=consumer-3, groupId=some-consumer] Fetch offset 12956961 is out of range for partition some_topic-80, resetting offset ...]

      Affected partition offset is being reset according to "auto.offset.reset" setting in the properties with "latest" as a default value that may contradict expectations when using "setStartFromEarliest()" configuration method and to cause an unexpected loss of data. 

      Flink documentation should provide a clear explanation for this behavior.

       

      Attachments

        Issue Links

          Activity

            People

              vkotovs Vladimirs Kotovs
              vkotovs Vladimirs Kotovs
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: