Add ability to pass in a debug_io option
Return early of operations array is empty
Separate out the exceptions for HTTP and ElasticSearch errors