Tengo un proyecto que está desarrollado con Java 11 y JBoss EAP 7.2.0.GA (WildFly Core 6.0.11.Final-redhat-00001) Con la recién salida de Java 17 me han solicitado la actualización de Java 11 a Java 17 y manteniendo la versión de JBoss 7.2 pero estoy obteniendo el siguiente error.
jboss.deployment.unit."proyecto.war".WeldStartService: Failed to start service
at [email protected]//org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1730)
at [email protected]//org.jboss.msc.service.ServiceControllerImpl$ControllerTask.run(ServiceControllerImpl.java:1558)
at [email protected]//org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
at [email protected]//org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1985)
at [email protected]//org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1487)
at [email protected]//org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1378)
at java.base/java.lang.Thread.run(Thread.java:833)
Caused by: org.jboss.weld.exceptions.WeldException: WELD-001524: Unable to load proxy class for bean Built-in Bean [javax.transaction.UserTransaction] with qualifiers [@Default] with class interface javax.transaction.UserTransaction using classloader ModuleClassLoader for Module "org.jboss.weld.core" version 3.0.5.Final-redhat-00001 from local module loader @2e385cce (finder: local module finder @2ddc9a9f (roots: \jboss-eap-7.2\modules,\jboss-eap-7.2\modules\system\layers\base))
at [email protected]//org.jboss.weld.bean.proxy.ProxyFactory.getProxyClass(ProxyFactory.java:370)
at [email protected]//org.jboss.weld.bean.proxy.ProxyFactory.run(ProxyFactory.java:324)
at [email protected]//org.jboss.weld.bean.proxy.ProxyFactory.create(ProxyFactory.java:316)
at [email protected]//org.jboss.weld.bean.builtin.ee.AbstractEEBean.<init>(AbstractEEBean.java:36)
at [email protected]//org.jboss.weld.module.jta.UserTransactionBean.<init>(UserTransactionBean.java:52)
at [email protected]//org.jboss.weld.module.jta.WeldTransactionsModule.preBeanRegistration(WeldTransactionsModule.java:46)
at [email protected]//org.jboss.weld.module.WeldModules.preBeanRegistration(WeldModules.java:158)
at [email protected]//org.jboss.weld.bootstrap.BeanDeployment.createBeans(BeanDeployment.java:224)
at [email protected]//org.jboss.weld.bootstrap.WeldStartup.deployBeans(WeldStartup.java:432)
at [email protected]//org.jboss.weld.bootstrap.WeldBootstrap.deployBeans(WeldBootstrap.java:86)
at [email protected]//org.jboss.as.weld.WeldStartService.start(WeldStartService.java:96)
at [email protected]//org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1738)
at [email protected]//org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1700)
... 6 more
Caused by: java.lang.Error: java.lang.NoSuchFieldException: override
at [email protected]//org.jboss.classfilewriter.ClassFile$1.run(ClassFile.java:394)
at [email protected]//org.jboss.classfilewriter.ClassFile$1.run(ClassFile.java:385)
at java.base/java.security.AccessController.doPrivileged(AccessController.java:569)
at [email protected]//org.jboss.classfilewriter.ClassFile.<clinit>(ClassFile.java:385)
at [email protected]//org.jboss.weld.bean.proxy.ProxyFactory.newClassFile(ProxyFactory.java:476)
at [email protected]//org.jboss.weld.bean.proxy.ProxyFactory.createProxyClass(ProxyFactory.java:436)
at [email protected]//org.jboss.weld.bean.proxy.ProxyFactory.getProxyClass(ProxyFactory.java:362)
... 18 more
Caused by: java.lang.NoSuchFieldException: override
at java.base/java.lang.Class.getDeclaredField(Class.java:2610)
at [email protected]//org.jboss.classfilewriter.ClassFile$1.run(ClassFile.java:392)
Estuve investigando y encontré que actualizando la versión del weld de la 3.0.5 a la 3.1.1 se soluciona el problema pero ahora obtento otro error.
Los directorios y bibliotecas y module.xml actualizados son los siguientes:
*jboss-eap-7.2\modules\system\layers\base\org\jboss\weld\core\main*
weld-web-3.0.5.Final-redhat-00001.jar -> weld-web-3.1.1.Final-redhat-00001.jar
weld-jta-3.0.5.Final-redhat-00001.jar -> weld-jta-3.1.1.Final-redhat-00001.jar
weld-ejb-3.0.5.Final-redhat-00001.jar -> weld-ejb-3.1.1.Final-redhat-00001.jar
weld-core-impl-3.0.5.Final-redhat-00001.jar -> weld-core-impl-3.1.1.Final-redhat-00001.jar
*jboss-eap-7.2\modules\system\layers\base\org\jboss\weld\probe\main*
weld-probe-core-3.0.5.Final-redhat-00001.jar -> weld-probe-core-3.1.1.Final-redhat-00001.jar
*jboss-eap-7.2\modules\system\layers\base\org\jboss\msc\main*
jboss-msc-1.4.5.Final-redhat-00001.jar -> jboss-msc-1.4.11.Final-redhat-00001.jar
*jboss-eap-7.2\modules\system\layers\base\org\jboss\as\jsf-injection\main*
weld-jsf-3.0.5.Final-redhat-00001.jar -> weld-jsf-3.1.1.Final-redhat-00001.jar
Sin embargo aún después de hacer esta actualización ahora obtengo el error:
00:55:40,788 WARN [org.jboss.as.ee] (MSC service thread 1-8) WFLYEE0007: No se está instalando el componente opcional mx.ine.evalSEyCAE.seguridad.ServletCaptcha debido a una excepción (active el nivel de registro DEBUG para ver la razón)
00:55:40,833 INFO [org.jboss.weld.Version] (MSC service thread 1-8) WELD-000900: 3.1.1 (redhat)
00:55:40,907 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-5) MSC000001: Failed to start service jboss.deployment.unit."evalSEyCAE.war".WeldBootstrapService: org.jboss.msc.service.StartException in service jboss.deployment.unit."evalSEyCAE.war".WeldBootstrapService: Failed to start service
at [email protected]//org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1731)
at [email protected]//org.jboss.msc.service.ServiceControllerImpl$ControllerTask.run(ServiceControllerImpl.java:1559)
at [email protected]//org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
at [email protected]//org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1985)
at [email protected]//org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1487)
at [email protected]//org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1378)
at java.base/java.lang.Thread.run(Thread.java:833)
Caused by: java.lang.NoSuchMethodError: 'boolean org.jboss.weld.serialization.spi.ProxyServices.supportsClassDefining()'
at [email protected]//org.jboss.weld.bootstrap.WeldStartup.startContainer(WeldStartup.java:218)
at [email protected]//org.jboss.weld.bootstrap.WeldBootstrap.startContainer(WeldBootstrap.java:72)
at [email protected]//org.jboss.as.weld.WeldBootstrapService.start(WeldBootstrapService.java:129)
at [email protected]//org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1739)
at [email protected]//org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1701)
... 6 more
Entiendo que no encuentra el método pero ¿Alguien tiene idea de qué me puede estar faltando o cómo se podría solucionar este error?.
Gracias