PDA

View Full Version : Issue when deploy spring web service in Jboss 4.2.1



jyzhou817
Oct 28th, 2007, 11:13 PM
Hi,

I am using spring web service client, which is running in jboss4.2.1, to access web service exposed in another machine.

I use the echo example shipped with spring web service package.

The error is as following,
....
java.lang.UnsupportedOperationException: setProperty must be overridden by all subclasses of SOAPMessage
at javax.xml.soap.SOAPMessage.setProperty(SOAPMessage .java:424)
at org.jboss.ws.core.soap.SOAPMessageImpl.<init>(SOAPMessageImpl.java:67)
at org.jboss.ws.core.soap.MessageFactoryImpl.createMe ssage(MessageFactoryImpl.java:155)
at org.springframework.ws.soap.saaj.SaajSoapMessageFa ctory.createWebServiceMessage(SaajSoapM
essageFactory.java:141)
at org.springframework.ws.client.core.WebServiceTempl ate.sendAndReceive(WebServiceTemplate.j
ava:393)
at org.springframework.ws.client.core.WebServiceTempl ate.doSendAndReceive(WebServiceTemplate
.java:350)
at org.springframework.ws.client.core.WebServiceTempl ate.sendSourceAndReceiveToResult(WebSer
viceTemplate.java:296)
at org.springframework.ws.client.core.WebServiceTempl ate.sendSourceAndReceiveToResult(WebSer
viceTemplate.java:287)
at org.springframework.ws.client.core.WebServiceTempl ate.sendSourceAndReceiveToResult(WebSer
viceTemplate.java:277)

I think maybe the jars lib i used in application conflict with Jboss web service implementation.

Please help.

Best regards
JY

Arjen Poutsma
Oct 29th, 2007, 05:18 PM
See http://static.springframework.org/spring-ws/site/faq.html#saaj-jboss

jyzhou817
Oct 29th, 2007, 08:47 PM
Hi,
I am totally use the sample "echo" shipped with spring WS. I deploy the client in the jboss server. without any configuration except "echoClient" bean.
So it is not the case mentioned in FAQ.
Because I have some problem in using "mvn package".
So any one can tell me the jars needed to deploy in client side?

Thanks

jyzhou817
Oct 29th, 2007, 08:48 PM
Hi,
I am totally use the sample "echo" shipped with spring WS. I deploy the client in the jboss server. without any configuration except "echoClient" bean.
So it is not the case mentioned in FAQ.
Because I have some problem in using "mvn package".
So any one can tell me the jars needed to deploy in client side?

Thanks

Arjen Poutsma
Oct 30th, 2007, 01:10 PM
Well, it looks like it's a JBoss SAAJ implementation problem. That's why I pointed you the FAQ on how to define a messageFactory which uses the reference implementation SAAJ (from SUN). You can then inject that messageFactory in the WebServiceTemplate in the echo client, using constructor or property.

jyzhou817
Oct 30th, 2007, 09:41 PM
Hi Arjen,

Many thanks. Now it is working in Jboss.

One strange thing is: I have to remove the "restriction" in echoRequest element of XML schema.
It does not happen when deploy to glassfish.
Maybe it is related to the "messageFactory" i choose?

Regards
JY