jQuery in Action, 3rd edition
The moose likes BEA/Weblogic and the fly likes unable to deploy EJB component Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Products » BEA/Weblogic
Bookmark "unable to deploy EJB component" Watch "unable to deploy EJB component" New topic

unable to deploy EJB component

Garlapati Ravi
Ranch Hand

Joined: Mar 05, 2008
Posts: 171
i was developing a simple EJB application as below :

as per the book knowledge i came to know that EJB3.0 automatically registers with JNDI at deployment time itself, especially to make this point more clear i was trying the above simple example.
i just kep these files in .jar and deployed the ear file, FYI i dont have ejb-jar.xml in my application,

my servlet looks as below, which calls an EJB :

EXCEPTION : com.ravi.bidding.ejb.PlaceBid NOT FOUND.

to avoid above problem i have used <ejb>PlaceBidEJB.jar</ejb> in application.xml file and deployed again.

EXCEPTION : No ejb-jar.xml file

i created ejb-jar.xml file as below

weblogic-ejb-jar.xml as below

still i am ending up with some exception at deployment time :

Unable to deploy EJB: C:\WeblogicDomainScripting_Developer\DomainScripting\desktop-PruDirectPresentationDomain\.\servers\AdminServer\tmp\_WL_user\PlaceBid\a9y5ul\PlaceBidEJB.jar from PlaceBidEJB.jar:

In EJB PlaceBidBean, both the local home and local component interface must be specified. Currently, only one of them is specified.

at weblogic.ejb.container.deployer.EJBDeployer.prepare(EJBDeployer.java:1189)
at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:354)
at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:90)
at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:318)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:53)
at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:43)
at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:620)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:231)
at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:147)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:61)
at weblogic.deploy.internal.targetserver.AppDeployment.prepare(AppDeployment.java:126)
at weblogic.management.deploy.internal.DeploymentAdapter$1.prepare(DeploymentAdapter.java:37)
at weblogic.management.deploy.internal.AppTransition$1.transitionApp(AppTransition.java:21)
at weblogic.management.deploy.internal.ConfiguredDeployments.transitionApps(ConfiguredDeployments.java:232)
at weblogic.management.deploy.internal.ConfiguredDeployments.prepare(ConfiguredDeployments.java:164)
at weblogic.management.deploy.internal.ConfiguredDeployments.deploy(ConfiguredDeployments.java:121)
at weblogic.management.deploy.internal.DeploymentServerService.resume(DeploymentServerService.java:173)
at weblogic.management.deploy.internal.DeploymentServerService.start(DeploymentServerService.java:89)
at weblogic.t3.srvr.SubsystemRequest.run(SubsystemRequest.java:64)
at weblogic.work.ServerWorkManagerImpl$WorkAdapterImpl.run(ServerWorkManagerImpl.java:518)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:207)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:179)
Caused by: In EJB PlaceBidBean, both the local home and local component interface must be specified. Currently, only one of them is specified.
at weblogic.ejb.container.deployer.ClientDrivenBeanInfoImpl.checkClientViews(ClientDrivenBeanInfoImpl.java:267)
at weblogic.ejb.container.deployer.ClientDrivenBeanInfoImpl.<init>(ClientDrivenBeanInfoImpl.java:149)
at weblogic.ejb.container.deployer.SessionBeanInfoImpl.<init>(SessionBeanInfoImpl.java:100)
at weblogic.ejb.container.deployer.BeanInfoImpl.createBeanInfoImpl(BeanInfoImpl.java:553)
at weblogic.ejb.container.deployer.MBeanDeploymentInfoImpl.initializeBeanInfos(MBeanDeploymentInfoImpl.java:598)
at weblogic.ejb.container.deployer.MBeanDeploymentInfoImpl.<init>(MBeanDeploymentInfoImpl.java:221)
at weblogic.ejb.container.deployer.EJBDeployer.prepare(EJBDeployer.java:1178)
... 23 more

Now i have no idea what this error is ?

please clarify.

Ravi Kumar
SCWCD 5 - 89%, SCJP 1.4 - 90%
Jaikiran Pai

Joined: Jul 20, 2005
Posts: 10441

EXCEPTION : No ejb-jar.xml file

Are you sure, the version of WebLogic you are using supports EJB3?

[My Blog] [JavaRanch Journal]
Christophe Verré

Joined: Nov 24, 2005
Posts: 14688

In EJB PlaceBidBean, both the local home and local component interface must be specified. Currently, only one of them is specified.

Good guess by Jaikiran. Looks like it is looking for some EJB2.x.

[My Blog]
All roads lead to JavaRanch
Garlapati Ravi
Ranch Hand

Joined: Mar 05, 2008
Posts: 171
I am using Weblogic9.0 application server.

if you want you can even see the packages which i imported are 'ejb30'.

below is my application.xml file

if i remove <ejb>PlaceBidEJB.jar</ejb> part, it deploys properly, but i belive it's deploying only web part. Because when i was trying to access the application it throwing below exception

java.lang.NoClassDefFoundError: com/ravi/bidding/ejb/PlaceBid at com.ravi.bidding.PlaceBidServlet.service(PlaceBidServlet.java:14)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:225)
at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:127)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:272)
at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:165)
at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3153)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:1973)
at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:1880)
at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1310)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:207)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:179)

any clues ?
Christophe Verré

Joined: Nov 24, 2005
Posts: 14688

In your application.xml, shouldn't you be using the new schema instead ?
Christophe Verré

Joined: Nov 24, 2005
Posts: 14688

I'm not into weblogic, but isn't EJB3 supported since Weblogic9.2 ?
Garlapati Ravi
Ranch Hand

Joined: Mar 05, 2008
Posts: 171
you mean to say EJB3 will not be supported in weblogic9.2 below versions ? will it supports only from and above weblogic 9.2 servers ?

in that case my server weblogic9.1 will not support EJB3.0, am i right ?

Please clarify

i was trying to use the new schema you specified, it throws different exception at deployment time, it was very huge, i truncated to below:

<13-Aug-2008 10:15:06 o'clock BST> <Error> <Deployer> <BEA-149605> <Failed to create App/Comp mbeans for AppDeploymentMBean PlaceBid. Error - weblogic.management.DeploymentException: Unmarshaller failed.
weblogic.management.DeploymentException: Unmarshaller failed
at weblogic.application.internal.EarDeploymentFactory.findOrCreateComponentMBeans(EarDeploymentFactory.java:189)
at weblogic.application.internal.MBeanFactoryImpl.findOrCreateComponentMBeans(MBeanFactoryImpl.java:48)
at weblogic.application.internal.MBeanFactoryImpl.createComponentMBeans(MBeanFactoryImpl.java:109)
at weblogic.application.internal.MBeanFactoryImpl.initializeMBeans(MBeanFactoryImpl.java:76)
at weblogic.management.deploy.internal.MBeanConverter.createApplicationMBean(MBeanConverter.java:97)
at weblogic.management.deploy.internal.MBeanConverter.createApplicationForAppDeployment(MBeanConverter.java:75)
at weblogic.management.deploy.internal.MBeanConverter.setupNew81MBean(MBeanConverter.java:322)
Christophe Verré

Joined: Nov 24, 2005
Posts: 14688

I'm moving this thread to the Weblogic forum where you'll get help from experts
Shikhar Madhok
Ranch Hand

Joined: Dec 18, 2006
Posts: 95
Infact even 9.2 does not have a mention of EJB3. I think EJB3 is supported only WLS 10 onwards.


He who asks a question is a fool for five minutes; he who does not ask a question remains a fool forever - Chinese proverb
Garlapati Ravi
Ranch Hand

Joined: Mar 05, 2008
Posts: 171
Hi Shikhar,

Thanks for your reply, that clarifies my doubt.

could you please suggest any server with it's version which supports EJB3.0
if you can give me Jboss version, that would be great help
Cotton Gear

Joined: Jun 02, 2008
Posts: 8
Even I am having the same issue on WebLogic 10. Does any one have info on how to solve this ?

Each one of us, teach(at least) one. <br />-Mahatma Gandhi
Amit Ghorpade

Joined: Jun 06, 2007
Posts: 2851

"Cotton Gear" please check your private messages for an important administrative matter. You can see them by clicking the My Private Messages link above.

This is really important.

|Asking Good Questions|
I agree. Here's the link: http://aspose.com/file-tools
subject: unable to deploy EJB component
It's not a secret anymore!