} else if (original instanceof TTransportException) {
// if the underlying cause is a scoket timeout, reflect that directly
// TODO this may be an issue on the Cassandra side which warrants ivestigation.
// I seem to remember these coming back as TimedOutException previously
if ( ((TTransportException)original).getCause() instanceof SocketTimeoutException ) {
return new HTimedOutException(original);
} else {
return new HectorTransportException(original);
}
} else if (original instanceof org.apache.cassandra.thrift.TimedOutException) {
return new HTimedOutException(original);
} else if (original instanceof org.apache.cassandra.thrift.InvalidRequestException) {
// See bug https://issues.apache.org/jira/browse/CASSANDRA-1862
// If a bootstrapping node is accessed it responds with IRE. It makes more sense to throw
// UnavailableException.
// Hector wraps this caveat and fixes this.