[jboss-user] [JBossWS] - Completely stuck with RPC client- please help!

DeanoUK do-not-reply at jboss.com
Thu Oct 4 07:16:50 EDT 2007


Ok I've already posted something similar, but am now able to detail my steps quite clearly.

I have JBoss 4.2.1GA running JBossWS 2.0.1 on JDK 6.

The JARs below are then included in jboss-4.2.1.GA\lib\endorsed:
jaxb-api.jar
jboss-jaxrpc.jar
jboss-jaxws.jar
jboss-saaj.jar


Here's my code: 

  | ServiceFactory factory = ServiceFactory.newInstance();
  | Service remote = factory.createService(url, qname);
  | 
  | NewRegistrationsSession proxy = (NewRegistrationsSession) remote.getPort(NewRegistrationsSession.class);
  | 
  | System.out.println("Receiving: " + proxy.uploadNewRegistrations("hello"));
  | 

At the last line I get:

  | Exception in thread "main" java.lang.ClassCastException: com.sun.xml.internal.messaging.saaj.soap.ver1_1.Message1_1Impl cannot be cast to com.sun.xml.messaging.saaj.soap.MessageImpl
  | 

I'm running the example through and IDE (IntelliJ) which has the JWSDP-2.0 JARs in it's class path: 
jaxrpc-impl.jar
FastInfoset.jar
AND Saaj1.3:
saaj-impl.jar

The reason I include JWSDP files is because the execution states:

  | Exception in thread "main" javax.xml.rpc.ServiceException: Provider com.sun.xml.rpc.client.ServiceFactoryImpl not found
  | 

Thus I need to include it. But I presume this isn't the corrct ServiceFactoryImpl and this causes the final problem...
Is there a JBoss WS implementation, or am I barking up the wrong tree?

Thanks in advance.

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

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



More information about the jboss-user mailing list