浏览代码

HADOOP-16771. Update checkstyle to 8.26 and maven-checkstyle-plugin to 3.1.0. Contributed by Andras Bokor.

(cherry picked from commit f777cd398f1d48898ddc4a9a5ab4e7e310e3027a)
Akira Ajisaka 5 年之前
父节点
当前提交
39c6849d34

+ 4 - 1
hadoop-build-tools/src/main/resources/checkstyle/checkstyle.xml

@@ -67,6 +67,10 @@
     <!--<module name="FileLength">-->
     <module name="FileTabCharacter"/>
 
+    <!-- Checks for line length violations.                                 -->
+    <!-- See https://checkstyle.sourceforge.io/config_sizes.html#LineLength -->
+    <module name="LineLength"/>
+
     <module name="TreeWalker">
 
         <module name="SuppressWarningsHolder"/>
@@ -122,7 +126,6 @@
 
         <!-- Checks for Size Violations.                    -->
         <!-- See http://checkstyle.sf.net/config_sizes.html -->
-        <module name="LineLength"/>
         <module name="MethodLength"/>
         <module name="ParameterNumber">
           <property name="ignoreOverriddenMethods" value="true"/>

+ 4 - 4
hadoop-tools/hadoop-azure/src/config/checkstyle.xml

@@ -62,6 +62,10 @@
         <property name="eachLine" value="true"/>
     </module>
 
+    <module name="LineLength">
+        <property name="max" value="160" />
+    </module>
+
     <module name="TreeWalker">
 
         <!-- Checks for Javadoc comments.                     -->
@@ -101,10 +105,6 @@
         <!-- Checks for Size Violations.                    -->
         <!-- See http://checkstyle.sf.net/config_sizes.html -->
 
-        <module name="LineLength">
-          <property name="max" value="160" />
-        </module>
-        
         <module name="MethodLength">
           <property name="max" value="3000"/>
         </module>

+ 2 - 2
pom.xml

@@ -107,8 +107,8 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/x
     <maven-clover2-plugin.version>3.3.0</maven-clover2-plugin.version>
     <maven-bundle-plugin.version>2.5.0</maven-bundle-plugin.version>
     <lifecycle-mapping.version>1.0.0</lifecycle-mapping.version>
-    <maven-checkstyle-plugin.version>3.0.0</maven-checkstyle-plugin.version>
-    <checkstyle.version>8.19</checkstyle.version>
+    <maven-checkstyle-plugin.version>3.1.0</maven-checkstyle-plugin.version>
+    <checkstyle.version>8.26</checkstyle.version>
     <dependency-check-maven.version>1.4.3</dependency-check-maven.version>
 
     <shell-executable>bash</shell-executable>