You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hive.apache.org by kg...@apache.org on 2020/06/12 13:31:06 UTC
[hive] branch master updated: HIVE-23620: Moving to SpotBugs that
is actively maintained (#1066)
This is an automated email from the ASF dual-hosted git repository.
kgyrtkirk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hive.git
The following commit(s) were added to refs/heads/master by this push:
new 5120f4f HIVE-23620: Moving to SpotBugs that is actively maintained (#1066)
5120f4f is described below
commit 5120f4fbc74cfa31194064381d16596d4e440741
Author: Panagiotis Garefalakis <pg...@cloudera.com>
AuthorDate: Fri Jun 12 14:30:54 2020 +0100
HIVE-23620: Moving to SpotBugs that is actively maintained (#1066)
---
Jenkinsfile | 4 ++--
pom.xml | 27 ++++++++++++++--------
ql/pom.xml | 7 +++---
.../spotbugs-exclude.xml | 0
standalone-metastore/metastore-common/pom.xml | 26 +++++++++++++--------
.../spotbugs/spotbugs-exclude.xml} | 0
standalone-metastore/metastore-server/pom.xml | 26 +++++++++++++--------
.../spotbugs/spotbugs-exclude.xml} | 0
.../spotbugs-exclude.xml} | 0
9 files changed, 58 insertions(+), 32 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index 8c18733..1d82b11 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -169,12 +169,12 @@ jobWrappers {
checkout scm
}
stage('Prechecks') {
- def findbugsProjects = [
+ def spotbugsProjects = [
":hive-shims-aggregator",
":hive-shims-common",
":hive-storage-api"
]
- buildHive("-Pfindbugs -pl " + findbugsProjects.join(",") + " -am compile findbugs:check")
+ buildHive("-Pspotbugs -pl " + spotbugsProjects.join(",") + " -am compile com.github.spotbugs:spotbugs-maven-plugin:4.0.0:check")
}
stage('Compile') {
buildHive("install -Dtest=noMatches")
diff --git a/pom.xml b/pom.xml
index 0529102..3536533 100644
--- a/pom.xml
+++ b/pom.xml
@@ -1604,18 +1604,27 @@
</profile>
<profile>
- <id>findbugs</id>
+ <id>spotbugs</id>
<build>
<plugins>
+ <!-- Execute as: com.github.spotbugs:spotbugs-maven-plugin:4.0.0:spotbugs -->
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>findbugs-maven-plugin</artifactId>
- <version>3.0.5</version>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs-maven-plugin</artifactId>
+ <version>4.0.0</version>
+ <dependencies>
+ <!-- Specify the version of spotbugs -->
+ <dependency>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs</artifactId>
+ <version>4.0.3</version>
+ </dependency>
+ </dependencies>
<configuration>
<fork>true</fork>
<maxHeap>2048</maxHeap>
<jvmArgs>-Djava.awt.headless=true -Xmx2048m -Xms512m</jvmArgs>
- <excludeFilterFile>${basedir}/${hive.path.to.root}/findbugs/findbugs-exclude.xml</excludeFilterFile>
+ <excludeFilterFile>${basedir}/${hive.path.to.root}/spotbugs/spotbugs-exclude.xml</excludeFilterFile>
</configuration>
</plugin>
</plugins>
@@ -1623,14 +1632,14 @@
<reporting>
<plugins>
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>findbugs-maven-plugin</artifactId>
- <version>3.0.5</version>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs-maven-plugin</artifactId>
+ <version>4.0.0</version>
<configuration>
<fork>true</fork>
<maxHeap>2048</maxHeap>
<jvmArgs>-Djava.awt.headless=true -Xmx2048m -Xms512m</jvmArgs>
- <excludeFilterFile>${basedir}/${hive.path.to.root}/findbugs/findbugs-exclude.xml</excludeFilterFile>
+ <excludeFilterFile>${basedir}/${hive.path.to.root}/spotbugs/spotbugs-exclude.xml</excludeFilterFile>
</configuration>
</plugin>
</plugins>
diff --git a/ql/pom.xml b/ql/pom.xml
index 40b1f30..4f9cd3d 100644
--- a/ql/pom.xml
+++ b/ql/pom.xml
@@ -857,9 +857,10 @@
<version>${jersey.version}</version>
</dependency>
<dependency>
- <groupId>com.google.code.findbugs</groupId>
- <artifactId>findbugs-annotations</artifactId>
- <version>3.0.1</version>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs-annotations</artifactId>
+ <version>4.0.3</version>
+ <optional>true</optional>
</dependency>
</dependencies>
<profiles>
diff --git a/findbugs/findbugs-exclude.xml b/spotbugs/spotbugs-exclude.xml
similarity index 100%
rename from findbugs/findbugs-exclude.xml
rename to spotbugs/spotbugs-exclude.xml
diff --git a/standalone-metastore/metastore-common/pom.xml b/standalone-metastore/metastore-common/pom.xml
index 1938dce..a535737 100644
--- a/standalone-metastore/metastore-common/pom.xml
+++ b/standalone-metastore/metastore-common/pom.xml
@@ -366,18 +366,26 @@
</build>
</profile>
<profile>
- <id>findbugs</id>
+ <id>spotbugs</id>
<build>
<plugins>
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>findbugs-maven-plugin</artifactId>
- <version>3.0.0</version>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs-maven-plugin</artifactId>
+ <version>4.0.0</version>
+ <dependencies>
+ <!-- Specify the version of spotbugs -->
+ <dependency>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs</artifactId>
+ <version>4.0.3</version>
+ </dependency>
+ </dependencies>
<configuration>
<fork>true</fork>
<maxHeap>2048</maxHeap>
<jvmArgs>-Djava.awt.headless=true -Xmx2048m -Xms512m</jvmArgs>
- <excludeFilterFile>${basedir}/findbugs/findbugs-exclude.xml</excludeFilterFile>
+ <excludeFilterFile>${basedir}/spotbugs/spotbugs-exclude.xml</excludeFilterFile>
</configuration>
</plugin>
</plugins>
@@ -385,14 +393,14 @@
<reporting>
<plugins>
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>findbugs-maven-plugin</artifactId>
- <version>3.0.0</version>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs-maven-plugin</artifactId>
+ <version>4.0.0</version>
<configuration>
<fork>true</fork>
<maxHeap>2048</maxHeap>
<jvmArgs>-Djava.awt.headless=true -Xmx2048m -Xms512m</jvmArgs>
- <excludeFilterFile>${basedir}/findbugs/findbugs-exclude.xml</excludeFilterFile>
+ <excludeFilterFile>${basedir}/spotbugs/spotbugs-exclude.xml</excludeFilterFile>
</configuration>
</plugin>
</plugins>
diff --git a/standalone-metastore/metastore-server/findbugs/findbugs-exclude.xml b/standalone-metastore/metastore-common/spotbugs/spotbugs-exclude.xml
similarity index 100%
rename from standalone-metastore/metastore-server/findbugs/findbugs-exclude.xml
rename to standalone-metastore/metastore-common/spotbugs/spotbugs-exclude.xml
diff --git a/standalone-metastore/metastore-server/pom.xml b/standalone-metastore/metastore-server/pom.xml
index 953deff..df6be61 100644
--- a/standalone-metastore/metastore-server/pom.xml
+++ b/standalone-metastore/metastore-server/pom.xml
@@ -319,18 +319,26 @@
</build>
</profile>
<profile>
- <id>findbugs</id>
+ <id>spotbugs</id>
<build>
<plugins>
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>findbugs-maven-plugin</artifactId>
- <version>3.0.0</version>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs-maven-plugin</artifactId>
+ <version>4.0.0</version>
+ <dependencies>
+ <!-- Specify the version of spotbugs -->
+ <dependency>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs</artifactId>
+ <version>4.0.3</version>
+ </dependency>
+ </dependencies>
<configuration>
<fork>true</fork>
<maxHeap>2048</maxHeap>
<jvmArgs>-Djava.awt.headless=true -Xmx2048m -Xms512m</jvmArgs>
- <excludeFilterFile>${basedir}/findbugs/findbugs-exclude.xml</excludeFilterFile>
+ <excludeFilterFile>${basedir}/spotbugs/spotbugs-exclude.xml</excludeFilterFile>
</configuration>
</plugin>
</plugins>
@@ -338,14 +346,14 @@
<reporting>
<plugins>
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>findbugs-maven-plugin</artifactId>
- <version>3.0.0</version>
+ <groupId>com.github.spotbugs</groupId>
+ <artifactId>spotbugs-maven-plugin</artifactId>
+ <version>4.0.0</version>
<configuration>
<fork>true</fork>
<maxHeap>2048</maxHeap>
<jvmArgs>-Djava.awt.headless=true -Xmx2048m -Xms512m</jvmArgs>
- <excludeFilterFile>${basedir}/findbugs/findbugs-exclude.xml</excludeFilterFile>
+ <excludeFilterFile>${basedir}/spotbugs/spotbugs-exclude.xml</excludeFilterFile>
</configuration>
</plugin>
</plugins>
diff --git a/standalone-metastore/metastore-common/findbugs/findbugs-exclude.xml b/standalone-metastore/metastore-server/spotbugs/spotbugs-exclude.xml
similarity index 100%
rename from standalone-metastore/metastore-common/findbugs/findbugs-exclude.xml
rename to standalone-metastore/metastore-server/spotbugs/spotbugs-exclude.xml
diff --git a/standalone-metastore/findbugs/findbugs-exclude.xml b/standalone-metastore/spotbugs/spotbugs-exclude.xml
similarity index 100%
rename from standalone-metastore/findbugs/findbugs-exclude.xml
rename to standalone-metastore/spotbugs/spotbugs-exclude.xml