java.lang.IllegalStateException

JBAS011477: Persistence unit 'module2.ear/ejb.jar#module2-pu' is not available .... (stacktrace) 14:35:58,818 INFO [org.jboss.as.server.deployment] (MSC service thread 1-4) JBAS015876: Starting deployment of "module1.ear" (runtime-name: "module1.ear") 14:35:58,988 INFO [org.jboss.as.server.deployment] (MSC service thread 1-4) JBAS015973: Starting subdeployment (runtime-name: "ejb.jar") 14:35:58,989 INFO [org.jboss.as.jpa] (MSC service thread 1-4) JBAS011401: Read persistence.xml for module1-pu 14:35:59,002 INFO [org.jboss.weld.deployer] (MSC service thread 1-2) JBAS016002: Processing weld deployment module1.ear 14:35:59,005 INFO [org.jboss.as.jpa] (ServerService Thread Pool -- 102) JBAS011409: Starting Persistence Unit (phase 1 of 2) Service 'module1.ear/ejb.jar#module1-pu' 14:35:59,005 INFO [org.hibernate.jpa.internal.util.LogHelper] (ServerService Thread Pool -- 102) HHH000204: Processing PersistenceUnitInfo [ name: module1-pu ...] 14:35:59,047 INFO [org.jboss.weld.deployer] (MSC service thread 1-2) JBAS016002: Processing weld deployment ejb.jar 14:35:59,050 INFO [org.jboss.weld.deployer] (MSC service thread 1-1) JBAS016005: Starting Services for CDI deployment: module1.ear 14:35:59,051 INFO [org.jboss.weld.deployer] (MSC service thread 1-3) JBAS016008: Starting weld service for deployment module1.ear 14:35:59,058 INFO [org.jboss.as.jpa] (ServerService Thread Pool -- 102) JBAS011409: Starting Persistence Unit (phase 2 of 2) Service 'module1.ear/ejb.jar#module1-pu' 14:35:59,071 INFO [org.hibernate.dialect.Dialect] (ServerService Thread Pool -- 102) HHH000400: Using dialect: org.hibernate.dialect.PostgreSQL9Dialect 14:35:59,072 INFO [org.hibernate.engine.jdbc.internal.LobCreatorBuilder] (ServerService Thread Pool -- 102) HHH000424: Disabling contextual LOB creation as createClob() method threw error : java.lang.reflect.InvocationTargetException 14:35:59,077 INFO [org.hibernate.hql.internal.ast.ASTQueryTranslatorFactory] (ServerService Thread Pool -- 102) HHH000397: Using ASTQueryTranslatorFactory 14:35:59,078 INFO [org.hibernate.cache.spi.UpdateTimestampsCache] (ServerService Thread Pool -- 102) HHH000250: Starting update timestamps cache at region: module1.ear/ejb.jar#module1-pu.org.hibernate.cache.spi.UpdateTimestampsCache 14:35:59,079 INFO [org.infinispan.jmx.CacheJmxRegistration] (ServerService Thread Pool -- 102) ISPN000031: MBeans were successfully registered to the platform MBean server. 14:35:59,079 INFO [org.jboss.as.clustering.infinispan] (ServerService Thread Pool -- 102) JBAS010281: Started module1.ear/ejb.jar#module1-pu.org.hibernate.cache.spi.UpdateTimestampsCache cache from hibernate container 14:35:59,079 INFO [org.hibernate.cache.internal.StandardQueryCache] (ServerService Thread Pool -- 102) HHH000248: Starting query cache at region: module1.ear/ejb.jar#module1-pu.org.hibernate.cache.internal.StandardQueryCache 14:35:59,082 INFO [org.infinispan.jmx.CacheJmxRegistration] (ServerService Thread Pool -- 102) ISPN000031: MBeans were successfully registered to the platform MBean server. 14:35:59,082 INFO [org.jboss.as.clustering.infinispan] (ServerService Thread Pool -- 102) JBAS010281: Started module1.ear/ejb.jar#module1-pu.org.hibernate.cache.internal.StandardQueryCache cache from hibernate container 14:35:59,193 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015971: Deployment restart detected for deployment module2.ear, performing full redeploy instead. 14:35:59,193 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015971: Deployment restart detected for deployment ejb.jar, performing full redeploy instead. 14:35:59,193 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015974: Stopped subdeployment (runtime-name: ejb.jar) in 0ms 14:35:59,196 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015877: Stopped deployment module2.ear (runtime-name: module2.ear) in 2ms 14:35:59,196 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015876: Starting deployment of "module2.ear" (runtime-name: "module2.ear") 14:35:59,319 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015973: Starting subdeployment (runtime-name: "ejb.jar") 14:35:59,321 INFO [org.jboss.as.jpa] (MSC service thread 1-3) JBAS011401: Read persistence.xml for module2-pu 14:35:59,328 INFO [org.jboss.weld.deployer] (MSC service thread 1-4) JBAS016002: Processing weld deployment module2.ear 14:35:59,329 INFO [org.jboss.as.jpa] (ServerService Thread Pool -- 102) JBAS011409: Starting Persistence Unit (phase 1 of 2) Service 'module2.ear/ejb.jar#module2-pu' 14:35:59,329 INFO [org.hibernate.jpa.internal.util.LogHelper] (ServerService Thread Pool -- 102) HHH000204: Processing PersistenceUnitInfo [ name: module2-pu ...] 14:35:59,381 INFO [org.jboss.weld.deployer] (MSC service thread 1-4) JBAS016002: Processing weld deployment ejb.jar 14:35:59,383 INFO [org.jboss.weld.deployer] (MSC service thread 1-4) JBAS016005: Starting Services for CDI deployment: module2.ear 14:35:59,384 INFO [org.jboss.weld.deployer] (MSC service thread 1-4) JBAS016008: Starting weld service for deployment module2.ear 14:35:59,394 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-2) MSC000001: Failed to start service jboss.deployment.subunit."module2.ear"."ejb.jar".INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.subunit."module2.ear"."ejb.jar".INSTALL: JBAS018733: Failed to process phase INSTALL of subdeployment "ejb.jar" of deployment "module2.ear"

