AtomicBoolean loggedUri = new AtomicBoolean(false);
ImmutableList.Builder<MaterializedRow> rows = ImmutableList.builder();
List<Type> types = null;
while (client.isValid()) {
QueryResults results = client.current();
if (!loggedUri.getAndSet(true)) {
log.info("Query %s: %s?pretty", results.getId(), results.getInfoUri());
}
if ((types == null) && (results.getColumns() != null)) {
types = getTypes(coordinator.getMetadata(), results.getColumns());
}
if (results.getData() != null) {
rows.addAll(transform(results.getData(), dataToRow(session.getTimeZoneKey(), types)));
}
client.advance();
}