The moose likes BEA/Weblogic and the fly likes How to use a servlet client to test EJB? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Products » BEA/Weblogic
Reply Bookmark "How to use a servlet client to test EJB?" Watch "How to use a servlet client to test EJB?" New topic
Author

How to use a servlet client to test EJB?

Oleg Shklyar
Greenhorn

Joined: May 28, 2001
Posts: 26
Hello ranchers,
I've developed the CMP bean and test it sucessfully with java client using WebLogic 6.0. Can anyone give me the basic idea how to use servlet as a client to test my EJB?
Thanks,
Oleg
Rahul Mahindrakar
Ranch Hand

Joined: Jul 28, 2000
Posts: 1825
Try out this servlet . But keep in mind and make the nessary changes
Marcos Maia
Ranch Hand

Joined: Jan 06, 2001
Posts: 973
You may also reference the ejb from your web.xml deployment descriptor:
<ejb-ref> (optional)
<description>description text</description> (optional)
<ejb-ref-name> name </ejb-ref-name> (required)
<ejb-ref-type> ejb java type </ejb-ref-type> (required)
<home>The home interface of the ejb</home> (required)
<remote>The remote interface of the ejb</remote> (required)
<ejb-link> ejb.name </ejb-link> (optional)
</ejb-ref>
Oleg Shklyar
Greenhorn

Joined: May 28, 2001
Posts: 26
Thank you guys for your assistance. It works!
(Administration tasks took a lot of time, but WLS is better than WebSphere. This is my opinion)
Oleg
Rahul Mahindrakar
Ranch Hand

Joined: Jul 28, 2000
Posts: 1825

but WLS is better than WebSphere. This is my opinion

Hmm.. Please dont tell this. Weblogic and WebSphere are both great products and one cannot be pitted against the other. If you are comparing Weblogic and Websphere 3.5 you may be slightly right, but with the arrival of Websphere 4.0 nothing definate can be said.
Let the market decide is the only solution.
------------------

Mahindrakar
IBM Application Server & Developer Forum Moderator

Consultant - Zensar Technologies ,Pune India.
SCJP2, SCJD2 & SCJEA (Part I)
 
 
subject: How to use a servlet client to test EJB?
 
Threads others viewed
EJB and WSAD
Toc
Tomcat 6 configuration with JBoss 5 using JNDI call
What can be an EJB client
How to configure Tomcat 6 to use EJB 3 component deployed on JBoss server
WebSphere development made easy
without the weight of IBM tools
http://www.myeclipseide.com