Better error handling for ncs requests, and better error responses to client.

* Changed NCSQuery to use zend http client instead of file_get_contents
* NCSException exception class to include NCS error code string
* Now returning 404 to client when requesting a record that's not in the repo
* Now returning 500 response code when there's an NCS error (other than
  not found) or when there's some other HTTP error tyring to get NCS response.
Better error handling for json search.