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 2022/06/21 22:40:34 UTC
[GitHub] [kafka] hachikuji opened a new pull request, #12328: MINOR: Add ineligible replica reason to log message
hachikuji opened a new pull request, #12328:
URL: https://github.com/apache/kafka/pull/12328
It's useful if the message about ineligible replicas added in https://github.com/apache/kafka/commit/f83d95d9a28267f7ef7a7b1e584dcdb4aa842210#diff-a52da12861f5f9722a73c354a650e4b9af3e7ccce560d7e0d1e67c299e000b58 explains the reason the replica is ineligible.
### Committer Checklist (excluded from commit message)
- [ ] Verify design and implementation
- [ ] Verify test coverage and CI build status
- [ ] Verify documentation (including upgrade notes)
--
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: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [kafka] hachikuji merged pull request #12328: MINOR: Add ineligible replica reason to log message
Posted by GitBox <gi...@apache.org>.
hachikuji merged PR #12328:
URL: https://github.com/apache/kafka/pull/12328
--
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: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [kafka] hachikuji commented on a diff in pull request #12328: MINOR: Add ineligible replica reason to log message
Posted by GitBox <gi...@apache.org>.
hachikuji commented on code in PR #12328:
URL: https://github.com/apache/kafka/pull/12328#discussion_r904038432
##########
metadata/src/main/java/org/apache/kafka/controller/ReplicationControlManager.java:
##########
@@ -1125,13 +1125,11 @@ private Errors validateAlterPartitionData(
return INVALID_REQUEST;
}
- List<Integer> ineligibleReplicas = partitionData.newIsr().stream()
- .filter(replica -> !isEligibleReplica.apply(replica))
Review Comment:
Thanks for the reminder. Forgot about 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.
To unsubscribe, e-mail: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [kafka] dajac commented on a diff in pull request #12328: MINOR: Add ineligible replica reason to log message
Posted by GitBox <gi...@apache.org>.
dajac commented on code in PR #12328:
URL: https://github.com/apache/kafka/pull/12328#discussion_r903319379
##########
metadata/src/main/java/org/apache/kafka/controller/ReplicationControlManager.java:
##########
@@ -1125,13 +1125,11 @@ private Errors validateAlterPartitionData(
return INVALID_REQUEST;
}
- List<Integer> ineligibleReplicas = partitionData.newIsr().stream()
- .filter(replica -> !isEligibleReplica.apply(replica))
Review Comment:
nit: I think that we could remove `isEligibleReplica` from the function params. It is not used anymore.
--
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: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [kafka] dajac commented on a diff in pull request #12328: MINOR: Add ineligible replica reason to log message
Posted by GitBox <gi...@apache.org>.
dajac commented on code in PR #12328:
URL: https://github.com/apache/kafka/pull/12328#discussion_r903713010
##########
metadata/src/main/java/org/apache/kafka/controller/ReplicationControlManager.java:
##########
@@ -1125,13 +1125,11 @@ private Errors validateAlterPartitionData(
return INVALID_REQUEST;
}
- List<Integer> ineligibleReplicas = partitionData.newIsr().stream()
- .filter(replica -> !isEligibleReplica.apply(replica))
- .collect(Collectors.toList());
+ List<IneligibleReplica> ineligibleReplicas = ineligibleReplicasForIsr(newIsr);
if (!ineligibleReplicas.isEmpty()) {
log.info("Rejecting AlterPartition request from node {} for {}-{} because " +
"it specified ineligible replicas {} in the new ISR {}.",
- brokerId, topic.name, partitionId, ineligibleReplicas, partitionData.newIsr());
Review Comment:
nit: We may want to revert this change in order to remain consistent with the other log line in this method.
--
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: jira-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org