Setter method for entity manager to override incase of app managed persistence.
Handling flow via error codes, no more exceptions.
Added handlers for unknown http status codes.