Jboss Enterprise Application Server / Wildfly Known Exceptions and Errors
Jboss EAP / Wildfly Deployment Exceptions and Errors
#1. IllegalArgumentException: Bean is already defined in this module
#2. Java.lang.OutOfMemoryError: PermGen space
java.lang.IllegalArgumentException: JBAS011046: A component named 'ApplicationLoginBean' is already defined in this module
08:23:06,628 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-5) MSC000001: Failed to start service jboss.deployment.unit."MyService-6.1.war".PARSE: org.j
boss.msc.service.StartException in service jboss.deployment.unit."MyService-6.1.war".PARSE: JBAS018733: Failed to process phase PARSE of deployment "MyService-6.1.war"
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:127) [jboss-as-server-7.2.0.Final-redhat-8.jar:7.2.0.Final-re
dhat-8]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.4.GA-redhat-1.jar:1.0.4.GA-redhat-1]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.4.GA-redhat-1.jar:1.0.4.GA-redhat-1]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1152) [rt.jar:1.7.0_181]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:622) [rt.jar:1.7.0_181]
at java.lang.Thread.run(Thread.java:748) [rt.jar:1.7.0_181]
Caused by: java.lang.IllegalArgumentException: JBAS011046: A component named 'ApplicationLoginBean' is already defined in this module
at org.jboss.as.ee.component.EEModuleDescription.addComponent(EEModuleDescription.java:140)
at org.jboss.as.ejb3.deployment.processors.EJBComponentDescriptionFactory.addComponent(EJBComponentDescriptionFactory.java:60)
at org.jboss.as.ejb3.deployment.processors.SessionBeanComponentDescriptionFactory.processSessionBeans(SessionBeanComponentDescriptionFactory.java:155)
at org.jboss.as.ejb3.deployment.processors.SessionBeanComponentDescriptionFactory.processAnnotations(SessionBeanComponentDescriptionFactory.java:84)
at org.jboss.as.ejb3.deployment.processors.AnnotatedEJBComponentDescriptionDeploymentUnitProcessor.processAnnotations(AnnotatedEJBComponentDescriptionDeployment
UnitProcessor.java:58)
at org.jboss.as.ejb3.deployment.processors.AbstractDeploymentUnitProcessor.deploy(AbstractDeploymentUnitProcessor.java:81)
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:120) [jboss-as-server-7.2.0.Final-redhat-8.jar:7.2.0.Final-re
dhat-8]
... 5 more
08:23:06,633 ERROR [org.jboss.as.server] (host-controller-connection-threads - 9) JBAS015870: Deploy of deployment "MyService-6.1.war" was rolled back with the fo
llowing failure message:
{"JBAS014671: Failed services" => {"jboss.deployment.unit.\"MyService-6.1.war\".PARSE" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\
"MyService-6.1.war\".PARSE: JBAS018733: Failed to process phase PARSE of deployment \"MyService-6.1.war\"
Caused by: java.lang.IllegalArgumentException: JBAS011046: A component named 'ApplicationLoginBean' is already defined in this module"}}
08:23:06,655 INFO [org.jboss.as.server.deployment] (MSC service thread 1-6) JBAS015877: Stopped deployment MyService-6.1.war (runtime-name: MyService-6.1.war) in 22ms
java.lang.IllegalArgumentException: is already defined in this module, Exception is thrown when the Jboss finds duplicate bean within the deployment context. In order to resolve this error make sure.
- Bean is defined only once.
- Verify all Jars within the EAR or WAR file and make sure that none of the jar files having the same bean name.
- If you come across multiple jars having classes with the same bean name then you have to remove or rename one of the bean.
Java.lang.OutOfMemoryError: PermGen space Error
08:52:53,077 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-4) MSC000001: Failed to start service jboss.deployment.unit."MyService.war".INSTALL: org
.jboss.msc.service.StartException in service jboss.deployment.unit."MyService.war".INSTALL: JBAS018733: Failed to process phase INSTALL of deployment "MyService.war"
at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:127) [jboss-as-server-7.2.0.Final-redhat-8.jar:7.2.0.Final-re
dhat-8]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.4.GA-redhat-1.jar:1.0.4.GA-redhat-1]
at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.4.GA-redhat-1.jar:1.0.4.GA-redhat-1]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1152) [rt.jar:1.7.0_181]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:622) [rt.jar:1.7.0_181]
at java.lang.Thread.run(Thread.java:748) [rt.jar:1.7.0_181]
Caused by: java.lang.OutOfMemoryError: PermGen space
08:52:53,291 ERROR [org.jboss.as.server] (host-controller-connection-threads - 10) JBAS015870: Deploy of deployment "MyService.war" was rolled back with the f
ollowing failure message:
{"JBAS014671: Failed services" => {"jboss.deployment.unit.\"MyService.war\".INSTALL" => "org.jboss.msc.service.StartException in service jboss.deployment.unit
.\"MyService.war\".INSTALL: JBAS018733: Failed to process phase INSTALL of deployment \"MyService.war\"
Caused by: java.lang.OutOfMemoryError: PermGen space"}}
08:52:53,317 INFO [org.jboss.as.server.deployment] (MSC service thread 1-1) JBAS015877: Stopped deployment MyService.war (runtime-name: MyService.war) in 26ms
08:54:12,134 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/con/rest].[javax.ws.rs.core.Application]] (ajp-localhost.localdomain/12
7.0.0.1:8019-4) JBWEB000236: Servlet.service() for servlet javax.ws.rs.core.Application threw exception: java.lang.OutOfMemoryError: PermGen space
Java.lang.OutOfMemoryError: PermGen space ERROR is thrown when jboss heap is running out of space. Quick fix for this would be to restart the JBOSS server.
[tech@mysever ~]$ sudo /etc/init.d/jboss-domain restart
Stopping jboss-as: [ OK ]
Starting jboss-as: [ OK ]