20fd254101
## What changes were proposed in this pull request? [Spark Coding Style Guide](https://cwiki.apache.org/confluence/display/SPARK/Spark+Code+Style+Guide) has 100-character limit on lines, but it's disabled for Java since 11/09/15. This PR enables **LineLength** checkstyle again. To help that, this also introduces **RedundantImport** and **RedundantModifier**, too. The following is the diff on `checkstyle.xml`. ```xml - <!-- TODO: 11/09/15 disabled - the lengths are currently > 100 in many places --> - <!-- <module name="LineLength"> <property name="max" value="100"/> <property name="ignorePattern" value="^package.*|^import.*|a href|href|http://|https://|ftp://"/> </module> - --> <module name="NoLineWrap"/> <module name="EmptyBlock"> <property name="option" value="TEXT"/> -167,5 +164,7 </module> <module name="CommentsIndentation"/> <module name="UnusedImports"/> + <module name="RedundantImport"/> + <module name="RedundantModifier"/> ``` ## How was this patch tested? Currently, `lint-java` is disabled in Jenkins. It needs a manual test. After passing the Jenkins tests, `dev/lint-java` should passes locally. Author: Dongjoon Hyun <dongjoon@apache.org> Closes #11831 from dongjoon-hyun/SPARK-14011.
40 lines
1.6 KiB
XML
40 lines
1.6 KiB
XML
<!--
|
|
~ Licensed to the Apache Software Foundation (ASF) under one or more
|
|
~ contributor license agreements. See the NOTICE file distributed with
|
|
~ this work for additional information regarding copyright ownership.
|
|
~ The ASF licenses this file to You under the Apache License, Version 2.0
|
|
~ (the "License"); you may not use this file except in compliance with
|
|
~ the License. You may obtain a copy of the License at
|
|
~
|
|
~ http://www.apache.org/licenses/LICENSE-2.0
|
|
~
|
|
~ Unless required by applicable law or agreed to in writing, software
|
|
~ distributed under the License is distributed on an "AS IS" BASIS,
|
|
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
~ See the License for the specific language governing permissions and
|
|
~ limitations under the License.
|
|
-->
|
|
|
|
<!DOCTYPE suppressions PUBLIC
|
|
"-//Puppy Crawl//DTD Suppressions 1.1//EN"
|
|
"http://www.puppycrawl.com/dtds/suppressions_1_1.dtd">
|
|
|
|
<!--
|
|
|
|
This file contains suppression rules for Checkstyle checks.
|
|
Ideally only files that cannot be modified (e.g. third-party code)
|
|
should be added here. All other violations should be fixed.
|
|
|
|
-->
|
|
|
|
<suppressions>
|
|
<suppress checks=".*"
|
|
files="core/src/main/java/org/apache/spark/util/collection/TimSort.java"/>
|
|
<suppress checks=".*"
|
|
files="sql/core/src/main/java/org/apache/spark/sql/api.java/*"/>
|
|
<suppress checks="LineLength"
|
|
files="src/test/java/org/apache/spark/sql/hive/test/Complex.java"/>
|
|
<suppress checks="LineLength"
|
|
files="src/main/java/org/apache/spark/examples/JavaLogQuery.java"/>
|
|
</suppressions>
|