[jboss-jira] [JBoss JIRA] (WFLY-10062) Application deployment fails with java.lang.NoClassDefFoundError: javax/enterprise/inject/Any$Literal
Matej Novotny (JIRA)
issues at jboss.org
Wed Mar 21 11:23:00 EDT 2018
[ https://issues.jboss.org/browse/WFLY-10062?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13549233#comment-13549233 ]
Matej Novotny edited comment on WFLY-10062 at 3/21/18 11:22 AM:
----------------------------------------------------------------
Possible workaround would be to enable EE 8 mode, that should give you CDI API 2.0 jar which contains this.
Also, the fix for this is to upgrade Weld version where we will correct this (3.0.4.Final).
Weld release schedule can be seen [here|https://issues.jboss.org/projects/WELD?selectedItem=com.atlassian.jira.jira-projects-plugin%3Arelease-page&status=released-unreleased].
was (Author: manovotn):
Possible workaround would be to enable EE 8 mode, that should give you CDI API 2.0 jar which contains this.
> Application deployment fails with java.lang.NoClassDefFoundError: javax/enterprise/inject/Any$Literal
> -----------------------------------------------------------------------------------------------------
>
> Key: WFLY-10062
> URL: https://issues.jboss.org/browse/WFLY-10062
> Project: WildFly
> Issue Type: Bug
> Components: CDI / Weld
> Affects Versions: 12.0.0.Final
> Reporter: Rich DiCroce
> Assignee: Martin Kouba
>
> Application fails to deploy with the below stack trace. EE8 preview mode is NOT enabled, which appears to be the cause. cdi-api-2.0.jar contains the class, but cdi-api-1.2.jar does not.
> {quote}
> 10:27:34,790 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-3) MSC000001: Failed to start service jboss.deployment.unit."song-gaming-portal.war".WeldStartService: org.jboss.msc.service.StartException in service jboss.deployment.unit."song-gaming-portal.war".WeldStartService: Failed to start service
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1706)
> at org.jboss.msc.service.ServiceControllerImpl$ControllerTask.run(ServiceControllerImpl.java:1540)
> at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
> at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1985)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1487)
> at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1378)
> at java.lang.Thread.run(Thread.java:748) [rt.jar:1.8.0_162]
> Caused by: java.lang.NoClassDefFoundError: javax/enterprise/inject/Any$Literal
> at org.jboss.weld.util.Observers.isContainerLifecycleObserverMethod(Observers.java:102) [weld-core-impl-3.0.3.Final.jar:3.0.3.Final]
> at org.jboss.weld.bootstrap.ExtensionBeanDeployer.createObserverMethod(ExtensionBeanDeployer.java:151) [weld-core-impl-3.0.3.Final.jar:3.0.3.Final]
> at org.jboss.weld.bootstrap.ExtensionBeanDeployer.createObserverMethods(ExtensionBeanDeployer.java:140) [weld-core-impl-3.0.3.Final.jar:3.0.3.Final]
> at org.jboss.weld.bootstrap.ExtensionBeanDeployer.deployBean(ExtensionBeanDeployer.java:101) [weld-core-impl-3.0.3.Final.jar:3.0.3.Final]
> at org.jboss.weld.bootstrap.ExtensionBeanDeployer.deployBeans(ExtensionBeanDeployer.java:75) [weld-core-impl-3.0.3.Final.jar:3.0.3.Final]
> at org.jboss.weld.bootstrap.WeldStartup.startInitialization(WeldStartup.java:377) [weld-core-impl-3.0.3.Final.jar:3.0.3.Final]
> at org.jboss.weld.bootstrap.WeldBootstrap.startInitialization(WeldBootstrap.java:76) [weld-core-impl-3.0.3.Final.jar:3.0.3.Final]
> at org.jboss.as.weld.WeldStartService.start(WeldStartService.java:95)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1714)
> at org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1693)
> ... 6 more
> Caused by: java.lang.ClassNotFoundException: javax.enterprise.inject.Any$Literal from [Module "org.jboss.weld.core" from local module loader @2ea6137 (finder: local module finder @41ee392b (roots: D:\wildfly\wildfly-12.0.0.Final-GP\modules,D:\wildfly\wildfly-12.0.0.Final-GP\modules\system\layers\base))]
> at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:199) [jboss-modules.jar:1.7.0.Final]
> at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:412) [jboss-modules.jar:1.7.0.Final]
> at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:400) [jboss-modules.jar:1.7.0.Final]
> at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:116) [jboss-modules.jar:1.7.0.Final]
> ... 16 more
> {quote}
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
More information about the jboss-jira
mailing list