Measure ElasticSearch write peformance

Specifically, keep track of the batch size and how long each batch is taking.

* Remove the timer from DiscoveryIO, as it wasn't useful (was getting ticked even on empty batches).
* Add the new measurement pieces.
* Add a boolean in DiscoveryWriter that keeps work off the threadpool when there are no registered discovery implementations.