tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Romain Manni-Bucau <rmannibu...@gmail.com>
Subject Re: WARNING: No operation matching request path on a full jax-rs app
Date Sun, 05 Jun 2016 19:53:47 GMT
The last one should catch it otherwise a Filter wrapping the request is
likely the easiest. If you don't care staying 100% portable a CXF
interceptor (or another extension point) does the job pretty well AFAIK


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com> | JavaEE Factory
<https://javaeefactory-rmannibucau.rhcloud.com>

2016-06-05 21:42 GMT+02:00 Kirys <kirys@neoteroi.org>:

> On 05/06/2016 21:20, Romain Manni-Bucau wrote:
>
>> Did you try an ExceptionMapper? It could handle 404 and delegate others.
>>
>
> tried these two without any result:
>
> @Provider
> public class EntityNotFoundMapper
>      implements ExceptionMapper<EntityNotFoundException> {
>
>    @Override
>    public Response toResponse(EntityNotFoundException e) {
>       return Response.status(Response.Status.NOT_FOUND).build();
>    }
> }
>
>
> @Provider
> public class WebApplicationExceptionHandler implements
> ExceptionMapper<WebApplicationException> {
>
>     @Override
>     public Response toResponse(WebApplicationException e) {
>         return Response.status(Response.Status.NOT_FOUND).build();
>     }
> }
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message