prateekm commented on a change in pull request #993: SAMZA-2164: Close the 
consumer after reading checkpoints
URL: https://github.com/apache/samza/pull/993#discussion_r275086290
 
 

 ##########
 File path: 
samza-kafka/src/main/scala/org/apache/samza/checkpoint/kafka/KafkaCheckpointManager.scala
 ##########
 @@ -128,11 +128,11 @@ class KafkaCheckpointManager(checkpointSpec: 
KafkaStreamSpec,
     info(s"Reading checkpoint for taskName $taskName")
 
     if (taskNamesToCheckpoints == null) {
-      debug("Reading checkpoints for the first time")
+      info("Reading checkpoints for the first time")
       taskNamesToCheckpoints = readCheckpoints()
-    } else {
-      debug("Updating existing checkpoint mappings")
-      taskNamesToCheckpoints ++= readCheckpoints()
+      // Stop the system consumer since we only need to read checkpoints once
 
 Review comment:
   'it' == systemConsumer. That way we won't break anything if something does 
rely on reading multiple times, and will still get the perf improvement for the 
happy path where we don't.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to