try {
Result<ProductDTO> result = productService.findBy(uriInfo, searchString, categoryId, priceFrom, priceTo, order, base, offset);
return Response.status(Response.Status.OK).header("X-Count", result.getCount()).entity(result.getData()).build();
} catch (NotExistingEntityException ex) {
throw new NotFoundException(ex.getMessage());
}
}