Skip to content

MINOR: Include additional detail in fetch error message#6036

Merged
hachikuji merged 2 commits intoapache:trunkfrom
hachikuji:minor-improve-fetch-error-message
Dec 17, 2018
Merged

MINOR: Include additional detail in fetch error message#6036
hachikuji merged 2 commits intoapache:trunkfrom
hachikuji:minor-improve-fetch-error-message

Conversation

@hachikuji
Copy link
Copy Markdown
Contributor

Issues such as KAFKA-7656 would be easier to debug if the error message included additional detail about the fetch request.

Committer Checklist (excluded from commit message)

  • Verify design and implementation
  • Verify test coverage and CI build status
  • Verify documentation (including upgrade notes)

@huangyiminghappy
Copy link
Copy Markdown
Contributor

#6002 @hachikuji could you help me review the pr? thank you

case OrdinaryConsumerId => "consumer"
case DebuggingConsumerId => "debug consumer"
case FutureLocalReplicaId => "future local replica"
case id if isValidBrokerId(id) => s"replica [$replicaId]"
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't really matter, but you have $replicaId here and $id below


val fetchSource = Request.describeReplicaId(replicaId)
error(s"Error processing fetch with max size $adjustedMaxBytes from $fetchSource " +
s"on partition $tp: $fetchInfo", e)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Offset is not longer included in this error message. Is that intentional?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's part of PartitionData.

Copy link
Copy Markdown
Member

@mumrah mumrah left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM :shipit:

@hachikuji hachikuji merged commit 4039226 into apache:trunk Dec 17, 2018
hachikuji added a commit that referenced this pull request Dec 18, 2018
This patch adds additional information in the log message after a fetch failure to make debugging easier.

Reviewers: David Arthur <mumrah@gmail.com>
pengxiaolong pushed a commit to pengxiaolong/kafka that referenced this pull request Jun 14, 2019
This patch adds additional information in the log message after a fetch failure to make debugging easier.

Reviewers: David Arthur <mumrah@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants