On 13/10/2026 17:42, Christopher Schultz wrote:
<snip/>
As a proof-of-concept, I:
1. Created a minimal Maven project
2. ... which has commons-pool2 2.13.1 as a (direct) dependency
3. ... and also has commons-dbcp2 2.14.0 as a (direct) dependency
4. Combines and shades the two above libraries into a single JAR
5. ... and also re-writes references from org.apache.logging ->
org.apache.juli
This produces a JAR file that worked for my JDBC-based application
deployed and running on Tomcat 9.0.122. I simply replaced the existing
tomcat-dbcp.jar file with the one produced by the Maven project
described above.
Some remaining potential issues:
1. The META-INF/MANIFEST.MF file in the resulting library does not match
what Tomcat's release build currently produces.
>
2. How to actually achieve the above process for a release build?
>
3. commons-dbcp2 is implementing the Java EE API for javax.transaction
which won't work properly on Tomcat 10.1.x and later.
Potential answers for the above 3 items:
1a. I'm not sure how much that matters, as Tomcat is not meaningfully
using Java modules, here.
There are users that are using modules and have complained in the past
when things aren't module compliant.
2a. Proposal: new subproject:tomcat-dbcp (not to be confused with
tomcat-pool, which is in module/!)
+1
3a. Proposals:
i. subproject:tomcat-dbcp has a packaging option for *also* re-naming
javax.transaction -> jakarta.transaction
ii. Tomcat 9 does nothing, Tomcat 10.1.x + add an additional
release-build step which is to run jakartaee-migration tool
on tomcat-dbcp.jar prior to release.
I like option ii).
Mark
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]