I'm developing a MVC Web application with a REST interface.
The REST controller performs actions on persisted items through a service class, which translates exceptions coming from the persistence layer.
When a request involves an item that not exists in the database, I would like to return 404 code, but actually this is not possible due to the exception translation operated by the service, that prevents the controller from knowing the reason of the problem.
Should the service class return a particular exception only for this case? Conversely, should the controller check for item existence before any action?