Aw: Re: TomEE does not launch on Java 24
Wolfgang Knauf <[email protected]> Fri, 4 Apr 2025 11:24:42 +0200
| Newsgroups | gmane.comp.java.openejb.user |
|---|---|
| Message-ID | <trinity-035d2bc2-0261-45fe-bdea-19c328ea1ec4-1743758682735@msvc-mesg-gmx021> |
Thanks for the reply, I created https://issues=2Eapache=2Eorg/jira/browse/T=
OMEE-4474
Best regards
Wolfgang
> Gesendet: Freitag, 4=2E April 2025 um 11:00
> Von: "Vicente Rossello" <cocorossello@gmail=2Ecom>
> An: users@tomee=2Eapache=2Eorg
> Betreff: Re: TomEE does not launch on Java 24
>
> <html><head></head><body>Hi,
>=20
> Just FYI, I got working with java 24 by removing the policies
>=20
> Remove lines 424 to 432 in
> https://github=2Ecom/apache/tomee/blob/main/container/openejb-core/src/m=
ain/java/org/apache/openejb/core/security/AbstractSecurityService=2Ejava#L4=
24
>=20
> Also, if you deploy with intellij (which uses a openejb deployer), you w=
ill
> need to remove the checkPermission in
> https://github=2Ecom/apache/tomee/blob/main/container/openejb-core/src/m=
ain/java/org/apache/openejb/core/security/AbstractSecurityService=2Ejava#L3=
89
>=20
> If you still want to check permissions you can do this dirty hack:
> if ("openejb/Deployer"=2Eequals(ejbName) || type =3D=3D
> BUSINESS_LOCALBEAN_HOME || type =3D=3D LOCALBEAN) {
> return true;
> }
>=20
> Finally, you also need to disable
> https://github=2Ecom/apache/tomee/blob/main/server/openejb-client/src/ma=
in/java/org/apache/openejb/client/JaasIdentityResolver=2Ejava#L28
> by returning null=2E
>=20
> These are dirty workarounds, I don't know the implications, but they are=
ok
> for our use case=2E
>=20
>=20
>=20
> On Fri, Apr 4, 2025 at 10:48=E2=80=AFAM Richard Zowalla <rzo1@apache=2Eo=
rg> wrote:
>=20
> > Hi,
> >
> > You can open a Jira at https://issues=2Eapache=2Eorg/jira/projects/=
TOMEE/
> >
> > Currently, there is no issue to track Java 24 support since the par=
t of
> > TomEE using SecurityManager wasn=E2=80=99t reworked yet nor did we =
test with Java
> > 24 and our 3rd party dependencies=2E
> >
> > If you have some capacity, feel free to propose a PR to rework that=
part
> > of TomEE=2E
> >
> > Gru=C3=9F
> > Richard
> >
> > > Am 04=2E04=2E2025 um 10:28 schrieb Wolfgang Knauf
> > <wolfgang=2Eknauf@gmx=2Ede=2Einvalid>:
> > >
> > > Hi all,
> > >
> > > (sorry if this is a duplicate one, I already sent it a few day=
s ago, but
> > as it did not appear, I think it might be related to the fact that =
I did
> > not subscribe to the list)
> > >
> > > TomEE 10=2E0=2E1 fails to launch with Java 24:
> > >
> > > 01-Apr-2025 13:10:36=2E888 SCHWERWIEGEND [main]
> > org=2Eapache=2Eopenejb=2Eutil=2EOpenEJBErrorHandler=2EhandleUnknown=
Error FATAL ERROR:
> > Unknown error in Assembler=2E Please send the following stack trace=
and this
> > message to users@tomee=2Eapache=2Eorg :
> > > org=2Eapache=2Exbean=2Erecipe=2EConstructionException: Error i=
nvoking
> > constructor: public org=2Eapache=2Etomee=2Ecatalina=2ETomcatSecurit=
yService()
> > > at
> > org=2Eapache=2Exbean=2Erecipe=2EReflectionUtil$ConstructorFactory=
=2Ecreate(ReflectionUtil=2Ejava:981)
> > > at
> > org=2Eapache=2Exbean=2Erecipe=2EObjectRecipe=2EinternalCreate(Objec=
tRecipe=2Ejava:279)
> > > at org=2Eapache=2Exbean=2Erecipe=2EAbstractRecipe=2Ecreate(Ab=
stractRecipe=2Ejava:96)
> > > at org=2Eapache=2Exbean=2Erecipe=2EAbstractRecipe=2Ecreate(Ab=
stractRecipe=2Ejava:61)
> > > at org=2Eapache=2Exbean=2Erecipe=2EAbstractRecipe=2Ecreate(Ab=
stractRecipe=2Ejava:49)
> > > at
> > org=2Eapache=2Eopenejb=2Eassembler=2Eclassic=2EAssembler=2EcreateSe=
curityService(Assembler=2Ejava:3553)
> > > at
> > org=2Eapache=2Eopenejb=2Eassembler=2Eclassic=2EAssembler=2EbuildCon=
tainerSystem(Assembler=2Ejava:579)
> > > at
> > org=2Eapache=2Eopenejb=2Eassembler=2Eclassic=2EAssembler=2Ebuild(As=
sembler=2Ejava:497)
> > > at org=2Eapache=2Eopenejb=2EOpenEJB$Instance=2E<init>(OpenEJB=
=2Ejava:150)
> > > at org=2Eapache=2Eopenejb=2EOpenEJB=2Einit(OpenEJB=2Ejava:307=
)
> > > at
> > org=2Eapache=2Etomee=2Ecatalina=2ETomcatLoader=2Einitialize(TomcatL=
oader=2Ejava:244)
> > > at
> > org=2Eapache=2Etomee=2Ecatalina=2EServerListener=2ElifecycleEvent(S=
erverListener=2Ejava:161)
> > > at
> > org=2Eapache=2Ecatalina=2Eutil=2ELifecycleBase=2EfireLifecycleEvent=
(LifecycleBase=2Ejava:109)
> > > at
> > org=2Eapache=2Ecatalina=2Eutil=2ELifecycleBase=2EsetStateInternal(L=
ifecycleBase=2Ejava:389)
> > > at org=2Eapache=2Ecatalina=2Eutil=2ELifecycleBase=2Einit(Life=
cycleBase=2Ejava:123)
> > > at org=2Eapache=2Ecatalina=2Estartup=2ECatalina=2Eload(Catali=
na=2Ejava:712)
> > > at org=2Eapache=2Ecatalina=2Estartup=2ECatalina=2Eload(Catali=
na=2Ejava:735)
> > > at
> > java=2Ebase/jdk=2Einternal=2Ereflect=2EDirectMethodHandleAccessor=
=2Einvoke(DirectMethodHandleAccessor=2Ejava:104)
> > > at java=2Ebase/java=2Elang=2Ereflect=2EMethod=2Einvoke(Method=
=2Ejava:565)
> > > at org=2Eapache=2Ecatalina=2Estartup=2EBootstrap=2Eload(Boots=
trap=2Ejava:302)
> > > at org=2Eapache=2Ecatalina=2Estartup=2EBootstrap=2Emain(Boots=
trap=2Ejava:472)
> > > Caused by: java=2Elang=2EIllegalStateException: Could not inst=
all JACC
> > Policy Provider: org=2Eapache=2Eopenejb=2Ecore=2Esecurity=2EJaccPro=
vider$Policy
> > > at
> > org=2Eapache=2Eopenejb=2Ecore=2Esecurity=2EAbstractSecurityService=
=2EinstallPolicy(AbstractSecurityService=2Ejava:443)
> > > at
> > org=2Eapache=2Eopenejb=2Ecore=2Esecurity=2EAbstractSecurityService=
=2EinstallJacc(AbstractSecurityService=2Ejava:431)
> > > at
> > org=2Eapache=2Eopenejb=2Ecore=2Esecurity=2EAbstractSecurityService=
=2E<init>(AbstractSecurityService=2Ejava:94)
> > > at
> > org=2Eapache=2Eopenejb=2Ecore=2Esecurity=2EAbstractSecurityService=
=2E<init>(AbstractSecurityService=2Ejava:88)
> > > at
> > org=2Eapache=2Etomee=2Ecatalina=2ETomcatSecurityService=2E<init>(To=
mcatSecurityService=2Ejava:55)
> > > at
> > java=2Ebase/jdk=2Einternal=2Ereflect=2EDirectConstructorHandleAcces=
sor=2EnewInstance(DirectConstructorHandleAccessor=2Ejava:62)
> > > at
> > java=2Ebase/java=2Elang=2Ereflect=2EConstructor=2EnewInstanceWithCa=
ller(Constructor=2Ejava:499)
> > > at
> > java=2Ebase/java=2Elang=2Ereflect=2EConstructor=2EnewInstance(Const=
ructor=2Ejava:483)
> > > at
> > org=2Eapache=2Exbean=2Erecipe=2EReflectionUtil$ConstructorFactory=
=2Ecreate(ReflectionUtil=2Ejava:971)
> > > =2E=2E=2E 20 more
> > > Caused by: java=2Elang=2EUnsupportedOperationException: Settin=
g a
> > system-wide Policy object is not supported
> > > at java=2Ebase/java=2Esecurity=2EPolicy=2EsetPolicy(Policy=2E=
java:114)
> > > at
> > org=2Eapache=2Eopenejb=2Ecore=2Esecurity=2EAbstractSecurityService=
=2EinstallPolicy(AbstractSecurityService=2Ejava:441)
> > > =2E=2E=2E 28 more
> > >
> > >
> > >
> > > Is there something I should do about this (file a JIRA issue),=
or is the
> > Java 24 support already on your roadmap?
> > >
> > > Best regards
> > >
> > > Wolfgang
> >
> ></init></init></init></init></wolfgang=2Eknauf@gmx=2Ede=2Einvalid></=
rzo1@apache=2Eorg></body></html>