leesf commented on a change in pull request #1208: [HUDI-304] Bring back
spotless plugin
URL: https://github.com/apache/incubator-hudi/pull/1208#discussion_r365633211
##########
File path: style/checkstyle.xml
##########
@@ -61,10 +61,11 @@
<property name="allowByTailComment" value="true"/>
<property name="allowNonPrintableEscapes" value="true"/>
</module>
+ <!-- when use mvn spotless:apply to format code, the length would be
more than 120, even 200.
<module name="LineLength">
- <property name="max" value="200"/>
+ <property name="max" value="120"/>
<property name="ignorePattern" value="^ *\* *[^ ]+$"/>
- </module>
+ </module>-->
Review comment:
In fact, change to 120 or keep as is(200) doesn't matter since the rule is
commented, it makes no sense. Here are my thoughts. When using `mvn
spotless:apply` to auto fix style error, a line length would be 124
(https://github.com/apache/incubator-hudi/blob/master/hudi-common/src/test/java/org/apache/hudi/common/util/collection/TestExternalSpillableMap.java#L72),
and would be
132(https://github.com/apache/incubator-hudi/blob/master/hudi-client/src/main/java/org/apache/hudi/func/CopyOnWriteLazyInsertIterable.java#L95),
So seems like after formatting, there is a possibility of line length more
than 200 (maybe rarely), So I comment it. BTW, in most case, 200 is enough
currently.
----------------------------------------------------------------
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]
With regards,
Apache Git Services