2 Replies Latest reply: Oct 27, 2009 4:36 AM by 730276 RSS

    JAXRPC ws-client generation failure with WL10.3

    730276
      Hi all.
      My deep apologies for crossposting; this question was posted first to "WebLogic Server - Upgrade" forum and just later I found this webservices related topic.
      I'm copying it as it for for the sake of convenience.
      ----------------------

      I'm facing a problem to generate web-service client with WL-10.3, while WL-9.2 works pretty fine with this WSDL.
      My ANT task is:
      <clientgen
      type="JAXRPC"
      wsdl="${WSDL}"
      destDir="${DESTDIR}"/>

      In case type is set to JAXWS, generation succeeds. However, if I set it to JAXRPC (I need to enable multirefs to support closed graphs), the generation fails with exception:

      weblogic.wsee.tools.WsBuildException: weblogic.descriptor.DescriptorException: Failed to marshal: weblogic.j2ee.descriptor.JavaWsdlMappingBeanImpl
      at weblogic.wsee.tools.anttasks.ClientGenFacadeTask.execute(ClientGenFacadeTask.java:235)
      at weblogic.wsee.tools.anttasks.ClientGenTask.execute(ClientGenTask.java:358)
      ******
      Caused by: java.io.IOException
      at weblogic.descriptor.internal.MarshallerFactory.<init>(MarshallerFactory.java:50)
      at weblogic.descriptor.BasicDescriptorManager.getMarshallerFactory(BasicDescriptorManager.java:137)
      ******
      Caused by: com.bea.xml.XmlException: unable to load type library from classloader org.apache.tools.ant.AntClassLoader@104c575
      at com.bea.staxb.runtime.internal.BindingContextFactoryImpl.createBindingContext(BindingContextFactoryImpl.java:50)
      at weblogic.descriptor.internal.MarshallerFactory.<init>(MarshallerFactory.java:48)

      Are there any known limitations/issues regarding JAXRPC support for WL-10.3?
      Is there any workaround for this problem?
      Greatly appreciating any inputs
      Sincerely
      Jabb
        • 1. Re: JAXRPC ws-client generation failure with WL10.3
          730276
          Updates.
          Meanwhile I found that the mentioned failure is caused due to inner calls to ClassLoader.getResources() searches for "META-INF/binding-file.ser" and "META-INF/binding-mapping-file.ser" calls which returns empty results. However these files were succesfully created in directory pointed by destDir attribute. I added the destDir dir to taks's classpath:
          <clientgen
          type="JAXRPC"
          wsdl="${WSDL}"
          destDir="${DESTDIR}">
          <classpath>
               <pathelement location="${DESTDIR}"/>
          </classpath>
          </clientgen>
          and this faulire was gone, but new appeared:
          weblogic.wsee.tools.WsBuildException: weblogic.descriptor.DescriptorException: Failed to marshal: weblogic.j2ee.descriptor.JavaWsdlMappingBeanImpl
               at weblogic.wsee.tools.anttasks.ClientGenFacadeTask.execute(ClientGenFacadeTask.java:235)
               ****
          Caused by: com.bea.xml.XmlException: failed to find root element corresponding to weblogic.j2ee.descriptor.JavaWsdlMappingBeanImpl
               at com.bea.staxb.runtime.internal.MarshallerImpl.lookupRootElementName(MarshallerImpl.java:70)
               at com.bea.staxb.runtime.internal.MarshallerImpl.marshal(MarshallerImpl.java:139)
               at com.bea.staxb.runtime.internal.MarshallerImpl.marshal(MarshallerImpl.java:191)
               at weblogic.descriptor.BasicDescriptorManager.writeDescriptorBeanAsXML(BasicDescriptorManager.java:503)
          • 2. Re: JAXRPC ws-client generation failure with WL10.3
            730276
            The problem was found.
            I have to say, very strange.. If executed with ant-1.6.5 provided in modules/org.apache.ant_1.6.5, it succeedes.
            However when executed with ant-1.6.2 it fails as described formely.
            Imho, if <clientgen> task is ANT version aware, it should recognize it and send some notifications...