private boolean waitUntilFlushIsReady() throws InterruptedException { if (maxAsyncItems > 0) { final long time = getTimeInterval(); synchronized (asyncMonitor) { if (time > 0) { long time = getTimeInterval(); if (time > 0) { long nanosRemaining = TimeUnit.MILLISECONDS.toNanos(time);
private boolean waitUntilFlushIsReady() throws InterruptedException { if (maxAsyncItems > 0) { final long time = getTimeInterval(); synchronized (asyncMonitor) { if (time > 0) { long time = getTimeInterval(); if (time > 0) { long nanosRemaining = TimeUnit.MILLISECONDS.toNanos(time);
private void initDiskData() { this.name = diskStore.getName(); this.compactionThreshold = diskStore.getCompactionThreshold(); this.timeInterval = diskStore.getTimeInterval(); this.writeBufferSize = diskStore.getWriteBufferSize(); this.maxOpLogSize = diskStore.getMaxOplogSize(); this.queueSize = diskStore.getQueueSize(); this.isAutoCompact = diskStore.getAutoCompact(); this.isForceCompactionAllowed = diskStore.getAllowForceCompaction(); this.directoryHolders = diskStore.getDirectoryHolders(); File[] diskDirs = diskStore.getDiskDirs(); String[] diskDirStr = new String[diskDirs.length]; for (int i = 0; i < diskDirs.length; i++) { diskDirStr[i] = diskDirs[i].getName(); } this.diskDirectories = diskDirStr; }
private void initDiskData() { this.name = diskStore.getName(); this.compactionThreshold = diskStore.getCompactionThreshold(); this.timeInterval = diskStore.getTimeInterval(); this.writeBufferSize = diskStore.getWriteBufferSize(); this.maxOpLogSize = diskStore.getMaxOplogSize(); this.queueSize = diskStore.getQueueSize(); this.isAutoCompact = diskStore.getAutoCompact(); this.isForceCompactionAllowed = diskStore.getAllowForceCompaction(); this.directoryHolders = diskStore.getDirectoryHolders(); File[] diskDirs = diskStore.getDiskDirs(); String[] diskDirStr = new String[diskDirs.length]; for (int i = 0; i < diskDirs.length; i++) { diskDirStr[i] = diskDirs[i].getAbsolutePath(); } this.diskDirectories = diskDirStr; }
if (getTimeInterval() != props.getTimeInterval()) { if (logger.isDebugEnabled()) { logger.debug("TimeInterval {} != {}", getTimeInterval(), props.getTimeInterval()); && getName().equals(props.getName()) && getQueueSize() == props.getQueueSize() && getTimeInterval() == props.getTimeInterval() && getWriteBufferSize() == props.getWriteBufferSize() && Arrays.equals(getDiskDirs(), props.getDiskDirs())
/** * @since 5.1 */ public void forceRolling(DiskRegion dr) { if (!dr.isBackup()) return; if (!dr.isSync() && this.maxAsyncItems == 0 && getTimeInterval() == 0) { forceFlush(); } acquireReadLock(dr); try { PersistentOplogSet oplogSet = getPersistentOplogSet(dr); oplogSet.forceRoll(dr); } finally { releaseReadLock(dr); } }
/** * @since 5.1 */ public void forceRolling(DiskRegion dr) { if (!dr.isBackup()) return; if (!dr.isSync() && this.maxAsyncItems == 0 && getTimeInterval() == 0) { forceFlush(); } acquireReadLock(dr); try { PersistentOplogSet oplogSet = getPersistentOplogSet(dr); oplogSet.forceRoll(dr); } finally { releaseReadLock(dr); } }
+ getQueueSize() + "!=" + props.getQueueSize()); if (getTimeInterval() != props.getTimeInterval()) { this.logger.info(LocalizedStrings.DEBUG, "DEBUG TimeInterval " + getTimeInterval() + "!=" + props.getTimeInterval()); && getName().equals(props.getName()) && getQueueSize() == props.getQueueSize() && getTimeInterval() == props.getTimeInterval() && getWriteBufferSize() == props.getWriteBufferSize() && Arrays.equals(getDiskDirs(), props.getDiskDirs())
DiskStoreImpl ds = lr.getDiskStore(); assertEquals(1, ds.getMaxOplogSize()); assertEquals(333, ds.getTimeInterval()); DiskStoreImpl ds = lr.getDiskStore(); assertEquals(1, ds.getMaxOplogSize()); assertEquals(333, ds.getTimeInterval()); DiskStoreImpl ds = lr.getDiskStore(); assertEquals(1, ds.getMaxOplogSize()); assertEquals(333, ds.getTimeInterval());
DiskStoreImpl ds = lr.getDiskStore(); assertEquals(2, ds.getMaxOplogSize()); assertEquals(1, ds.getTimeInterval()); assertEquals(0, ds.getQueueSize()); DiskStoreImpl ds = lr.getDiskStore(); assertEquals(2, ds.getMaxOplogSize()); assertEquals(1, ds.getTimeInterval()); assertEquals(0, ds.getQueueSize()); DiskStoreImpl ds = lr.getDiskStore(); assertEquals(2, ds.getMaxOplogSize()); assertEquals(1, ds.getTimeInterval()); assertEquals(0, ds.getQueueSize());