[jboss-user] [JBossWS] - Use of JAX-RPC in JBoss 4.2.3

glen_s do-not-reply at jboss.com
Sat Feb 28 00:01:44 EST 2009


I have a web app running on JBoss AS 4.2.3, default server configuration. I need to write a web service client that can talk to a soap encoded web service. I know that JBossWS does not support soap encoding, so I am struggling to find a workaround.

>From my research I'm lead to believe that JAX-RPC is the one library that does support soap encoding, so have tried using a (JWSDP) wscompile produced client in JBoss 4.2.3.

When I include the JWSDP compatible JARs[1] in the lib directory of my EAR, and my client code calls into the wscompile produced stub, the stub calls into (JWSDP) StreamingSender class and ultimately throws a ClassCastException:

  |    1. java.lang.ClassCastException: org.jboss.ws.core.soap.SOAPMessageImpl  
  |    2.     at com.sun.xml.rpc.client.StubBase._postSendingHook(StubBase.java:231)  
  |    3.     at com.sun.xml.rpc.client.StreamingSender._send(StreamingSender.java:324)  
  | 

How can I make JAX-RPC work on JBoss 4.2.3? Is it possible to manipulate the set of JARs from JWSDP that I am including[1] in my web app to make JAX-RPC (supporting soap encoding) work on JBoss 4.2.3?

If no-one can offer the silver-bullet answer as to how to make JAX-RPC work on JBoss 4.2.3, maybe one of the following ideas will ring true with someone who can at least point me in the right direction to pursue.

Might I:
* *Somehow* configure JBossWS to "play nice" with JAX-RPC so that JAX-RPC can be used as my web service library
  | * Change the class loader configuration to allow the JAX-RPC (and associated JWSDP) JAR files to work in my web app
  | * Remove the JBossWS module from the default configuration, and somehow just use JAX-RPC JARs from my web app rather than being loaded as a JBoss service (although I have concerns that the JAX-RPC dependant JARs from JWSDP would still conflict with other XML related JARs in JBoss AS)
  | * Switch to some other web service client library that supports soap encoding (that I'm not aware of) that can be configured to run on JBoss AS 4.2.3
  | 
  | I am relatively new to JBoss, so if one of the above ideas strikes you as ludicrous (just doesn't make sense), I apologize.
  | 
  | Thank you,
  | Glen Scott
  | 
  | [1]The jars from JWSDP 1.6 I included in my EAR's lib are: activation.jar, commons-beanutils.jar, commons-collections.jar, commons-digester.jar, commons-logging.jar, dom.jar, jaas.jar, jax-qname.jar, jaxp-api.jar, jaxrpc-api.jar, jaxrpc-impl.jar, jaxrpc-spi.jar, mail.jar, namespace.jar, relaxngDatatype.jar, saaj-api.jar, saaj-impl.jar, sax.jar, xercesImpl.jar, xsdlib.jar
  | 

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4213909#4213909

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4213909



More information about the jboss-user mailing list