hachikuji commented on code in PR #11951:
URL: https://github.com/apache/kafka/pull/11951#discussion_r857852045
##########
core/src/main/scala/kafka/server/BrokerLifecycleManager.scala:
##########
@@ -333,7 +353,11 @@ class BrokerLifecycleManager(val config: KafkaConfig,
}
private def sendBrokerHeartbeat(): Unit = {
- val metadataOffset = _highestMetadataOffsetProvider()
+ val metadataOffset = if (readyToUnfence) {
Review Comment:
Ok, I think I get it now. We don't begin publishing until the controller
lets us know that we are caught up. That's the part I was missing. We might
need to step back and reconsider this. Letting the reported offset in
`BrokerHeartbeat` mean different things depending on the context seems
undesirable. Does it give us any additional guarantees? Even after the
controller marks the follower as "caught up," there is still a delay before the
broker can publish the data. Additionally, would it be possible for the offset
to go backwards when we switch to the published offset? It would be odd if we
could end up going back to an offset which was not considered caught up. What
do you think?
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]