srdo commented on code in PR #20295:
URL: https://github.com/apache/kafka/pull/20295#discussion_r2251698418


##########
build.gradle:
##########
@@ -72,6 +72,12 @@ ext {
       "--add-opens=java.security.jgss/sun.security.krb5=ALL-UNNAMED"
     )
 
+  if (JavaVersion.current().isCompatibleWith(JavaVersion.VERSION_24)) {
+    // Spotbugs is not compatible with Java 24+ until Spotbugs 4.9.4. Disable 
it until we can upgrade to that version.
+    project.gradle.startParameter.excludedTaskNames.add("spotbugsMain")

Review Comment:
   Yes, but the secondary reason I added those flags is that running those 
tasks in that step is wasteful.
   
   `build.yml` runs the Spotbugs check here, running it with the JDK that I set 
to 17 with this PR.
   
   
https://github.com/apache/kafka/blob/904ee87b8505813534937f20cec33f31d431564b/.github/workflows/build.yml#L143
   
   It is then a bit of a waste of time to run it again when the same script 
invokes `action.yml` here 
   
   
https://github.com/apache/kafka/blob/904ee87b8505813534937f20cec33f31d431564b/.github/workflows/build.yml#L220
   
   so Spotbugs ends up running again alongside all the tests.
   
   I don't really see a benefit to running Spotbugs in both places?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to