java.io.Closeable, java.lang.AutoCloseable, java.lang.Runnable@LimitedPrivate("HDFS")
public class CacheReplicationMonitor
extends java.lang.Thread
implements java.io.Closeable
| Constructor | Description |
|---|---|
CacheReplicationMonitor(FSNamesystem namesystem,
CacheManager cacheManager,
long intervalMs,
java.util.concurrent.locks.ReentrantLock lock) |
| Modifier and Type | Method | Description |
|---|---|---|
void |
close() |
Shut down the monitor thread.
|
void |
run() |
|
void |
setNeedsRescan() |
Indicates to the CacheReplicationMonitor that there have been CacheManager
changes that require a rescan.
|
void |
waitForRescanIfNeeded() |
Waits for a rescan to complete.
|
activeCount, checkAccess, clone, countStackFrames, currentThread, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, onSpinWait, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, suspend, toString, yieldpublic CacheReplicationMonitor(FSNamesystem namesystem, CacheManager cacheManager, long intervalMs, java.util.concurrent.locks.ReentrantLock lock)
public void run()
run in interface java.lang.Runnablerun in class java.lang.Threadpublic void waitForRescanIfNeeded()
Note that this call will release the FSN lock, so operations before and after are not atomic.
public void setNeedsRescan()
public void close()
throws java.io.IOException
close in interface java.lang.AutoCloseableclose in interface java.io.Closeablejava.io.IOExceptionCopyright © 2008–2025 Apache Software Foundation. All rights reserved.