Solutions on the web37542

  • JBAS011477: Persistence unit 'module2.ear/ejb.jar#module2-pu' is not available .... (stacktrace) 14:35:58,818 INFO [org.jboss.as.server.deployment] (MSC service thread 1-4) JBAS015876: Starting deployment of "module1.ear" (runtime-name: "module1
  • via jboss.org by Unknown author, 10 months ago
    JBAS011477: Persistence unit 'module2.ear/ejb.jar#module2-pu' is not available .... (stacktrace) 14:35:58,818 INFO [org.jboss.as.server.deployment] (MSC service thread 1-4) JBAS015876: Starting deployment of "module1.ear" (runtime-name: "module1
  • JBAS011477: Persistence unit 'module2.ear/ejb.jar#module2-pu' is not available .... (stacktrace) 14:35:58,818 INFO [org.jboss.as.server.deployment] (MSC service thread 1-4) JBAS015876: Starting deployment of "module1.ear" (runtime-name: "module1
  • Stack trace

    • java.lang.IllegalStateException: JBAS011477: Persistence unit 'module2.ear/ejb.jar#module2-pu' is not available .... (stacktrace) 14:35:58,818 INFO [org.jboss.as.server.deployment] (MSC service thread 1-4) JBAS015876: Starting deployment of "module1.ear" (runtime-name: "module1.ear") 14:35:58,988 INFO [org.jboss.as.server.deployment] (MSC service thread 1-4) JBAS015973: Starting subdeployment (runtime-name: "ejb.jar") 14:35:58,989 INFO [org.jboss.as.jpa] (MSC service thread 1-4) JBAS011401: Read persistence.xml for module1-pu 14:35:59,002 INFO [org.jboss.weld.deployer] (MSC service thread 1-2) JBAS016002: Processing weld deployment module1.ear 14:35:59,005 INFO [org.jboss.as.jpa] (ServerService Thread Pool -- 102) JBAS011409: Starting Persistence Unit (phase 1 of 2) Service 'module1.ear/ejb.jar#module1-pu' 14:35:59,005 INFO [org.hibernate.jpa.internal.util.LogHelper] (ServerService Thread Pool -- 102) HHH000204: Processing PersistenceUnitInfo [ name: module1-pu ...] 14:35:59,047 INFO [org.jboss.weld.deployer] (MSC service thread 1-2) JBAS016002: Processing weld deployment ejb.jar 14:35:59,050 INFO [org.jboss.weld.deployer] (MSC service thread 1-1) JBAS016005: Starting Services for CDI deployment: module1.ear 14:35:59,051 INFO [org.jboss.weld.deployer] (MSC service thread 1-3) JBAS016008: Starting weld service for deployment module1.ear 14:35:59,058 INFO [org.jboss.as.jpa] (ServerService Thread Pool -- 102) JBAS011409: Starting Persistence Unit (phase 2 of 2) Service 'module1.ear/ejb.jar#module1-pu' 14:35:59,071 INFO [org.hibernate.dialect.Dialect] (ServerService Thread Pool -- 102) HHH000400: Using dialect: org.hibernate.dialect.PostgreSQL9Dialect 14:35:59,072 INFO [org.hibernate.engine.jdbc.internal.LobCreatorBuilder] (ServerService Thread Pool -- 102) HHH000424: Disabling contextual LOB creation as createClob() method threw error : java.lang.reflect.InvocationTargetException 14:35:59,077 INFO [org.hibernate.hql.internal.ast.ASTQueryTranslatorFactory] (ServerService Thread Pool -- 102) HHH000397: Using ASTQueryTranslatorFactory 14:35:59,078 INFO [org.hibernate.cache.spi.UpdateTimestampsCache] (ServerService Thread Pool -- 102) HHH000250: Starting update timestamps cache at region: module1.ear/ejb.jar#module1-pu.org.hibernate.cache.spi.UpdateTimestampsCache 14:35:59,079 INFO [org.infinispan.jmx.CacheJmxRegistration] (ServerService Thread Pool -- 102) ISPN000031: MBeans were successfully registered to the platform MBean server. 14:35:59,079 INFO [org.jboss.as.clustering.infinispan] (ServerService Thread Pool -- 102) JBAS010281: Started module1.ear/ejb.jar#module1-pu.org.hibernate.cache.spi.UpdateTimestampsCache cache from hibernate container 14:35:59,079 INFO [org.hibernate.cache.internal.StandardQueryCache] (ServerService Thread Pool -- 102) HHH000248: Starting query cache at region: module1.ear/ejb.jar#module1-pu.org.hibernate.cache.internal.StandardQueryCache 14:35:59,082 INFO [org.infinispan.jmx.CacheJmxRegistration] (ServerService Thread Pool -- 102) ISPN000031: MBeans were successfully registered to the platform MBean server. 14:35:59,082 INFO [org.jboss.as.clustering.infinispan] (ServerService Thread Pool -- 102) JBAS010281: Started module1.ear/ejb.jar#module1-pu.org.hibernate.cache.internal.StandardQueryCache cache from hibernate container 14:35:59,193 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015971: Deployment restart detected for deployment module2.ear, performing full redeploy instead. 14:35:59,193 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015971: Deployment restart detected for deployment ejb.jar, performing full redeploy instead. 14:35:59,193 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015974: Stopped subdeployment (runtime-name: ejb.jar) in 0ms 14:35:59,196 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015877: Stopped deployment module2.ear (runtime-name: module2.ear) in 2ms 14:35:59,196 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015876: Starting deployment of "module2.ear" (runtime-name: "module2.ear") 14:35:59,319 INFO [org.jboss.as.server.deployment] (MSC service thread 1-3) JBAS015973: Starting subdeployment (runtime-name: "ejb.jar") 14:35:59,321 INFO [org.jboss.as.jpa] (MSC service thread 1-3) JBAS011401: Read persistence.xml for module2-pu 14:35:59,328 INFO [org.jboss.weld.deployer] (MSC service thread 1-4) JBAS016002: Processing weld deployment module2.ear 14:35:59,329 INFO [org.jboss.as.jpa] (ServerService Thread Pool -- 102) JBAS011409: Starting Persistence Unit (phase 1 of 2) Service 'module2.ear/ejb.jar#module2-pu' 14:35:59,329 INFO [org.hibernate.jpa.internal.util.LogHelper] (ServerService Thread Pool -- 102) HHH000204: Processing PersistenceUnitInfo [ name: module2-pu ...] 14:35:59,381 INFO [org.jboss.weld.deployer] (MSC service thread 1-4) JBAS016002: Processing weld deployment ejb.jar 14:35:59,383 INFO [org.jboss.weld.deployer] (MSC service thread 1-4) JBAS016005: Starting Services for CDI deployment: module2.ear 14:35:59,384 INFO [org.jboss.weld.deployer] (MSC service thread 1-4) JBAS016008: Starting weld service for deployment module2.ear 14:35:59,394 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-2) MSC000001: Failed to start service jboss.deployment.subunit."module2.ear"."ejb.jar".INSTALL: org.jboss.msc.service.StartException in service jboss.deployment.subunit."module2.ear"."ejb.jar".INSTALL: JBAS018733: Failed to process phase INSTALL of subdeployment "ejb.jar" of deployment "module2.ear" at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:166)[wildfly-server-8.2.0.Final.jar:8.2.0.Final] at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1948)[jboss-msc-1.2.2.Final.jar:1.2.2.Final] at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1881)[jboss-msc-1.2.2.Final.jar:1.2.2.Final] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)[rt.jar:1.8.0_45] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)[rt.jar:1.8.0_45] at java.lang.Thread.run(Thread.java:745)[rt.jar:1.8.0_45] Caused by: java.lang.IllegalStateException: JBAS014666: Duplicate resource module2.ear/ejb.jar#module2-pu at org.jboss.as.controller.registry.AbstractModelResource$DefaultResourceProvider.register(AbstractModelResource.java:224) at org.jboss.as.controller.registry.AbstractModelResource.registerChild(AbstractModelResource.java:134) at org.jboss.as.jpa.processor.PersistenceUnitServiceHandler.addManagementConsole(PersistenceUnitServiceHandler.java:1077) at org.jboss.as.jpa.processor.PersistenceUnitServiceHandler.deployPersistenceUnitPhaseTwo(PersistenceUnitServiceHandler.java:687) at org.jboss.as.jpa.processor.PersistenceUnitServiceHandler.addPuService(PersistenceUnitServiceHandler.java:280) at org.jboss.as.jpa.processor.PersistenceUnitServiceHandler.handleJarDeployment(PersistenceUnitServiceHandler.java:153) at org.jboss.as.jpa.processor.PersistenceUnitServiceHandler.deploy(PersistenceUnitServiceHandler.java:128) at org.jboss.as.jpa.processor.PersistenceCompleteInstallProcessor.deploy(PersistenceCompleteInstallProcessor.java:55) at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:159)[wildfly-server-8.2.0.Final.jar:8.2.0.Final] ... 5 more

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    You are the first who have seen this exception. Write a tip to help other users and build your expert profile.