Keith,
              I did exactly as suggested by you.The problem now is i have
to fill the implementation class with calls to ejbs. Do i have to make
lookups in the implementation class and call the ejbs.?.
My implementation class

package sample;

public class SampleSoapBindingImpl implements sample.Sample{
    public java.lang.String getThis() throws java.rmi.RemoteException {
         //make look ups to ejbs. and call the methods.
    }

}


----------------------------------------------------------------------------------------

This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery. NOTE: Regardless of content, this e-mail shall not operate to
bind CSC to any order or other contract unless pursuant to explicit written
agreement or government initiative expressly permitting the use of e-mail
for such purpose.
----------------------------------------------------------------------------------------




                                                                                       
                                               
                      "Keith Hatton"                                                   
                                               
                      <khatton                 To:      <[EMAIL PROTECTED]>            
                                         
                      @axiomsystems.co         cc:                                     
                                               
                      m>                       Subject: RE: A very unique situation.   
                                               
                                                                                       
                                               
                      11/21/2003 06:44                                                 
                                               
                      AM                                                               
                                               
                      Please respond                                                   
                                               
                      to axis-user                                                     
                                               
                                                                                       
                                               
                                                                                       
                                               




Hi Pradeep,

You can create WSDL from an EJB - just pass the remote interface to
Java2WSDL. This may not give you everything that you need - it depends on
exactly what types the remote interface contains and you may need to modify
it by hand - but then you should be able to run WSDL2Java on it and get the
stub classes.

Hope this helps

Keith


-----Original Message-----
From: Pradeep Jonnalagadda [mailto:[EMAIL PROTECTED]
Sent: 20 November 2003 22:21
To: [EMAIL PROTECTED]
Subject: A very unique situation.


Hi Guys,
               I'm trying to implement axis web services .My architecture
demands that my webservices talk to stateless session ejbs. Also I'm using
doc/literal scheme of arhitecture. Initially when i did a prototype my
webservices where simple java beans .I generated wsdl out of it and from
wsdl generated client and servercode.Since we wanted validation to take
place i declared few typeMapping elements with CastorSerializerFactory and
CastorDeSerializerFactory in deploy.wsdd and deployed the application. On
the client side i tweaked XYZBindingStub.java to add these classes. So my
functionality of validation was thus accomplished.
                  Later when we decided that we should make calls to
ejbs(using soap) i adopted a different approach. Since I cannot generate a
wsdl out of an ejb(correct me if im wrong) and hence the client and stub
code from wsdl I decided to use ejb provider in deploy.wsdd file and
deployed it.
My deploy.wsdd looks like this:
<service name="DepositService" provider="java:EJB">
   <parameter name="allowedMethods" value="getBalance"/>
   <parameter name="jndiURL" value="iiop://localhost:2809"/>
   <parameter name="jndiContextClass" value
="com.ibm.websphere.naming.WsnInitialContextFactory"/>
   <parameter name="remoteInterfaceName" value="com.Bank"/>
   <parameter name="beanJndiName" value="ejb/com/BankHome"/>
   <parameter name="homeInterfaceName" value="com.BankHome"/>
</service>

On the client side to invoke this ejb the code is:
            String endpoint =
"http://localhost:9080/IllustrateRouterWeb/services/DepositService";;
            Service service = new Service();
            Call call = (Call)service.createCall();
            call.setTargetEndpointAddress(endpoint);
            call.setOperationName(new QName("getBalance"));
            Object a[]=null;
            String ret = (String)call.invoke(a);
            System.out.println(ret);

All this works great .Now my problem is i need to send and receive complex
data types using castor.So i'm thinking to reintroduce the Typemapping
element with castor mapping in deploy.wsdd and deploy which should take
care of server side serialization/deserialization. Here are my questions
1. But i wonder how to tweak the client file to register the castor type
mappings.
2.I guess my root question is when ejbs are involved on server side is the
approach i have used of using dyanamic client invocation correct.Are there
any better ways of doing this.
3.I have a third option in my mind.The option is to declare an interface
which has all the method declrations .The session ejb would implement this
interface .I would generate a wsdl out of this interface and from the wsdl
would generate the client and stub code (WSDL2Java).Then i could send and
receive complex data types easily at the client side(as i used to do it
before) but the only disadvantage being i need to make looks ups on ejbs
and call the methods in the implementation classes of soap.This is ok but i
dont know if this is the right way of doing .

These are my concerns.All the active group ps take time to answer this mail
since this is one of crucal problems pending
thx
pradeep.







----------------------------------------------------------------------------------------


This is a PRIVATE message. If you are not the intended recipient, please
delete without copying and kindly advise us by e-mail of the mistake in
delivery. NOTE: Regardless of content, this e-mail shall not operate to
bind CSC to any order or other contract unless pursuant to explicit written
agreement or government initiative expressly permitting the use of e-mail
for such purpose.
----------------------------------------------------------------------------------------










Reply via email to