KAFKA-19809 CheckStyle version upgrade: 10 -->> 12#20726
KAFKA-19809 CheckStyle version upgrade: 10 -->> 12#20726chia7712 merged 1 commit intoapache:trunkfrom
Conversation
| <module name="ClassFanOutComplexity"> | ||
| <!-- default is 20 --> | ||
| <property name="max" value="52"/> | ||
| <property name="max" value="55"/> |
There was a problem hiding this comment.
Options:
- increase limit (like here)
- create a baseline (skip/suppress this check for existing cases/classes)
- change existing classes and keep the old property value max limit
| <suppress checks="ImportControl" files="(JaasTestUtils).java" /> | ||
|
|
||
| <suppress checks="FinalLocalVariable" files="."/> | ||
| <suppress checks="FinalParameters" files="."/> |
There was a problem hiding this comment.
From my POV both of these checks are overzealous and hence I turned them off, but I'm open to a discussion.
Related links:
- https://checkstyle.sourceforge.io/checks/misc/finalparameters.html
- https://checkstyle.sourceforge.io/checks/coding/finallocalvariable.html
- https://softwareengineering.stackexchange.com/questions/48413/in-java-should-i-use-final-for-parameters-and-locals-even-when-i-dont-have-t
- https://stackoverflow.com/questions/3635863/why-method-parameters-needs-to-be-set-as-final
- https://stackoverflow.com/questions/500508/why-should-i-use-the-keyword-final-on-a-method-parameter-in-java
- https://www.reddit.com/r/learnjava/comments/1ffoa9p/using_final_in_method_parameters_your_opinion
There was a problem hiding this comment.
I didn't pay attention to this PR, but upgrading a dependency should not change any checkstyle rules... We should not have disabled this; inside KS module, we have this rule for a long time, and want to keep it (personally, I would think it would actually be good to even expand its scope to the entire code base, but that's a different discussion, and I don't want to touch it at this point)
Fixing via #21456
\cc @chia7712
|
Can you please take a look @chia7712 ? |
|
It seems that this PR has to be rebased onto trunk (to avoid |
6d1827f to
2b5b7cd
Compare
2b5b7cd to
4e633c7
Compare
| <module name="ClassDataAbstractionCoupling"> | ||
| <!-- default is 7 --> | ||
| <property name="max" value="25"/> | ||
| <property name="max" value="28"/> |
There was a problem hiding this comment.
Options:
- increase limit (like here)
- create a baseline (skip/suppress this check for existing cases/classes)
- change existing classes and keep the old property value max limit
dd07a5e to
9a19852
Compare
9a19852 to
835d655
Compare
|
After this PR is any form is merged, checkstyle team will start using Kafka repository code base in regression testing. So update of checkstyle version will be just version number bump. |
|
@dejan2609 , please resolve conflict. |
|
Checkstyle team merged integration of Kafka validation over by checkstyle for each pull request to checkstyle. Any changes in behavior that results in extra violations on Kafka code base will result in PR from checkstyle team to Kafka to be merged before checkstyle accept PR checkstyle code base. |
835d655 to
c27984a
Compare
Jira ticket: KAFKA-19809 Related link: https://checkstyle.org/releasenotes.html#Release_12.2.0⚠️ quick and dirty (aka skeleton) solution Reviews are welcome! Relates to: checkstyle/checkstyle#16003 Reviewers: Chia-Ping Tsai <[email protected]>
Jira ticket: KAFKA-19809
Related link: https://checkstyle.org/releasenotes.html#Release_12.2.0
Reviews are welcome!
Relates to: checkstyle/checkstyle#16003
Reviewers: Chia-Ping Tsai [email protected]