Meaningless Drivel is fun!
The moose likes Websphere and the fly likes Calling an EJB using a client in WSAD Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Websphere
Bookmark "Calling an EJB using a client in WSAD" Watch "Calling an EJB using a client in WSAD" New topic

Calling an EJB using a client in WSAD

Ranch Hand

Joined: Jun 03, 2001
Posts: 47
Hi all,
I have a stateless EJB (TestEJB) which returns a "Hello World" created in WSAD 5.0. I need to write a test client application which can be a basic java class or a JSP to call that EJB and execute that "Hello World" method. Since I am new to WSAD, could anyone please let me know:
1) The test code for client application
2) How to import or add that generated EJB to client application path in WSAD.
I have tried test client from WSAD where I can see Bean Page, JNDI explorer..... but when I clicked on Invoke button I cannot see anything.
Thanks in advance,
Mahesh Chalil
Ranch Hand

Joined: Jan 24, 2002
Posts: 147
HI Chandra
I am not discouraging you but if you could at least look at Help Contents from WSAD, you will see step by step instruction about how to do all these things. Please let us know if you face any problem after that.
I studied myself a long back only following their help materials and there is nothing else to beat that. There is everything what you need. I faced the same situation you had before when I was testing my ejb but you will see that solution is just about following the right path of how to do it. Thats why you have WSAD Help "Tasks" to do it. You ask the question "How do I". They have answers for you.
Good luck.
Howard Kushner
Ranch Hand

Joined: Sep 19, 2003
Posts: 361
It is much easier to use the Universal Test Client (UTC) that comes with WebSphere Studio Application Developer. Check the documentation. There is no need to write a client for unit testing. After generating deploy code, right click the bean and select run on server from the pop-up menu.
Hope this helps.

Howard Kushner<br />IBM Certified Enterprise Developer - WebSphere Studio Application Developer V5.0<br />IBM Certified Advanced System Administrator - WebSphere Application Server V5.0<br />IBM Certified Solution Developer - Web Services with WebSphere Studio V5.1<br /><a href="" target="_blank" rel="nofollow">Developing J2EE Applications with WebSphere Studio</a> my Certification Study Guide for IBM Test 287
I agree. Here's the link:
subject: Calling an EJB using a client in WSAD
It's not a secret anymore!