I'm creating a web service in Java EE 6 annotating an enterprise bean with @WebService
.
I need to expose only some of the bean methods, so I've annotated with @WebMethod
only the required ones.
Unfortunately JAX-WS ignores the annotations and try to expose all methods. The trouble is that there is one method, that's not intended to be used as a web service operation, that returns an interface and this cannot be managed by JAX-WS, so the web service is not deployed.
Is this an expected behavior or am I missing something?
You could add the attribute 'exclude' to the annotation and set it to true. The Javadoc states: Marks a method to NOT be exposed as a web method.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With