You are viewing a plain text version of this content. The canonical link for it is here.
Posted to gitbox@activemq.apache.org by "mattrpav (via GitHub)" <gi...@apache.org> on 2025/11/11 15:39:36 UTC
[PR] [NO-JIRA] Update enforcer-plugin to require building with JDK 21 [activemq]
mattrpav opened a new pull request, #1532:
URL: https://github.com/apache/activemq/pull/1532
I tested building with JDK 21 and then running with JDK 17 without a problem.
The docs for enforcer plugin make it read that this setting impacts _runtime_, but it does _**not**_ in fact change the compiler-plugin values used for source/target/release.
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to releasing with JDK 21 [activemq]
Posted by "gemmellr (via GitHub)" <gi...@apache.org>.
gemmellr commented on PR #1532:
URL: https://github.com/apache/activemq/pull/1532#issuecomment-3522756633
> This change looks good to me for the enforcer.
>
> However, if we merge it, it means Jenkins will fail. I suggest to update `Jenkinsfile` as part of this PR.
I dont see mention of it enabling the apache-release profile, so I dont think it will fail unless thats being introduced elsewhere.
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to releasing with JDK 21 [activemq]
Posted by "jeanouii (via GitHub)" <gi...@apache.org>.
jeanouii commented on PR #1532:
URL: https://github.com/apache/activemq/pull/1532#issuecomment-3884448880
@mattrpav I'm closing this one because with the Java 25 work, we are now enforcing Maven 3.9 and Java 24 for the release. So I don't think this one is necessary anymore. If I'm wrong, my apologies and please reopen.
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to releasing with JDK 21 [activemq]
Posted by "gemmellr (via GitHub)" <gi...@apache.org>.
gemmellr commented on code in PR #1532:
URL: https://github.com/apache/activemq/pull/1532#discussion_r2727821885
##########
pom.xml:
##########
@@ -1337,6 +1337,39 @@
</activation>
<build>
<plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-enforcer-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>enforce-maven</id>
+ <goals>
+ <goal>enforce</goal>
+ </goals>
+ <configuration>
+ <rules>
+ <requireMavenVersion>
+ <version>3.6.3</version>
+ </requireMavenVersion>
+ </rules>
+ </configuration>
+ </execution>
Review Comment:
Could similarly remove this maven version enforcement.
##########
pom.xml:
##########
@@ -1133,7 +1133,7 @@
<configuration>
<rules>
<requireMavenVersion>
- <version>3.0.5</version>
+ <version>3.6.3</version>
Review Comment:
The parent pom 37 now requires Maven 3.9 to build. Given 3.8.x is now entirely out of support and new plugin releases are aimed at 3.9+, I'd say its time to do the same (and have already done so in other projects). I'd also defer to its enforcer definition (by removing this one entirely) at this point to simplify the pom.
You could also get rid of the java version check below this one (but not the other one in the release profile) and defer to the parents one. They have also defined a new property in v37 to link all the java verison enforcement and compiler settings together, though personally I prefer having the compiler properties set in the components own pom and so am still setting them regardless.
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to releasing with JDK 21 [activemq]
Posted by "mattrpav (via GitHub)" <gi...@apache.org>.
mattrpav commented on code in PR #1532:
URL: https://github.com/apache/activemq/pull/1532#discussion_r2725700365
##########
pom.xml:
##########
@@ -1340,6 +1340,39 @@
</activation>
<build>
<plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-enforcer-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>enforce-maven</id>
+ <goals>
+ <goal>enforce</goal>
+ </goals>
+ <configuration>
+ <rules>
+ <requireMavenVersion>
+ <version>3.0.5</version>
Review Comment:
Updated to 3.6.3
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to releasing with JDK 21 [activemq]
Posted by "jeanouii (via GitHub)" <gi...@apache.org>.
jeanouii closed pull request #1532: [NO-JIRA] Update enforcer-plugin to releasing with JDK 21
URL: https://github.com/apache/activemq/pull/1532
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to require building with JDK 21 [activemq]
Posted by "mattrpav (via GitHub)" <gi...@apache.org>.
mattrpav commented on PR #1532:
URL: https://github.com/apache/activemq/pull/1532#issuecomment-3518221872
@gemmellr good catch. I'll move this change inside a release profile.
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to require building with JDK 21 [activemq]
Posted by "mattrpav (via GitHub)" <gi...@apache.org>.
mattrpav commented on PR #1532:
URL: https://github.com/apache/activemq/pull/1532#issuecomment-3522384251
Output when building with JDK 17 and apache-release profile
```
% mvn -Papache-release clean install -DskipTests=true
...
[ERROR] Rule 0: org.apache.maven.enforcer.rules.version.RequireJavaVersion failed with message:
[ERROR] You must use Java 21+ to release.
```
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to releasing with JDK 21 [activemq]
Posted by "gemmellr (via GitHub)" <gi...@apache.org>.
gemmellr commented on code in PR #1532:
URL: https://github.com/apache/activemq/pull/1532#discussion_r2518979767
##########
pom.xml:
##########
@@ -1340,6 +1340,39 @@
</activation>
<build>
<plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-enforcer-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>enforce-maven</id>
+ <goals>
+ <goal>enforce</goal>
+ </goals>
+ <configuration>
+ <rules>
+ <requireMavenVersion>
+ <version>3.0.5</version>
Review Comment:
I'd definitely use something much newer than 3.0.5 since most current plugins dont work with versions that old (baseline is 3.6.3 currently I think), though I probably wouldnt require 3.9.11 either (even though it is what I am now using) but perhaps some older 3.9.x.
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to releasing with JDK 21 [activemq]
Posted by "jbonofre (via GitHub)" <gi...@apache.org>.
jbonofre commented on code in PR #1532:
URL: https://github.com/apache/activemq/pull/1532#discussion_r2518669815
##########
pom.xml:
##########
@@ -1340,6 +1340,39 @@
</activation>
<build>
<plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-enforcer-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>enforce-maven</id>
+ <goals>
+ <goal>enforce</goal>
+ </goals>
+ <configuration>
+ <rules>
+ <requireMavenVersion>
+ <version>3.0.5</version>
Review Comment:
Maven 3.0.x doesn't support JDK21.
I suggest to set Maven to 3.9.11.
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact
Re: [PR] [NO-JIRA] Update enforcer-plugin to require building with JDK 21 [activemq]
Posted by "gemmellr (via GitHub)" <gi...@apache.org>.
gemmellr commented on PR #1532:
URL: https://github.com/apache/activemq/pull/1532#issuecomment-3517730990
The java version rule is just about the JVM running the enforcement, i.e the current runtime. It has nothing to do with the compiler settings or what the build output compiles for / runs on, which is all independent.
Wasnt the idea to only require _release builds_ are done with JDK 21+? This change also prevents building testing on 17+, which would ideally still be a thing if supporting/targeting it?
--
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: gitbox-unsubscribe@activemq.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: gitbox-unsubscribe@activemq.apache.org
For additional commands, e-mail: gitbox-help@activemq.apache.org
For further information, visit: https://activemq.apache.org/contact