Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -522,7 +522,7 @@ class GroupMetadataManager(brokerId: Int,
// buffer may not be needed if records are read from memory
var buffer = ByteBuffer.allocate(0)

// loop breaks if leader changes at any time during the load, since getHighWatermark is -1
// loop breaks if leader changes at any time during the load, since logEndOffset is -1
val loadedOffsets = mutable.Map[GroupTopicPartition, CommitRecordMetadataAndOffset]()
val pendingOffsets = mutable.Map[Long, mutable.Map[GroupTopicPartition, CommitRecordMetadataAndOffset]]()
val loadedGroups = mutable.Map[String, GroupMetadata]()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -287,13 +287,13 @@ class TransactionStateManager(brokerId: Int,

replicaManager.getLog(topicPartition) match {
case None =>
warn(s"Attempted to load offsets and group metadata from $topicPartition, but found no log")
warn(s"Attempted to load transaction metadata from $topicPartition, but found no log")

case Some(log) =>
// buffer may not be needed if records are read from memory
var buffer = ByteBuffer.allocate(0)

// loop breaks if leader changes at any time during the load, since getHighWatermark is -1
// loop breaks if leader changes at any time during the load, since logEndOffset is -1
var currOffset = log.logStartOffset

try {
Expand All @@ -312,7 +312,7 @@ class TransactionStateManager(brokerId: Int,
// minOneMessage = true in the above log.read means that the buffer may need to be grown to ensure progress can be made
if (buffer.capacity < bytesNeeded) {
if (config.transactionLogLoadBufferSize < bytesNeeded)
warn(s"Loaded offsets and group metadata from $topicPartition with buffer larger ($bytesNeeded bytes) than " +
warn(s"Loaded transaction metadata from $topicPartition with buffer larger ($bytesNeeded bytes) than " +
s"configured transaction.state.log.load.buffer.size (${config.transactionLogLoadBufferSize} bytes)")

buffer = ByteBuffer.allocate(bytesNeeded)
Expand Down