public boolean nextKeyValue() throws IOException, InterruptedException {
if (!iterator.hasNext()) {
return false;
}
AtomWritable atomWritable = iterator.next();
key = new CompositeKey(
ByteBuffer.wrap(atomWritable.getKey()),
atomWritable.getAtom().name(),
atomWritable.getAtom().maxTimestamp()
);
value = atomWritable;