Search code examples
javawsdlcxf

CXF is not generating "throws RemoteException"


I am trying to migrate to CXF from AXIS. I am facing a lot of differences in code, generated from the same wsdl file (different method arguments list, return types). There is no RemoteException throwing declaration for all methods, generated by CXF. Any suggestions? Thanks. Paul.


Solution

  • Per JAX-WS spec the methods should not be throwing RemoteException. They could throw a javax.xml.ws.WebServiceException if something goes wrong, but that is a subclass of RuntimeException and thus doesn't need to be declared.