public boolean isCleanAfter(ReplayPosition position) { return isClean() || (position != null && minReplayPosition.compareTo(position) >= 0); }
if (memtable.isClean() || truncate)
protected void runMayThrow() { synchronized (data) { Memtable current = data.getView().getCurrentMemtable(); // if we're not expired, we've been hit by a scheduled flush for an already flushed memtable, so ignore if (current.isExpired()) { if (current.isClean()) { // if we're still clean, instead of swapping just reschedule a flush for later scheduleFlush(); } else { // we'll be rescheduled by the constructor of the Memtable. forceFlush(); } } } } };
protected void runMayThrow() { synchronized (data) { Memtable current = data.getView().getCurrentMemtable(); // if we're not expired, we've been hit by a scheduled flush for an already flushed memtable, so ignore if (current.isExpired()) { if (current.isClean()) { // if we're still clean, instead of swapping just reschedule a flush for later scheduleFlush(); } else { // we'll be rescheduled by the constructor of the Memtable. forceFlush(); } } } } };
protected void runMayThrow() { synchronized (data) { Memtable current = data.getView().getCurrentMemtable(); // if we're not expired, we've been hit by a scheduled flush for an already flushed memtable, so ignore if (current.isExpired()) { if (current.isClean()) { // if we're still clean, instead of swapping just reschedule a flush for later scheduleFlush(); } else { // we'll be rescheduled by the constructor of the Memtable. forceFlush(); } } } } };
protected void runMayThrow() throws Exception { synchronized (data) { Memtable current = data.getView().getCurrentMemtable(); // if we're not expired, we've been hit by a scheduled flush for an already flushed memtable, so ignore if (current.isExpired()) { if (current.isClean()) { // if we're still clean, instead of swapping just reschedule a flush for later scheduleFlush(); } else { // we'll be rescheduled by the constructor of the Memtable. forceFlush(); } } } } };
public Collection<SSTableReader> flushMemtable(Memtable memtable, boolean flushNonCf2i) if (memtable.isClean() || truncate)
public Collection<SSTableReader> flushMemtable(Memtable memtable, boolean flushNonCf2i) if (memtable.isClean() || truncate)
/** * Flush if there is unflushed data in the memtables * * @return a Future yielding the commit log position that can be guaranteed to have been successfully written * to sstables for this table once the future completes */ public ListenableFuture<CommitLogPosition> forceFlush() { synchronized (data) { Memtable current = data.getView().getCurrentMemtable(); for (ColumnFamilyStore cfs : concatWithIndexes()) if (!cfs.data.getView().getCurrentMemtable().isClean()) return switchMemtableIfCurrent(current); return waitForFlushes(); } }
/** * Flush if there is unflushed data in the memtables * * @return a Future yielding the commit log position that can be guaranteed to have been successfully written * to sstables for this table once the future completes */ public ListenableFuture<CommitLogPosition> forceFlush() { synchronized (data) { Memtable current = data.getView().getCurrentMemtable(); for (ColumnFamilyStore cfs : concatWithIndexes()) if (!cfs.data.getView().getCurrentMemtable().isClean()) return switchMemtableIfCurrent(current); return waitForFlushes(); } }
/** * Flush if there is unflushed data in the memtables * * @return a Future yielding the commit log position that can be guaranteed to have been successfully written * to sstables for this table once the future completes */ public ListenableFuture<CommitLogPosition> forceFlush() { synchronized (data) { Memtable current = data.getView().getCurrentMemtable(); for (ColumnFamilyStore cfs : concatWithIndexes()) if (!cfs.data.getView().getCurrentMemtable().isClean()) return switchMemtableIfCurrent(current); return waitForFlushes(); } }
public Collection<SSTableReader> flushMemtable(Memtable memtable, boolean flushNonCf2i) if (memtable.isClean() || truncate)