Announcement Announcement Module
No announcement yet.
JaxRpcPortProxyFactoryBean and objects from WSDL Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • JaxRpcPortProxyFactoryBean and objects from WSDL

    Hi Springers.

    Have the following question.
    The wsdl document from the webservice defines some object which has to be passed to the webservice invoke method. Like this:
    <wsdl:definitions targetNamespace="">
    WSDL created by Apache Axis version: 1.4
    Built on Apr 22, 2006 (06:55:48 PDT)
        <schema targetNamespace="">
        <import namespace=""/>
        <import namespace=""/>
    	<complexType name="MyRequest">
                    <element name="auxData" nillable="true" type="soapenc:string"/>
    		<element name="clientKey" nillable="true" type="soapenc:string"/>
    		<element name="datXKey" nillable="true" type="soapenc:string"/>
    		<element name="encoding" nillable="true" type="soapenc:string"/>
    		<element name="password" nillable="true" type="soapenc:string"/>
    		<element name="schemaName" nillable="true" type="soapenc:string"/>
    		<element name="timeout" nillable="true" type="soapenc:int"/>
    		<element name="username" nillable="true" type="soapenc:string"/>
    So. when I used AXIS the class com.framework.packaging.MyRequest had been generated, compiled and jared. And I was able to use this class in the application, to populate all necessary fields and then pass it as an argument to the webservice method.
    Using JaxRpcPorProxyFactoryBeans this class will be generated at runtime. So here is the question. How can I use this runtime generated class to populate all its properties.
    I tried to create a bean in the application context xml file
    <bean id="myRequest" class="com.framework.packaging.MyRequest"/>
    but when I start the application server the ClassNotFoundException is thrown.

    Thanks in advance.

  • #2

    you complex data types which will be send through the webservice are not generated at the runtime. You have to generate them and package them with your client. If you use jaxrpcproxyfactorybean, then you don't have to create the axis (or in particular the jax-rpc) specific classes. (Like the ServiceImplementation and the underlying Port implementations).

    best rgds


    • #3
      So, you want to say, that JaxRpcPortProxyFactoryBean will generate only stubs, interfaces and so on, but not the complex types from the wsdl definitions?


      • #4

        yes, have a look at the petstore sample application, there you can see the use of JaxRpcProxFactoryBean.

        best rgds


        • #5
          Huh. I'd like to remove a jar file from the application class path to make it liter. Ok. At least I can remove from this jar file all generated artifacts which are related to axis.
          Thanks for your reply.