Skip to content
Merged
Changes from 1 commit
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
4 changes: 2 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,8 @@ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/x
<maven-checkstyle-plugin.version>3.1.0</maven-checkstyle-plugin.version>
<checkstyle.version>8.29</checkstyle.version>
<dependency-check-maven.version>7.1.1</dependency-check-maven.version>
<spotbugs.version>4.2.2</spotbugs.version>
<spotbugs-maven-plugin.version>4.2.0</spotbugs-maven-plugin.version>
<spotbugs.version>4.8.3</spotbugs.version>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for reviewing! You made a very good point — I’ll update this PR accordingly.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

spotbugs 4.9 onwards requires JDK 11+, are we ready to drop Java 8 support on trunk?

currently, trunk GitHub Actions site jobs fail due to this upgrade.

@szetszwo @slfan1989

@szetszwo szetszwo Nov 4, 2025

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@slfan1989 , we probably should move back to 4.8.x?

@pan3793 , Actually, SpotBugs is build tool but not a runtime library. One option is to run SpotBugs code analysis using jdk11 or above. The runtime still can be built with and run with JDK8. Would it work?

@slfan1989 slfan1989 Nov 4, 2025

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you all for the discussion! I believe what @szetszwo mentioned makes sense.

Let me explain the situation:

We have upgraded the JDK version in the trunk to JDK 17 and JDK 21. Regarding the issue of mvn site failing to compile, this is a known issue and is unrelated to the SpotBugs plugin.

Here’s a detailed explanation of the two issues:

  1. The reason for upgrading is that SpotBugs 4.2.0, as indicated by Yetus, does not support scanning for JDK 17 and above. Therefore, we upgraded to a higher version, choosing SpotBugs 4.9.7. From my perspective, upgrading to SpotBugs 4.9.7 is reasonable. Although new warning messages have appeared, I do not plan to roll back the version. Issue after upgrading to SpotBugs 4.9.7: Due to the introduction of new rules, new warning messages appeared during compilation. We have formulated a solution:
  1. mvn site compilation failure: This issue is related to our custom annotations, which we can see in the error logs. We already have a solution for this:
  • Referring to PR HADOOP-19402. [JDK11] JDiff Support JDK11. #8038. we have rewritten all the annotations under hadoop-common-project/hadoop-annotations/src/main/java17/org/apache/hadoop/classification/tools/* and added support for JDIFF under JDK 17.

Currently, these two PRs are being followed up by HuaLong. In offline communication, HuaLong mentioned that he is currently on leave, so it may take some more time to complete.

I hope this makes the situation clearer!

<spotbugs-maven-plugin.version>4.7.3.6</spotbugs-maven-plugin.version>

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Similarly, why not 4.9.7.0 (or 4.8.6.7)?

<jsonschema2pojo-maven-plugin.version>1.1.1</jsonschema2pojo-maven-plugin.version>
<maven-compiler-plugin.version>3.10.1</maven-compiler-plugin.version>
<cyclonedx.version>2.9.1</cyclonedx.version>
Expand Down