public void applyUpdates(ColumnFamily current, ColumnFamily updates) throws InvalidRequestException { Map<ByteBuffer, CQL3Row> map = null; if (stmt.requiresRead()) { // Uses the "current" values read by Paxos for lists operation that requires a read Iterator<CQL3Row> iter = cfm.comparator.CQL3RowBuilder(cfm, now).group(current.iterator(new ColumnSlice[]{ rowPrefix.slice() })); if (iter.hasNext()) { map = Collections.singletonMap(key, iter.next()); assert !iter.hasNext() : "We shoudn't be updating more than one CQL row per-ModificationStatement"; } } UpdateParameters params = new UpdateParameters(cfm, options, timestamp, stmt.getTimeToLive(options), map); stmt.addUpdateForKey(updates, key, rowPrefix, params); } }
continue; CQL3Row.RowIterator iter = cfm.comparator.CQL3RowBuilder(cfm, now).group(row.cf.getSortedColumns().iterator()); if(iter.getStaticRow() != null) { map.put(row.key.getKey(), iter.getStaticRow());
cells = applySliceRestriction(cells, options); CQL3Row.RowIterator iter = cfm.comparator.CQL3RowBuilder(cfm, now).group(cells);