[
https://issues.apache.org/jira/browse/KAFKA-4680?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17052038#comment-17052038
]
ASF GitHub Bot commented on KAFKA-4680:
---------------------------------------
paolo-moriello commented on pull request #8225: KAFKA-4680: config mismatch
exception on min isr > replication factor
URL: https://github.com/apache/kafka/pull/8225
Added new ConfigurationMismatchException. This is thrown on
appendRecordsToLeader to avoid writing to leader if replication factor < min
insync replicas and acks=all.
At the moment (https://issues.apache.org/jira/browse/KAFKA-4680), Kafka
throwns NotEnoughReplicasException in the case above. This PR aims to introduce
a more specific exception for the case above. NotEnoughReplicasException is
still used when there are not enough insync replicas when trying to append a
record.
Changes:
- add new ConfigurationMismatchException and related Error
- updated documentation for min.insync.replicas
- add test case for the new exception
- updated existing tests
### 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.
For queries about this service, please contact Infrastructure at:
[email protected]
> min.insync.replicas can be set higher than replication factor
> -------------------------------------------------------------
>
> Key: KAFKA-4680
> URL: https://issues.apache.org/jira/browse/KAFKA-4680
> Project: Kafka
> Issue Type: Bug
> Components: config, replication
> Affects Versions: 0.10.0.1
> Reporter: James Cheng
> Assignee: Paolo Moriello
> Priority: Major
>
> It is possible to specify a min.insync.replicas for a topic that is higher
> than the replication factor of the topic. If you do this, you will not be
> able to produce to the topic with acks=all.
> Furthermore, each produce request (including retries) to the topic will emit
> an ERROR level message to the broker debuglogs. If this is not noticed
> quickly enough, it can cause the debuglogs to balloon.
> We actually hosed one of our Kafka clusters because of this. A topic got
> configured with min.insync.replicas > replication factor. It had partitions
> on all brokers of our cluster. The broker logs ballooned and filled up the
> disks. We run these clusters on CoreOS, and CoreOS's etcd database got
> corrupted. (Kafka didn't get corrupted, tho).
> I think Kafka should do validation when someone tries to change a topic to
> min.insync.replicas > replication factor, and reject the change.
> This would presumably affect kafka-topics.sh, kafka-configs.sh, as well as
> the CreateTopics operation that came in KIP-4.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)