elasticsearch/elasticsearch — pull request #6829 by javanna (2014-07-11 10:25:52+00:00)
Title: Transport Client: fixed the node retry mechanism which could fail without trying all the connected nodes

The RetryListener was notified twice for each single failure, which caused some additional retries, but more importantly was making the client reach the maximum number of retries (number of connected nodes) too quickly, meanwhile ongoing retries which could succeed are not completed yet.

The `TransportService` already notifies the listener of any exception received from a separate thread through the request holder, no need to notify the retry listener again in any other place (either catch or `onFailure` method itself).