throws UnavailableException, ReadTimeoutException
{
Tracing.trace("Determining replicas to query");
long startTime = System.nanoTime();
Keyspace keyspace = Keyspace.open(command.keyspace);
List<Row> rows;
// now scan until we have enough results
try
{
int cql3RowCount = 0;
rows = new ArrayList<>();
// when dealing with LocalStrategy keyspaces, we can skip the range splitting and merging (which can be
// expensive in clusters with vnodes)
List<? extends AbstractBounds<RowPosition>> ranges;
if (keyspace.getReplicationStrategy() instanceof LocalStrategy)
ranges = command.keyRange.unwrap();
else
ranges = getRestrictedRanges(command.keyRange);
// our estimate of how many result rows there will be per-range