Bug Report: Could not initialize class ClassCopierOrdinaryImpl #6524
Labels
Status: Open
Issue has been triaged by the front-line engineers and is being worked on verification
Type: Bug
Label issue as a bug defect
Brief Summary
While deploying some applications the named error gets thrown. I can't seem to find why this is happening. On my main PC it works without any problems, on my other machines it doesn'tm even though it did without any problems in the past.
Expected Outcome
Expected outcome is the application be succesfully deployed
Current Outcome
The error gets thrown when I tryto deploy the .war file of the microservice.
I tried to re-produce this with different operating systems and machines.
Payara: 6.2023.9
PC 1 (Win11): Deploys correctly
PC 2 (Win11, fresh install): Throws the error
PC 3 (Arch Linux): Throws the error
PC 4 (Debian): Throws the error
All machines have a fully setup java development environment and use the exact same payara server.
(Server files are located on a home-server).
Stacktrace
[2024-01-10T15:59:50.780+0100] [Payara 6.2023.9] [SEVERE] [NCLS-CORE-00026] [javax.enterprise.system.core] [tid: _ThreadID=179 _ThreadName=admin-thread-pool::admin-listener(4)] [timeMillis: 1704898790780] [levelValue: 1000] [[
Exception during lifecycle processing
java.lang.NoClassDefFoundError: Could not initialize class org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierOrdinaryImpl
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper$PackageContext.(Wrapper.java:477)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper$Environment._clear(Wrapper.java:693)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper$Environment.(Wrapper.java:688)
at java.base/java.lang.ThreadLocal$SuppliedThreadLocal.initialValue(ThreadLocal.java:305)
at java.base/java.lang.ThreadLocal.setInitialValue(ThreadLocal.java:195)
at java.base/java.lang.ThreadLocal.get(ThreadLocal.java:172)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper.env(Wrapper.java:886)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper._clear(Wrapper.java:1142)
at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:242)
at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:286)
at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:104)
at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:218)
at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:334)
at com.sun.enterprise.v3.server.ApplicationLifecycle.prepare(ApplicationLifecycle.java:580)
at org.glassfish.deployment.admin.DeployCommand.execute(DeployCommand.java:570)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:556)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$2$1.run(CommandRunnerImpl.java:552)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
at java.base/javax.security.auth.Subject.doAs(Subject.java:376)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$2.execute(CommandRunnerImpl.java:551)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$3.run(CommandRunnerImpl.java:582)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$3.run(CommandRunnerImpl.java:574)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:399)
at java.base/javax.security.auth.Subject.doAs(Subject.java:376)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:573)
at com.sun.enterprise.v3.admin.CommandRunnerImpl.doCommand(CommandRunnerImpl.java:1497)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1879)
at com.sun.enterprise.v3.admin.CommandRunnerImpl$ExecutionContext.execute(CommandRunnerImpl.java:1755)
at org.glassfish.admin.rest.utils.ResourceUtil.runCommand(ResourceUtil.java:272)
at org.glassfish.admin.rest.utils.ResourceUtil.runCommand(ResourceUtil.java:240)
at org.glassfish.admin.rest.utils.ResourceUtil.runCommand(ResourceUtil.java:294)
at org.glassfish.admin.rest.resources.TemplateListOfResource.createResource(TemplateListOfResource.java:136)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:568)
at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory.lambda$static$0(ResourceMethodInvocationHandlerFactory.java:52)
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher$1.run(AbstractJavaResourceMethodDispatcher.java:134)
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:177)
at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:176)
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:81)
at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:478)
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:400)
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:81)
at org.glassfish.jersey.server.ServerRuntime$1.run(ServerRuntime.java:261)
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:248)
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:244)
at org.glassfish.jersey.internal.Errors.process(Errors.java:292)
at org.glassfish.jersey.internal.Errors.process(Errors.java:274)
at org.glassfish.jersey.internal.Errors.process(Errors.java:244)
at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:265)
at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:240)
at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:697)
at org.glassfish.jersey.grizzly2.httpserver.GrizzlyHttpContainer.service(GrizzlyHttpContainer.java:367)
at org.glassfish.admin.rest.adapter.RestAdapter$2.service(RestAdapter.java:335)
at org.glassfish.admin.rest.adapter.RestAdapter.service(RestAdapter.java:189)
at com.sun.enterprise.v3.services.impl.ContainerMapper$HttpHandlerCallable.call(ContainerMapper.java:520)
at com.sun.enterprise.v3.services.impl.ContainerMapper.service(ContainerMapper.java:217)
at org.glassfish.grizzly.http.server.HttpHandler.runService(HttpHandler.java:174)
at org.glassfish.grizzly.http.server.HttpHandler.doHandle(HttpHandler.java:153)
at org.glassfish.grizzly.http.server.HttpServerFilter.handleRead(HttpServerFilter.java:196)
at org.glassfish.grizzly.filterchain.ExecutorResolver$9.execute(ExecutorResolver.java:88)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeFilter(DefaultFilterChain.java:246)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.executeChainPart(DefaultFilterChain.java:178)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.execute(DefaultFilterChain.java:118)
at org.glassfish.grizzly.filterchain.DefaultFilterChain.process(DefaultFilterChain.java:96)
at org.glassfish.grizzly.ProcessorExecutor.execute(ProcessorExecutor.java:51)
at org.glassfish.grizzly.nio.transport.TCPNIOTransport.fireIOEvent(TCPNIOTransport.java:510)
at org.glassfish.grizzly.strategies.AbstractIOStrategy.fireIOEvent(AbstractIOStrategy.java:82)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy.run0(WorkerThreadIOStrategy.java:83)
at org.glassfish.grizzly.strategies.WorkerThreadIOStrategy$WorkerThreadRunnable.run(WorkerThreadIOStrategy.java:101)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.doWork(AbstractThreadPool.java:535)
at org.glassfish.grizzly.threadpool.AbstractThreadPool$Worker.run(AbstractThreadPool.java:515)
at java.base/java.lang.Thread.run(Thread.java:840)
Caused by: java.lang.ExceptionInInitializerError: Exception java.lang.reflect.InaccessibleObjectException: Unable to make private static java.lang.ClassLoader java.io.ObjectInputStream.latestUserDefinedLoader() accessible: module java.base does not "opens java.io" to unnamed module @4a5b48ff [in thread "RunLevelControllerThread-1704898313642"]
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:354)
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
at java.base/java.lang.reflect.Method.checkCanSetAccessible(Method.java:199)
at java.base/java.lang.reflect.Method.setAccessible(Method.java:193)
at org.glassfish.pfl.basic.reflection.Bridge$1.run(Bridge.java:90)
at org.glassfish.pfl.basic.reflection.Bridge$1.run(Bridge.java:82)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)
at org.glassfish.pfl.basic.reflection.Bridge.getLatestUserDefinedLoaderMethod(Bridge.java:81)
at org.glassfish.pfl.basic.reflection.Bridge.(Bridge.java:129)
at org.glassfish.pfl.basic.reflection.Bridge.get(Bridge.java:154)
at org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierOrdinaryImpl$1.run(ClassCopierOrdinaryImpl.java:58)
at org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierOrdinaryImpl$1.run(ClassCopierOrdinaryImpl.java:55)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)
at org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierOrdinaryImpl.(ClassCopierOrdinaryImpl.java:54)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper$PackageContext.(Wrapper.java:477)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper$Environment._clear(Wrapper.java:693)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper$Environment.(Wrapper.java:688)
at java.base/java.lang.ThreadLocal$SuppliedThreadLocal.initialValue(ThreadLocal.java:305)
at java.base/java.lang.ThreadLocal.setInitialValue(ThreadLocal.java:195)
at java.base/java.lang.ThreadLocal.get(ThreadLocal.java:172)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper.env(Wrapper.java:886)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper._clear(Wrapper.java:1142)
at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:242)
at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:286)
at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:104)
at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:218)
at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:334)
at com.sun.enterprise.v3.server.ApplicationLifecycle.prepare(ApplicationLifecycle.java:580)
at com.sun.enterprise.v3.server.ApplicationLoaderService.processApplication(ApplicationLoaderService.java:427)
at com.sun.enterprise.v3.server.ApplicationLoaderService.postConstruct(ApplicationLoaderService.java:259)
at org.jvnet.hk2.internal.ClazzCreator.postConstructMe(ClazzCreator.java:303)
at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:351)
at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:466)
at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:281)
at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:65)
at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2103)
at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:93)
at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:67)
at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.oneJob(CurrentTaskFuture.java:1213)
at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.run(CurrentTaskFuture.java:1144)
at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$UpOneLevel.run(CurrentTaskFuture.java:762)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
... 1 more
]]
[2024-01-10T15:59:50.781+0100] [Payara 6.2023.9] [SEVERE] [] [javax.enterprise.system.core] [tid: _ThreadID=179 _ThreadName=admin-thread-pool::admin-listener(4)] [timeMillis: 1704898790781] [levelValue: 1000] [[
Exception while loading the app]]
[2024-01-10T15:59:50.788+0100] [Payara 6.2023.9] [SEVERE] [] [javax.enterprise.system.core] [tid: _ThreadID=179 _ThreadName=admin-thread-pool::admin-listener(4)] [timeMillis: 1704898790788] [levelValue: 1000] [[
Exception while loading the app : Could not initialize class org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierOrdinaryImpl
java.lang.ExceptionInInitializerError: Exception java.lang.reflect.InaccessibleObjectException: Unable to make private static java.lang.ClassLoader java.io.ObjectInputStream.latestUserDefinedLoader() accessible: module java.base does not "opens java.io" to unnamed module @4a5b48ff [in thread "RunLevelControllerThread-1704898313642"]
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:354)
at java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
at java.base/java.lang.reflect.Method.checkCanSetAccessible(Method.java:199)
at java.base/java.lang.reflect.Method.setAccessible(Method.java:193)
at org.glassfish.pfl.basic.reflection.Bridge$1.run(Bridge.java:90)
at org.glassfish.pfl.basic.reflection.Bridge$1.run(Bridge.java:82)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)
at org.glassfish.pfl.basic.reflection.Bridge.getLatestUserDefinedLoaderMethod(Bridge.java:81)
at org.glassfish.pfl.basic.reflection.Bridge.(Bridge.java:129)
at org.glassfish.pfl.basic.reflection.Bridge.get(Bridge.java:154)
at org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierOrdinaryImpl$1.run(ClassCopierOrdinaryImpl.java:58)
at org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierOrdinaryImpl$1.run(ClassCopierOrdinaryImpl.java:55)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:318)
at org.glassfish.pfl.dynamic.copyobject.impl.ClassCopierOrdinaryImpl.(ClassCopierOrdinaryImpl.java:54)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper$PackageContext.(Wrapper.java:477)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper$Environment._clear(Wrapper.java:693)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper$Environment.(Wrapper.java:688)
at java.base/java.lang.ThreadLocal$SuppliedThreadLocal.initialValue(ThreadLocal.java:305)
at java.base/java.lang.ThreadLocal.setInitialValue(ThreadLocal.java:195)
at java.base/java.lang.ThreadLocal.get(ThreadLocal.java:172)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper.env(Wrapper.java:886)
at org.glassfish.pfl.dynamic.codegen.spi.Wrapper._clear(Wrapper.java:1142)
at org.glassfish.ejb.startup.EjbApplication.loadContainers(EjbApplication.java:242)
at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:286)
at org.glassfish.ejb.startup.EjbDeployer.load(EjbDeployer.java:104)
at org.glassfish.internal.data.ModuleInfo.load(ModuleInfo.java:218)
at org.glassfish.internal.data.ApplicationInfo.load(ApplicationInfo.java:334)
at com.sun.enterprise.v3.server.ApplicationLifecycle.prepare(ApplicationLifecycle.java:580)
at com.sun.enterprise.v3.server.ApplicationLoaderService.processApplication(ApplicationLoaderService.java:427)
at com.sun.enterprise.v3.server.ApplicationLoaderService.postConstruct(ApplicationLoaderService.java:259)
at org.jvnet.hk2.internal.ClazzCreator.postConstructMe(ClazzCreator.java:303)
at org.jvnet.hk2.internal.ClazzCreator.create(ClazzCreator.java:351)
at org.jvnet.hk2.internal.SystemDescriptor.create(SystemDescriptor.java:466)
at org.glassfish.hk2.runlevel.internal.AsyncRunLevelContext.findOrCreate(AsyncRunLevelContext.java:281)
at org.glassfish.hk2.runlevel.RunLevelContext.findOrCreate(RunLevelContext.java:65)
at org.jvnet.hk2.internal.Utilities.createService(Utilities.java:2103)
at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:93)
at org.jvnet.hk2.internal.ServiceHandleImpl.getService(ServiceHandleImpl.java:67)
at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.oneJob(CurrentTaskFuture.java:1213)
at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$QueueRunner.run(CurrentTaskFuture.java:1144)
at org.glassfish.hk2.runlevel.internal.CurrentTaskFuture$UpOneLevel.run(CurrentTaskFuture.java:762)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at java.base/java.lang.Thread.run(Thread.java:840)
]]
Reproducer
https://github.com/DubskySteam/AQP/releases/download/stable_24.1/admin-1.4.war
or download (admin-1.4.war) directly from release:
https://github.com/DubskySteam/AQP/releases/tag/stable_24.1
Operating System
Windows 11, Arch Linux, Debian
JDK Version
OpenJDK 17
Payara Distribution
Payara Server Web Profile
The text was updated successfully, but these errors were encountered: