aspose file tools
The moose likes EJB and other Java EE Technologies and the fly likes Problem while running the client Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of OCA Java SE 8 Programmer I Study Guide 1Z0-808 this week in the OCAJP forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Problem while running the client" Watch "Problem while running the client" New topic

Problem while running the client

Pratibha Gayake

Joined: May 08, 2001
Posts: 29
I am trying to run my first bean(WelcomeBean). After one day of hard work I came upto successfull deployment. And while running client I get following error:
Any help is really appriciated.
I am using weblogic 4.5.
javax.naming.NameNotFoundException: 'WelcomeHome'; remaining name 'WelcomeHome'
at weblogic.rmi.extensions.BasicRequest.sendReceive(
at weblogic.jndi.WLContext_WLStub.lookup(
at weblogic.jndi.toolkit.WLContextStub.lookup(
at javax.naming.InitialContext.lookup(
at WelcomeClient.main(
Manjunath B.S

Joined: Apr 24, 2001
Posts: 16

Hi Pratiba,
I haven't worked on Weblogic 4.5.
But looking at the messages weblogic has shown, i think that
the the bean hasen't been deployed.Check or redeploy your
Muhammad Asif
Ranch Hand

Joined: Jul 13, 2001
Posts: 202
I haven't used weblogic 4.5 either but the problem seems obvious if u consider weblogic 5.1 (and this may help u!) !
The JNDI name that you have specified for your EJB cannot be found!
Now there can be two problems
1) Either EJB is not deployed correctly
2) Or It is not bound to the JNDI name with which you are trying to look it up! For this purpose check ur descriptor where you are specifying the JNDI Name!

Hope this helps
Muhammad Asif

Pratibha Gayake

Joined: May 08, 2001
Posts: 29
Thnaks Asif,
I deployed the bean using following code.
//This is DeploymentDecriptor.txt
beanHomeName WelcomeHome
enterpriseBeanClassName WelcomeBean
homeInterfaceClassName WelcomeHome
remoteInterfaceClassName Welcome
isReentrant false
; Session EJBean-specific properties:
stateManagementType STATELESS_SESSION
sessionTimeout 10; seconds
; end session EJBean-specific properties
; DEFAULT [admin managers]
); end accessControlEntries
transactionAttribute TX_REQUIRED
; runAsIdentity WelcomeBeanAdmin
); end DEFAULT
); end controlDescriptors
; Application-specific environment properties
; end Application-specific environment properties
; realmName "my.realm"
; homeClassName
; ejbObjectClassName
maxBeansInFreePool 100
maxBeansInCache 100
idleTimeoutSeconds 60
); end environmentProperties
); end SessionDescriptor

Here in this code I do not have to use JNDI name. Where are you pointing please explain.
When I deployed the bean using following command:
java weblogic.ejb.utils.DDCreator -d classes deployment/DeploymentDescriptor.txt
I have not got any error.
I am again going through the documentation.
Any input will be helpful
anup vachali
Ranch Hand

Joined: Oct 17, 2000
Posts: 54
I havent worked with 4.5 but I think u have to put the location of ur jar file in the file. The JNDI name would be the name of ur bean ur case WelcomeHome
When u start ur weblogic server u should see a message saying that EJB was successfully deployed.
Marcos Maia
Ranch Hand

Joined: Jan 06, 2001
Posts: 977
Simillar error Sorry long post but I�m trying to solve this problem for more than a week now).pls help.
Im running the examples of Enterprise Java Beans from Monson-Haefel book in WebLogic 6.0 and I?m havin the error:
java.rmi.RemoteException: EJB Exception: ; nested exception is:
java.lang.NoClassDefFoundError: com.titan.cabin.CabinHome
java.lang.NoClassDefFoundError: com.titan.cabin.CabinHome
I was debuggin it and I discovered tha the error occurs right after I get a remote reference to the bean with
Object ref = ctx.lookup("java:comp/env/ejb/Cabin");
I got the reference but then when I try to do:
CabinHome home = (CabinHome)(javax.rmi.PortableRemoteObject.narrow(ref, CabinHome.class));
the error occurs.

Here goes a fragment of code showing the reference I recovered:
Object ref = ctx.lookup("java:comp/env/ejb/Cabin");
// this next line prints: com.titan.cabin.CabinEJBHomeImpl_WLStub
here goes a fragment of my ejb-jar.xml:
<description>stateless ejb que manuseia Cabin ejb</description>

and a fragment of weblogic-ejb-jar.xml:

Any help will be wellcome.
txs in advance.
PS - If I set the classpath to
it works but I�m sure thats not the wright thing to do.
I agree. Here's the link:
subject: Problem while running the client