private void periodicRoll() throws IOException { if (storeTracker.isEmpty()) { LOG.trace("no active procedures"); tryRollWriter(); removeAllLogs(flushLogId - 1, "no active procedures"); } else { if (storeTracker.isAllModified()) { LOG.trace("all the active procedures are in the latest log"); removeAllLogs(flushLogId - 1, "all the active procedures are in the latest log"); } // if the log size has exceeded the roll threshold // or the periodic roll timeout is expired, try to roll the wal. if (totalSynced.get() > rollThreshold || getMillisToNextPeriodicRoll() <= 0) { tryRollWriter(); } removeInactiveLogs(); } }
waitCond.await(getMillisToNextPeriodicRoll(), TimeUnit.MILLISECONDS); if (slotIndex == 0) {
long millisToNextRoll = walStore.getMillisToNextPeriodicRoll(); long millisFromLastRoll = walStore.getMillisFromLastRoll(); ArrayList<ProcedureWALFile> procedureWALFiles = walStore.getActiveLogs();
private void periodicRoll() throws IOException { if (storeTracker.isEmpty()) { if (LOG.isTraceEnabled()) { LOG.trace("no active procedures"); } tryRollWriter(); removeAllLogs(flushLogId - 1); } else { if (storeTracker.isUpdated()) { if (LOG.isTraceEnabled()) { LOG.trace("all the active procedures are in the latest log"); } removeAllLogs(flushLogId - 1); } // if the log size has exceeded the roll threshold // or the periodic roll timeout is expired, try to roll the wal. if (totalSynced.get() > rollThreshold || getMillisToNextPeriodicRoll() <= 0) { tryRollWriter(); } removeInactiveLogs(); } }
private void periodicRoll() throws IOException { if (storeTracker.isEmpty()) { LOG.trace("no active procedures"); tryRollWriter(); removeAllLogs(flushLogId - 1, "no active procedures"); } else { if (storeTracker.isAllModified()) { LOG.trace("all the active procedures are in the latest log"); removeAllLogs(flushLogId - 1, "all the active procedures are in the latest log"); } // if the log size has exceeded the roll threshold // or the periodic roll timeout is expired, try to roll the wal. if (totalSynced.get() > rollThreshold || getMillisToNextPeriodicRoll() <= 0) { tryRollWriter(); } removeInactiveLogs(); } }
waitCond.await(getMillisToNextPeriodicRoll(), TimeUnit.MILLISECONDS); if (slotIndex == 0) {
waitCond.await(getMillisToNextPeriodicRoll(), TimeUnit.MILLISECONDS); if (slotIndex == 0) {
waitCond.await(getMillisToNextPeriodicRoll(), TimeUnit.MILLISECONDS); if (slotIndex == 0) {
private void periodicRoll() throws IOException { if (storeTracker.isEmpty()) { if (LOG.isTraceEnabled()) { LOG.trace("no active procedures"); } tryRollWriter(); removeAllLogs(flushLogId - 1); } else { if (storeTracker.isUpdated()) { if (LOG.isTraceEnabled()) { LOG.trace("all the active procedures are in the latest log"); } removeAllLogs(flushLogId - 1); } // if the log size has exceeded the roll threshold // or the periodic roll timeout is expired, try to roll the wal. if (totalSynced.get() > rollThreshold || getMillisToNextPeriodicRoll() <= 0) { tryRollWriter(); } removeInactiveLogs(); } }