Apache CXF JBoss 4.2 deployment – tips and tricks

If you are not able to deploy an application using Apache CXF library in JBoss, you might want to check first Application Server Specific Configuration Guide chapter of CXF user’s guide.

Furthermore, check if the JBossWS framework is already deployed (jbossws.sar directory in the JBoss deployment directory) and try to remove it. It contains already a lot of APIs and implementations that can confict with APIs and implementations provided with CXF.

Concrete example – I was using CXF 2.0 series which implements JAX-WS 2.0 standard. JBossWS 2.0 framework, shipped with JBoss 4.2, implements JAX-WS 2.1 specification. In some situations when a dateTime was parsed I was getting NullPointerException with a message about marshalling error. Removing the jbossws.sar helped.