class OperationCancelledExceptionMapper implements ExceptionMapper<OperationCancelledException> {

    @Override
    public Response toResponse(OperationCancelledException exception) {
        return Response.status(403).entity(exception.getErrorDescriptor()).build();
    }

}