This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes EJB and other Java EE Technologies and the fly likes No persistence unit named 'entityManager' is available in scope MyFacade.jar. Available persistence Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "No persistence unit named Watch "No persistence unit named New topic
Author

No persistence unit named 'entityManager' is available in scope MyFacade.jar. Available persistence

shirish singh
Greenhorn

Joined: Mar 25, 2011
Posts: 1
Any Idea about the folwoing error:

module: EJBModule(MyFacade.jar)
Unable to deploy EJB: MerchantFacadeBean from MyFacade.jar:
No persistence unit named 'entityManager' is available in scope MyFacade.jar. Available persistence units: []
.
weblogic.application.ModuleException: Exception preparing module: EJBModule(MyFacade.jar)
Unable to deploy EJB: MerchantFacadeBean from MyFacade.jar:
No persistence unit named 'entityManager' is available in scope MyFacade.jar. Available persistence units: []
at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:469)
at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:199)
at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:517)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:52)
at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:159)
Truncated. see log file for complete stacktrace
Caused By: java.lang.IllegalArgumentException: No persistence unit named 'entityManager' is available in scope MyFacade.jar. Available persistence units: []
at weblogic.deployment.ModulePersistenceUnitRegistry.getPersistenceUnit(ModulePersistenceUnitRegistry.java:132)
at weblogic.deployment.BasePersistenceContextProxyImpl.<init>(BasePersistenceContextProxyImpl.java:39)
at weblogic.deployment.TransactionalEntityManagerProxyImpl.<init>(TransactionalEntityManagerProxyImpl.java:26)
at weblogic.deployment.EntityManagerInvocationHandlerFactory.createTransactionalEntityManagerInvocationHandler(EntityManagerInvocationHandlerFactory.java:18)
at weblogic.deployment.BaseEnvironmentBuilder.createPersistenceContextProxy(BaseEnvironmentBuilder.java:973)
Truncated. see log file for complete stacktrace
>
Chris Logan
Greenhorn

Joined: Jan 31, 2011
Posts: 10
The things that came up to my mind:

First thing first - did you configured persistence.xml file?
It should be in the META-INF catalog with ejb-jar.xml file.

Are you sure that your persistence unit name is "entityManager"? You can check it in persistence.xml file - the tag is <persistence-unit name="yourName">.

I don't have any more ideas I hope it will help you somehow.


Cheers
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: No persistence unit named 'entityManager' is available in scope MyFacade.jar. Available persistence
 
Similar Threads
deployment error ,jpa(wl10.3.3)
No-Interface view not getting deployed in Weblogic12C.
deploy ejb3 on weblogic errors
Newbie question - how to include dependent classes automatically in ejb jar
Unable to deploy my EJB application