[jboss-user] [JBoss Web Services] - Re: JBoss 5.1.0, Apache CXF, Spring, and WSS4J issue

Alessio Soldano do-not-reply at jboss.com
Tue Apr 5 04:17:32 EDT 2011

Alessio Soldano [http://community.jboss.org/people/asoldano] created the discussion

"Re: JBoss 5.1.0, Apache CXF, Spring, and WSS4J issue"

To view the discussion, visit: http://community.jboss.org/message/597751#597751

Hi John,
ok, so you're not using jbossws-cxf and this is a generic issue with using Apache CXF directly on top of JBoss Application Server. I might provide some hints / suggestion to help, but generally speaking one of aims of the JBossWS-CXF project is exactly solving this kind of integration problems.

> john h wrote:
> Thanks Alessio for the response. Forgive me I'm relatively new to this.
> I haven't done anything with the JBoss 5.1.0 GA server that is downloaded other than adding the ojdbc.jar to access an Oracle datasource.
> Deploying works fine and other than the addition of the wss4j security the web service works fine. Here's the beginning of the stack trace happening when I call any web service interface method:
> 2011-04-01 11:09:00,126 ERROR [STDERR] (http- java.lang.ClassNotFoundException: org.apache.ws.security.transform.STRTransform 
> from  mailto:BaseClassLoader at 110769b%7BVFSClassLoaderPolicy at 1daf835%7Bname=vfsfile:/C:/Documents%20and%20Settings/webedj/Desktop/GA/jboss-5.1.0.GA/server/default BaseClassLoader at 110769b{VFSClassLoaderPolicy at 1daf835{name=vfsfile:/C:/Documents%20and%20Settings/jj/Desktop/GA/jboss-5.1.0.GA/server/default
> /deployers/jbossws.deployer/  http://community.jboss.org/mailto:domain=ClassLoaderDomain@19c7c21{name=DefaultDomain domain=ClassLoaderDomain at 19c7c21{name=DefaultDomain parentPolicy=BEFORE  mailto:parent=org.jboss.bootstrap.NoAnnotationURLClassLoader at 1de3f2d parent=org.jboss.bootstrap.NoAnnotationURLClassLoader at 1de3f2d}
> roots=[MemoryContextHandler at 14513156[path= context=vfsmemory://ap403g-tsevsv-glz909pu-1-glz910q2-e real=vfsmemory://ap403g-tsevsv-glz909pu-1-glz910q2-e], 
What's the full stacktrace?
And where did you add the wss4j lib? It seems there's some kind of clash, given the classloader for the jbossws.deployer is trying to access that apache class. Or the classloading setup you mention below is preventing jbossws from accessing wss4j classes (and why does it need them?).

> As far as I know I haven't done anything with jbossws-cxf as all the CXF stuff I'm working with is directly Apache. I assume the jbossws-cxf stack is JBoss specific? If so I would prefer to stay away from a vendor specific implemetation of anything as I don't want to tie it to JBoss in the future.

Besides jokes (how is that JBossWS is vendor specific and Apache CXF and Spring later are not? ;-) ), JBossWS-CXF provides a integration layer for CXF on top of JBoss AS. So you can use plain jaxws api and stay really on a 100% portable application, or you can use the apache cxf api (annotations, interceptors, ...) with it. Take a look at the documentation for more info.

> When I deploy the war, I also make sure the war file uses the library files I include in the war file and not the ones in JBoss via the addition of a jboss-web.xml file telling it to do so:
> <jboss-web> 
> <class-loading java2ClassLoadingCompliance="true"> 
> <loader-repository> 
> com.comp.wu:loader=MyService.war 
> </loader-repository> 
> </class-loading> 
> </jboss-web>

OK, in any case it's not clear if you're deploying a ws endpoint or you have a servlet app acting as a ws client.
The full stacktrace above might reveal more on when the exception is thrown and what throws it.

Reply to this message by going to Community

Start a new discussion in JBoss Web Services at Community

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20110405/c065aee3/attachment.html 

More information about the jboss-user mailing list