Intercept JAX-RS Request with Jersey ContainerRequestFilter - Java Tutorial Blog
ContainerRequestFilter
ContainerRequestFilter
this is an interface and should be implemented by the container request filters.
- We should annotate the filter class that implements this interface with
@Provider
so that the JAX-RS runtime will discover this filter. As always, this annotation is sufficient and there is no other configuration required in web.xml @NameBinding
annotation can be applied to match the request for filter execution.- By default filter is executed
post-match
and if we want the execution to be done before match we should use the@PreMatching
annotation.
Read full article from Intercept JAX-RS Request with Jersey ContainerRequestFilter - Java Tutorial Blog
No comments:
Post a Comment