When using a WSDL-first approach to generate java stubs, is there a way to make exceptions extend RuntimeException instead of Exception?
问题 Is there a way to force JAXB to generate exceptions which extend java.lang.RuntimeException instead of Exceptions when using a WSDL-first approach? I'm using a WSDL-first approach for my Java web services project. The stubs are generated with CXF's "wsdl2java" Maven plugin, which is driven by JAXB. It's able to generate stubs from my WSDL, including generating ~150 different exception classes based on the faults defined in my WSDL. However, all of these exceptions extend java.lang.Exception.