@Override public ClientResponse<RetryResponseHolder<Final>> done(
      ClientResponse<RetryResponseHolder<Intermediate>> clientResponse) {
    if (clientResponse.getObj().shouldRetry()) {
      return ClientResponse.finished(RetryResponseHolder.retry());
    } else {
      return wrap(httpResponseHandler.done(unwrap(clientResponse)));
    }
  }
Class handling retry on Unauthorized responses.

@param <Intermediate> Intermediate response type.
@param <Final> final result type.
druid-handler/src/java/org/apache/hadoop/hive/druid/security/RetryIfUnauthorizedResponseHandler.java