Rob Goodwin
Rob Goodwin

Reputation: 2777

Web Service Class Cast Exception

I am currently using JBoss 5.1.0 and have an ejb deployed that makes use of an WebService on a remote system. I recently received a new VM that had an updated JBoss configuration and now after deploying and when trying to call a method on the webservice, I get the following error.

java.lang.ClassCastException: org.jboss.ws.core.soap.SOAPElementImpl cannot be cast to javax.xml.soap.SOAPHeader

I have generated the java web service bindings from the WSDL and it has been working. There must be some classpath issue going on here but I am not sure where to begin to look.

-Rob

Looks like the picketlink libraries were added to the JBoss instance for webservice security some some webservices that are deployed on that local instance. The remote web service I am calling does not make use of this.

Upvotes: 2

Views: 1380

Answers (1)

Sean Patrick Floyd
Sean Patrick Floyd

Reputation: 298858

This issue in jbossws-native-3.2.0 was fixed in jbossws-native-3.2.2. Please try upgrading.

Here is the relevant issue from the JBoss Web Services issue tracker:

JBWS-2746: ClassCastException because SOAPEnvelopeImpl blindly casts to SOAPElementImpl

Upvotes: 5

Related Questions