You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by GitBox <gi...@apache.org> on 2020/12/10 23:20:28 UTC

[GitHub] [kafka] kowshik commented on a change in pull request #9718: KAFKA-10832: Fix Log to use the correct ProducerStateManager instance when updating producers

kowshik commented on a change in pull request #9718:
URL: https://github.com/apache/kafka/pull/9718#discussion_r540573082



##########
File path: core/src/main/scala/kafka/log/Log.scala
##########
@@ -2670,6 +2573,112 @@ object Log {
   private def isLogFile(file: File): Boolean =
     file.getPath.endsWith(LogFileSuffix)
 
+  // Rebuild producer state until lastOffset. This method may be called from the recovery code path, and thus must be
+  // free of all side-effects, i.e. it must not update any log-specific state.
+  private def rebuildProducerState(log: Log,

Review comment:
       That is true. Do you feel the original approach in f0466b2420dc500112b4839678564996c0677d2e was better, where, we didn't move methods into a companion object? I'd be happy to revert to that.




----------------------------------------------------------------
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:
users@infra.apache.org