public void run() { // mark writes older than the barrier as blocking progress, permitting them to exceed our memory limit // if they are stuck waiting on it, then wait for them all to complete writeBarrier.markBlocking(); writeBarrier.await(); // mark all memtables as flushing, removing them from the live memtable list for (Memtable memtable : memtables) memtable.cfs.data.markFlushing(memtable); metric.memtableSwitchCount.inc(); try { // Flush "data" memtable with non-cf 2i first; flushMemtable(memtables.get(0), true); for (int i = 1; i < memtables.size(); i++) flushMemtable(memtables.get(i), false); } catch (Throwable t) { JVMStabilityInspector.inspectThrowable(t); postFlush.flushFailure = t; } // signal the post-flush we've done our work postFlush.latch.countDown(); }
public void run() { // mark writes older than the barrier as blocking progress, permitting them to exceed our memory limit // if they are stuck waiting on it, then wait for them all to complete writeBarrier.markBlocking(); writeBarrier.await(); // mark all memtables as flushing, removing them from the live memtable list for (Memtable memtable : memtables) memtable.cfs.data.markFlushing(memtable); metric.memtableSwitchCount.inc(); try { // Flush "data" memtable with non-cf 2i first; flushMemtable(memtables.get(0), true); for (int i = 1; i < memtables.size(); i++) flushMemtable(memtables.get(i), false); } catch (Throwable t) { JVMStabilityInspector.inspectThrowable(t); postFlush.flushFailure = t; } // signal the post-flush we've done our work postFlush.latch.countDown(); }
public void run() { // mark writes older than the barrier as blocking progress, permitting them to exceed our memory limit // if they are stuck waiting on it, then wait for them all to complete writeBarrier.markBlocking(); writeBarrier.await(); // mark all memtables as flushing, removing them from the live memtable list for (Memtable memtable : memtables) memtable.cfs.data.markFlushing(memtable); metric.memtableSwitchCount.inc(); try { // Flush "data" memtable with non-cf 2i first; flushMemtable(memtables.get(0), true); for (int i = 1; i < memtables.size(); i++) flushMemtable(memtables.get(i), false); } catch (Throwable t) { JVMStabilityInspector.inspectThrowable(t); postFlush.flushFailure = t; } // signal the post-flush we've done our work postFlush.latch.countDown(); }