org.archive.wayback.resourceindex.updater
Class LocalResourceIndexUpdater
java.lang.Object
org.archive.wayback.resourceindex.updater.LocalResourceIndexUpdater
- All Implemented Interfaces:
- Shutdownable
public class LocalResourceIndexUpdater
- extends java.lang.Object
- implements Shutdownable
Class which starts a background thread that repeatedly scans an incoming
directory and merges files found therein(which are assumed to be in CDX
format) with a BDBIndex. Optional configurations include:
target directory where merged files are moved to (otherwise deleted)
target directory where failed failed are moved(otherwise left in place)
milliseconds between scans of the incoming directory(default 10000)
- Version:
- $Date: 2008-08-08 16:03:50 -0700 (Fri, 08 Aug 2008) $, $Revision: 2529 $
- Author:
- brad
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
LocalResourceIndexUpdater
public LocalResourceIndexUpdater()
init
public void init()
throws ConfigurationException
- start the background index merging thread
- Throws:
ConfigurationException
shutdown
public void shutdown()
- Specified by:
shutdown in interface Shutdownable
mergeAll
protected int mergeAll()
getIndex
public LocalResourceIndex getIndex()
- Returns:
- the index
setIndex
public void setIndex(LocalResourceIndex index)
- Parameters:
index - the index to set
getIncoming
public java.lang.String getIncoming()
- Returns:
- the incoming directory path, or null if not set
setIncoming
public void setIncoming(java.lang.String incoming)
throws java.io.IOException
- Parameters:
incoming - the incoming to set
- Throws:
java.io.IOException
getMerged
public java.lang.String getMerged()
- Returns:
- the merged directory path, or null if not set
setMerged
public void setMerged(java.lang.String merged)
throws java.io.IOException
- Parameters:
merged -
- Throws:
java.io.IOException
getFailed
public java.lang.String getFailed()
- Returns:
- the failed directory path, or null if not set
setFailed
public void setFailed(java.lang.String failed)
throws java.io.IOException
- Parameters:
failed - The failed to set.
- Throws:
java.io.IOException
getRunInterval
public int getRunInterval()
- Returns:
- the runInterval
setRunInterval
public void setRunInterval(int runInterval)
- Parameters:
runInterval - The runInterval to set.
Copyright © 2005-2009 Internet Archive. All Rights Reserved.