mirror of https://github.com/apache/druid.git
add changes as suggested by cheddar
This commit is contained in:
parent
6fb3e61a98
commit
d6f4cf3733
|
@ -292,20 +292,20 @@ public class DirectDruidClient<T> implements QueryRunner<T>
|
||||||
try {
|
try {
|
||||||
jp = objectMapper.getFactory().createParser(future.get());
|
jp = objectMapper.getFactory().createParser(future.get());
|
||||||
if (jp.nextToken() != JsonToken.START_ARRAY) {
|
if (jp.nextToken() != JsonToken.START_ARRAY) {
|
||||||
throw new IAE("Next token wasn't a START_ARRAY, was[%s] in url [%s]", jp.getCurrentToken(), url);
|
throw new IAE("Next token wasn't a START_ARRAY, was[%s] from url [%s]", jp.getCurrentToken(), url);
|
||||||
} else {
|
} else {
|
||||||
jp.nextToken();
|
jp.nextToken();
|
||||||
objectCodec = jp.getCodec();
|
objectCodec = jp.getCodec();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (IOException e) {
|
catch (IOException e) {
|
||||||
throw Throwables.propagate(new RE(e, "Failure getting results from[%s]", url));
|
throw new RE(e, "Failure getting results from[%s]", url);
|
||||||
}
|
}
|
||||||
catch (InterruptedException e) {
|
catch (InterruptedException e) {
|
||||||
throw Throwables.propagate(new RE(e, "Failure getting results from[%s]", url));
|
throw new RE(e, "Failure getting results from[%s]", url);
|
||||||
}
|
}
|
||||||
catch (ExecutionException e) {
|
catch (ExecutionException e) {
|
||||||
throw Throwables.propagate(new RE(e, "Failure getting results from[%s]", url));
|
throw new RE(e, "Failure getting results from[%s]", url);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue