Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion BUILDING.txt
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ Maven build goals:
* Compile : mvn compile [-Pnative]
* Run tests : mvn test [-Pnative] [-Pshelltest]
* Create JAR : mvn package
* Run findbugs : mvn compile findbugs:findbugs
* Run spotbugs : mvn compile spotbugs:spotbugs
* Run checkstyle : mvn compile checkstyle:checkstyle
* Install JAR in M2 cache : mvn install
* Deploy JAR to Maven repo : mvn deploy
Expand Down
6 changes: 3 additions & 3 deletions dev-support/Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -120,11 +120,11 @@ pipeline {
YETUS_ARGS+=("--proclimit=5500")
YETUS_ARGS+=("--dockermemlimit=22g")

# -1 findbugs issues that show up prior to the patch being applied
YETUS_ARGS+=("--findbugs-strict-precheck")
# -1 spotbugs issues that show up prior to the patch being applied
YETUS_ARGS+=("--spotbugs-strict-precheck")

# rsync these files back into the archive dir
YETUS_ARGS+=("--archive-list=checkstyle-errors.xml,findbugsXml.xml")
YETUS_ARGS+=("--archive-list=checkstyle-errors.xml,spotbugsXml.xml")

# URL for user-side presentation in reports and such to our artifacts
# (needs to match the archive bits below)
Expand Down
4 changes: 2 additions & 2 deletions dev-support/bin/hadoop.sh
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,7 @@ function personality_file_tests
fi

if [[ ${filename} =~ \.java$ ]]; then
add_test findbugs
add_test spotbugs
fi
}

Expand Down Expand Up @@ -550,7 +550,7 @@ function shadedclient_rebuild
echo_and_redirect "${logfile}" \
"${MAVEN}" "${MAVEN_ARGS[@]}" verify -fae --batch-mode -am \
"${modules[@]}" \
-Dtest=NoUnitTests -Dmaven.javadoc.skip=true -Dcheckstyle.skip=true -Dfindbugs.skip=true
-Dtest=NoUnitTests -Dmaven.javadoc.skip=true -Dcheckstyle.skip=true -Dspotbugs.skip=true

count=$("${GREP}" -c '\[ERROR\]' "${logfile}")
if [[ ${count} -gt 0 ]]; then
Expand Down
12 changes: 10 additions & 2 deletions dev-support/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,6 @@ RUN apt-get -q update \
cmake \
curl \
doxygen \
findbugs \
fuse \
g++ \
gcc \
Expand Down Expand Up @@ -92,7 +91,16 @@ RUN apt-get -q update \
ENV MAVEN_HOME /usr
# JAVA_HOME must be set in Maven >= 3.5.0 (MNG-6003)
ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-amd64
ENV FINDBUGS_HOME /usr

#######
# Install SpotBugs 4.2.2
#######
RUN mkdir -p /opt/spotbugs \
&& curl -L -s -S https://github.com/spotbugs/spotbugs/releases/download/4.2.2/spotbugs-4.2.2.tgz \
-o /opt/spotbugs.tgz \
&& tar xzf /opt/spotbugs.tgz --strip-components 1 -C /opt/spotbugs \
&& chmod +x /opt/spotbugs/bin/*
ENV SPOTBUGS_HOME /opt/spotbugs

#######
# Install Boost 1.72 (1.71 ships with Focal)
Expand Down
12 changes: 10 additions & 2 deletions dev-support/docker/Dockerfile_aarch64
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ RUN apt-get -q update \
cmake \
curl \
doxygen \
findbugs \
fuse \
g++ \
gcc \
Expand Down Expand Up @@ -96,7 +95,16 @@ RUN apt-get -q update \
ENV MAVEN_HOME /usr
# JAVA_HOME must be set in Maven >= 3.5.0 (MNG-6003)
ENV JAVA_HOME /usr/lib/jvm/java-8-openjdk-arm64
ENV FINDBUGS_HOME /usr

#######
# Install SpotBugs 4.2.2
#######
RUN mkdir -p /opt/spotbugs \
&& curl -L -s -S https://github.com/spotbugs/spotbugs/releases/download/4.2.2/spotbugs-4.2.2.tgz \
-o /opt/spotbugs.tgz \
&& tar xzf /opt/spotbugs.tgz --strip-components 1 -C /opt/spotbugs \
&& chmod +x /opt/spotbugs/bin/*
ENV SPOTBUGS_HOME /opt/spotbugs

#######
# Install Boost 1.72 (1.71 ships with Focal)
Expand Down
5 changes: 2 additions & 3 deletions hadoop-cloud-storage-project/hadoop-cos/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,9 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${basedir}/dev-support/findbugs-exclude.xml
</excludeFilterFile>
Expand Down
4 changes: 2 additions & 2 deletions hadoop-common-project/hadoop-auth/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -237,8 +237,8 @@
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<excludeFilterFile>${basedir}/dev-support/findbugsExcludeFile.xml</excludeFilterFile>
</configuration>
Expand Down
4 changes: 2 additions & 2 deletions hadoop-common-project/hadoop-kms/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -237,8 +237,8 @@
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<excludeFilterFile>${basedir}/dev-support/findbugsExcludeFile.xml
</excludeFilterFile>
Expand Down
4 changes: 2 additions & 2 deletions hadoop-common-project/hadoop-minikdc/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<excludeFilterFile>${basedir}/dev-support/findbugsExcludeFile.xml
</excludeFilterFile>
Expand Down
4 changes: 2 additions & 2 deletions hadoop-common-project/hadoop-nfs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,8 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<excludeFilterFile>${basedir}/dev-support/findbugsExcludeFile.xml
</excludeFilterFile>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-common-project/hadoop-registry/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -163,10 +163,9 @@
</resources>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${project.basedir}/dev-support/findbugs-exclude.xml</excludeFilterFile>
<effort>Max</effort>
Expand Down
4 changes: 2 additions & 2 deletions hadoop-hdfs-project/hadoop-hdfs-httpfs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -337,8 +337,8 @@
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<excludeFilterFile>${basedir}/dev-support/findbugsExcludeFile.xml</excludeFilterFile>
</configuration>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-mapreduce-project/hadoop-mapreduce-client/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -157,10 +157,9 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${mr.basedir}/dev-support/findbugs-exclude.xml</excludeFilterFile>
<effort>Max</effort>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-mapreduce-project/hadoop-mapreduce-examples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -138,10 +138,9 @@
</plugin>

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${mr.examples.basedir}/dev-support/findbugs-exclude.xml</excludeFilterFile>
<effort>Max</effort>
Expand Down
12 changes: 4 additions & 8 deletions hadoop-mapreduce-project/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -178,10 +178,9 @@
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${mr.basedir}/dev-support/findbugs-exclude.xml</excludeFilterFile>
<effort>Max</effort>
Expand Down Expand Up @@ -299,12 +298,9 @@
<reporting>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<!-- until we have reporting management cf. MSITE-443 -->
<version>2.3.2</version>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
</configuration>
</plugin>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-project-dist/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,10 @@
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<excludeFilterFile>${basedir}/dev-support/findbugsExcludeFile.xml</excludeFilterFile>
<fork>true</fork>
<maxHeap>2048</maxHeap>
</configuration>
</plugin>
Expand Down
17 changes: 0 additions & 17 deletions hadoop-project/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@
<zookeeper.version>3.5.6</zookeeper.version>
<curator.version>4.2.0</curator.version>
<findbugs.version>3.0.5</findbugs.version>
<spotbugs.version>4.0.6</spotbugs.version>
<dnsjava.version>2.1.7</dnsjava.version>

<guava.version>27.0-jre</guava.version>
Expand Down Expand Up @@ -1854,18 +1853,6 @@
<artifactId>maven-war-plugin</artifactId>
<version>${maven-war-plugin.version}</version>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<version>${findbugs.version}</version>
<dependencies>
<dependency>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs</artifactId>
<version>${spotbugs.version}</version>
</dependency>
</dependencies>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>make-maven-plugin</artifactId>
Expand Down Expand Up @@ -2099,10 +2086,6 @@
</filesets>
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-tools/hadoop-aliyun/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,9 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${basedir}/dev-support/findbugs-exclude.xml
</excludeFilterFile>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-tools/hadoop-archive-logs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -194,10 +194,9 @@
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>
${basedir}/dev-support/findbugs-exclude.xml
Expand Down
5 changes: 2 additions & 3 deletions hadoop-tools/hadoop-aws/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -399,10 +399,9 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${basedir}/dev-support/findbugs-exclude.xml
</excludeFilterFile>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-tools/hadoop-azure/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,9 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${basedir}/dev-support/findbugs-exclude.xml
</excludeFilterFile>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-tools/hadoop-datajoin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -108,10 +108,9 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${basedir}/dev-support/findbugs-exclude.xml
</excludeFilterFile>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-tools/hadoop-fs2img/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,9 @@
</configuration>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${basedir}/dev-support/findbugs-exclude.xml</excludeFilterFile>
<effort>Max</effort>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-tools/hadoop-gridmix/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -123,10 +123,9 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${basedir}/dev-support/findbugs-exclude.xml</excludeFilterFile>
<effort>Max</effort>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-tools/hadoop-kafka/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,9 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<effort>Max</effort>
</configuration>
Expand Down
5 changes: 2 additions & 3 deletions hadoop-tools/hadoop-openstack/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -66,10 +66,9 @@
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>findbugs-maven-plugin</artifactId>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<findbugsXmlOutput>true</findbugsXmlOutput>
<xmlOutput>true</xmlOutput>
<excludeFilterFile>${basedir}/dev-support/findbugs-exclude.xml
</excludeFilterFile>
Expand Down
Loading