Skip to content

Instantly share code, notes, and snippets.

@jsanda
Created June 13, 2012 01:44
Show Gist options
  • Save jsanda/2921288 to your computer and use it in GitHub Desktop.
Save jsanda/2921288 to your computer and use it in GitHub Desktop.
Hector's column slice iterator
SliceQuery<Integer, Double Long> query = HFactory.createSliceQuery(keyspace, IntegerSerializer.get(),
LongSerializer.get(), DoubleSerializer.get());
query.setColumnFamily(rawMetricsDataCF);
query.setKey(scheduleId);
ColumnSliceIterator<Integer, Double, Long> iterator = new ColumnSliceIterator<Integer, Double, Long>(
query, startTime.getMillis(), endTime.getMillis(), false);
HColumn<Long, Double> column = iterator.next();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment