Github user tdas commented on a diff in the pull request:

    https://github.com/apache/spark/pull/4805#discussion_r26093934
  
    --- Diff: 
external/kafka/src/main/scala/org/apache/spark/streaming/kafka/DirectKafkaInputDStream.scala
 ---
    @@ -84,6 +83,11 @@ class DirectKafkaInputDStream[
     
       protected var currentOffsets = fromOffsets
     
    +  // Map to manage the time -> topic/partition+offset
    +  private val offsetMap = new mutable.HashMap[Time, Map[TopicAndPartition, 
Long]]()
    +  // Add to the listener bus for job completion hook
    +  context.addStreamingListener(new DirectKafkaStreamingListener)
    +
       @tailrec
       protected final def latestLeaderOffsets(retries: Int): 
Map[TopicAndPartition, LeaderOffset] = {
    --- End diff --
    
    Valid point. And the signal to turn on the updating could simply be the 
"group.id" setting. Isnt it?



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to