I have been utilizing JAX-WS to generate web service clients in my current Grails project. It is the best I have found so far in consuming SOAP-based web services within a Grails project. I do have one beef with the library though: annotation overload! I am not a huge fan of the overuse of annotations that has happened over the last few years. JAX-WS seems to want to take this to a new level. For the most part the annotations do seem to stay out of the way, except for one scenario which we have in many of our XSD schemas: <xsd:any>.
For example, you have defined a complex type where one of the elements is defined to be <xsd:any>, so that different XML documents can be inserted at that element. The problem is that JAX-WS wants to know all of the possible types at compile-time via annotations! If you don’t provide the run-time classe during compile-time, you will end up with a message liek this when you attempt to marshall the XML:
class example.package.MyType nor any of its super class is known to this context
This breaks all of the abstraction and defining the implementation at run-time. I have not found a simple way to get around this and still add classes to the JAXBContext like I used to be able to do. We have been able to work with it for the most part, but if anyone know of an easy way to add classes to the JAX-WS JAXBContext at run-time, feel free to let me know!