AFAIK there are two mains options:

1. relocation (shade plugin which is used a lot for impacted projects or
alike)
2. a bridge since API is close enough to use one and wire to the other
(like
https://github.com/yupiik/uship/tree/master/servlet-jakarta-javax-bridge)

Advantage of 1 is to only require 1 dependency whereas option 2 requires to
have both spec in the classpath so I would be for the relocation as well.

Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://rmannibucau.metawerx.net/> | Old Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Book
<https://www.packtpub.com/application-development/java-ee-8-high-performance>


Le jeu. 31 mars 2022 à 00:03, Melloware Inc <melloware...@gmail.com> a
écrit :

> With PrimeFaces we use a special plug-in for Shade that builds a second
> jar that renames javax to Jakarta everywhere and in maven central it adds
> the Jakarta classifier to the jar so we can have both javax and Jakarta
> versions built from the same code base.
>
> See:  https://github.com/primefaces/primefaces
>
> Melloware
> @melloware on GitHub
>
> > On Mar 30, 2022, at 5:50 PM, John Patrick <nhoj.patr...@gmail.com>
> wrote:
> >
> > That would probably need to be a major release as it would break
> backwards
> > compatibility for other consumers.
> > I don't know the roadmap for fileupload but I would suggest raising a
> jira
> > ticket for this new feature request.
> >
> > Looking at Tomcat 10.x it appears to be Servlet 5.0 specification which
> is
> > either Jakarta EE 9 or Jakarta EE 9.1.
> > Then looking at Jakarta EE 9 release in 2020-12-08, that did the breaking
> > change from javax. to jakarta.
> >
> > I think this type of issue will happen more as I don't think all Apache
> > Commons are at Java 1.8, but once they support Java 9 or new and they can
> > support Multi Jar Releases it will be easier to support newer Java LTS
> > like, 11 and 17. Then in 15 months we get Java 21 which i understand is
> the
> > new 2 year LTS release schedule instead of the 3 year release schedule.
> >
> > Cheers,
> > John
> >
> >
> >> On Wed, 30 Mar 2022 at 21:33, Mark Foley <mfo...@novatec-inc.com>
> wrote:
> >>
> >> Just now joining this list. I've installed Tomcat 10.0.17 which uses the
> >> jakarta class, not javax. FileUpload 1.4 (the most recent as far as I
> >> can tell) uses javax. Is FileUpload schedule for a new version using
> >> jakarta?
> >>
> >> Thanks --Mark
>

Reply via email to