Repository: kudu
Updated Branches:
  refs/heads/master 25771c21f -> 11fa20723


[build] - Suppress generated sources from checkstyle plugin

The Maven Checkstyle plugin is currently executing against
generated sources, this patch uses a Suppression Filter to
avoid this.

Change-Id: I22e8dd001543fca7cdd5778fc8f461685071fe9e
Reviewed-on: http://gerrit.cloudera.org:8080/5225
Tested-by: Kudu Jenkins
Reviewed-by: Dan Burkert <[email protected]>


Project: http://git-wip-us.apache.org/repos/asf/kudu/repo
Commit: http://git-wip-us.apache.org/repos/asf/kudu/commit/11fa2072
Tree: http://git-wip-us.apache.org/repos/asf/kudu/tree/11fa2072
Diff: http://git-wip-us.apache.org/repos/asf/kudu/diff/11fa2072

Branch: refs/heads/master
Commit: 11fa207232cf2a4389919faa21c45ed4ebbcc2cb
Parents: 25771c2
Author: Jordan Birdsell <[email protected]>
Authored: Fri Nov 25 15:06:13 2016 -0500
Committer: Dan Burkert <[email protected]>
Committed: Sat Nov 26 00:38:24 2016 +0000

----------------------------------------------------------------------
 java/checkstyle_suppressions.xml | 28 ++++++++++++++++++++++++++++
 java/kudu_style.xml              |  5 +++++
 java/pom.xml                     |  4 ----
 3 files changed, 33 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kudu/blob/11fa2072/java/checkstyle_suppressions.xml
----------------------------------------------------------------------
diff --git a/java/checkstyle_suppressions.xml b/java/checkstyle_suppressions.xml
new file mode 100644
index 0000000..86c7d98
--- /dev/null
+++ b/java/checkstyle_suppressions.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0"?>
+<!--
+//
+// 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";>
+
+<suppressions>
+    <suppress files="/generated-sources/"
+              checks=".*" />
+</suppressions>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/kudu/blob/11fa2072/java/kudu_style.xml
----------------------------------------------------------------------
diff --git a/java/kudu_style.xml b/java/kudu_style.xml
index 6b8ef8a..1db1e35 100644
--- a/java/kudu_style.xml
+++ b/java/kudu_style.xml
@@ -49,6 +49,11 @@
     </module>
     <!-- Turn off/on checkstyle with CHECKSTYLE:OFF CHECKSTYLE:ON comments -->
     <module name="SuppressionCommentFilter"/>
+    <!-- Suppress generated sources -->
+    <module name="SuppressionFilter">
+        <property name="file" value="checkstyle_suppressions.xml"/>
+        <property name="optional" value="false"/>
+    </module>
     <module name="TreeWalker">
         <module name="FileContentsHolder"/>
         <module name="OuterTypeFilename"/>

http://git-wip-us.apache.org/repos/asf/kudu/blob/11fa2072/java/pom.xml
----------------------------------------------------------------------
diff --git a/java/pom.xml b/java/pom.xml
index 3fea1e7..c9fb510 100644
--- a/java/pom.xml
+++ b/java/pom.xml
@@ -257,10 +257,6 @@
                             <encoding>UTF-8</encoding>
                             <consoleOutput>true</consoleOutput>
                             <failsOnError>false</failsOnError>
-                            <!-- Don't check generated sources. -->
-                            <sourceDirectories>
-                                
<sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
-                            </sourceDirectories>
                         </configuration>
                         <goals>
                             <goal>check</goal>

Reply via email to