|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sleepycat.je.utilint.DaemonThread
com.sleepycat.je.incomp.INCompressor
public class INCompressor
The IN Compressor. JE compression consist of removing delete entries from BINs, and pruning empty IN/BINs from the tree. Compression is carried out by either a daemon thread or lazily by operations (namely checkpointing and eviction) that are writing INS.
Field Summary |
---|
Fields inherited from class com.sleepycat.je.utilint.DaemonThread |
---|
name, nWakeupRequests, workQueue, workQueueLatch |
Constructor Summary | |
---|---|
INCompressor(EnvironmentImpl env,
long waitTime,
String name)
|
Method Summary | |
---|---|
void |
addBinKeyToQueue(BIN bin,
Key deletedKey,
boolean doWakeup)
Adds the BIN and deleted Key to the queue if the BIN is not already in the queue, or adds the deleted key to an existing entry if one exists. |
void |
addBinRefToQueue(BINReference binRef,
boolean doWakeup)
Adds the BINReference to the queue if the BIN is not already in the queue, or adds the deleted keys to an existing entry if one exists. |
void |
addMultipleBinRefsToQueue(Collection binRefs,
boolean doWakeup)
Adds an entire collection of BINReferences to the queue at once. |
void |
addToQueue(Object o)
The default daemon work queue is not used because we need a map, not a set. |
void |
clearEnv()
|
void |
doCompress()
The real work to doing a compress. |
boolean |
exists(long nodeId)
|
int |
getBinRefQueueSize()
|
void |
lazyCompress(IN in)
Lazily compress a single BIN. |
void |
loadStats(StatsConfig config,
EnvironmentStats stat)
Return stats |
protected int |
nDeadlockRetries()
Return the number of retries when a deadlock exception occurs. |
void |
onWakeup()
onWakeup is synchronized to ensure that multiple invocations of the DaemonThread aren't made. |
BIN |
searchForBIN(DatabaseImpl db,
BINReference binRef)
Search the tree for the BIN or DBIN that corresponds to this BINReference. |
String |
toString()
|
void |
verifyCursors()
|
Methods inherited from class com.sleepycat.je.utilint.DaemonThread |
---|
addToQueueAlreadyLatched, getNWakeupRequests, getQueueSize, getThread, isRunning, isShutdownRequested, requestShutdown, run, runOrPause, shutdown, wakeup |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public INCompressor(EnvironmentImpl env, long waitTime, String name) throws DatabaseException
DatabaseException
Method Detail |
---|
public String toString()
toString
in class DaemonThread
public void clearEnv()
public void verifyCursors() throws DatabaseException
DatabaseException
public void addToQueue(Object o) throws DatabaseException
addToQueue
in class DaemonThread
DatabaseException
public int getBinRefQueueSize() throws DatabaseException
DatabaseException
public void addBinKeyToQueue(BIN bin, Key deletedKey, boolean doWakeup) throws DatabaseException
DatabaseException
public void addBinRefToQueue(BINReference binRef, boolean doWakeup) throws DatabaseException
DatabaseException
public void addMultipleBinRefsToQueue(Collection binRefs, boolean doWakeup) throws DatabaseException
DatabaseException
public boolean exists(long nodeId)
public void loadStats(StatsConfig config, EnvironmentStats stat) throws DatabaseException
DatabaseException
protected int nDeadlockRetries() throws DatabaseException
nDeadlockRetries
in class DaemonThread
DatabaseException
public void onWakeup() throws DatabaseException
DaemonThread
onWakeup
in class DaemonThread
DatabaseException
public void doCompress() throws DatabaseException
DatabaseException
public BIN searchForBIN(DatabaseImpl db, BINReference binRef) throws DatabaseException
binRef
- the BINReference that indicates the bin we want.
DatabaseException
public void lazyCompress(IN in) throws DatabaseException
DatabaseException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |