Cannot rule out using JAX-WS as a web service action

I am creating a web service in Java EE 6 by annotating an enterprise bean using @WebService . I need to expose only some of the bean methods, so I added only the necessary @WebMethod to the @WebMethod annotation. Unfortunately, JAX-WS ignores annotations and tries to expose all methods. The problem is that there is one method that is not intended to be used as a web service operation that returns an interface, and JAX-WS cannot be managed, so the web service is not deployed. Is this the expected behavior or am I missing something?

+7
source share
1 answer

You can add the attribute 'exclude' to the annotation and set it to true. Javadoc states: it marks a method that should NOT display as a web method.

+13
source

All Articles