Improved exception handling for Elasticsearch collector

Catching HTTPError only works for HTTP errors. Connectivity issues (during ES restart) trigger an URLError, not catched thus crashing the collector.

As HTTPError is a subclass of URLError, this change will deal with more failure situations.