Class CrawlerAgent
- java.lang.Object
- 
- org.apache.manifoldcf.crawler.system.CrawlerAgent
 
- 
- 
Field Summary
 - 
Constructor SummaryConstructors Constructor Description CrawlerAgent()Constructor.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcleanUp(IThreadContext threadContext)Tear down agent environment.voidcleanUpAgentData(IThreadContext threadContext, java.lang.String currentProcessID, java.lang.String cleanupProcessID)Cleanup after agents process.voidcleanUpAllAgentData(IThreadContext threadContext, java.lang.String currentProcessID)Cleanup after ALL agents processes.voidclusterInit(IThreadContext threadContext)Called ONLY when no other active services of this kind are running.voiddeinstall(IThreadContext threadContext)Uninstall agent.voidinitialize(IThreadContext threadContext)Initialize agent environment.voidinstall(IThreadContext threadContext)Install agent.booleanisOutputConnectionInUse(IThreadContext threadContext, java.lang.String connName)Request permission from agent to delete an output connection.booleanisTransformationConnectionInUse(IThreadContext threadContext, java.lang.String connName)Request permission from agent to delete a transformation connection.voidnoteOutputConnectionChange(IThreadContext threadContext, java.lang.String connectionName)Note a change in configuration for an output connection.voidnoteOutputConnectorDeregistration(IThreadContext threadContext, java.lang.String[] connectionNames)Note the deregistration of a set of output connections.voidnoteOutputConnectorRegistration(IThreadContext threadContext, java.lang.String[] connectionNames)Note the registration of a set of output connections.voidnoteTransformationConnectionChange(IThreadContext threadContext, java.lang.String connectionName)Note a change in configuration for a transformation connection.voidnoteTransformationConnectorDeregistration(IThreadContext threadContext, java.lang.String[] connectionNames)Note the deregistration of a set of transformation connections.voidnoteTransformationConnectorRegistration(IThreadContext threadContext, java.lang.String[] connectionNames)Note the registration of a set of transformation connections.voidstartAgent(IThreadContext threadContext, java.lang.String processID)Start the agent.voidstartSystem(IThreadContext threadContext)Start everything.voidstopAgent(IThreadContext threadContext)Stop the agent.voidstopSystem(IThreadContext threadContext)Stop the system.
 
- 
- 
- 
Field Detail- 
_rcsidpublic static final java.lang.String _rcsid - See Also:
- Constant Field Values
 
 - 
jobStartThreadprotected JobStartThread jobStartThread 
 - 
stufferThreadprotected StufferThread stufferThread 
 - 
finisherThreadprotected FinisherThread finisherThread 
 - 
notificationThreadprotected JobNotificationThread notificationThread 
 - 
startupThreadprotected StartupThread startupThread 
 - 
startDeleteThreadprotected StartDeleteThread startDeleteThread 
 - 
jobDeleteThreadprotected JobDeleteThread jobDeleteThread 
 - 
workerThreadsprotected WorkerThread[] workerThreads 
 - 
expireStufferThreadprotected ExpireStufferThread expireStufferThread 
 - 
expireThreadsprotected ExpireThread[] expireThreads 
 - 
deleteStufferThreadprotected DocumentDeleteStufferThread deleteStufferThread 
 - 
deleteThreadsprotected DocumentDeleteThread[] deleteThreads 
 - 
cleanupStufferThreadprotected DocumentCleanupStufferThread cleanupStufferThread 
 - 
cleanupThreadsprotected DocumentCleanupThread[] cleanupThreads 
 - 
jobResetThreadprotected JobResetThread jobResetThread 
 - 
seedingThreadprotected SeedingThread seedingThread 
 - 
idleCleanupThreadprotected IdleCleanupThread idleCleanupThread 
 - 
setPriorityThreadprotected SetPriorityThread setPriorityThread 
 - 
historyCleanupThreadprotected HistoryCleanupThread historyCleanupThread 
 - 
assessmentThreadprotected AssessmentThread assessmentThread 
 - 
workerResetManagerprotected WorkerResetManager workerResetManager Worker thread pool reset manager
 - 
docDeleteResetManagerprotected DocDeleteResetManager docDeleteResetManager Delete thread pool reset manager
 - 
docCleanupResetManagerprotected DocCleanupResetManager docCleanupResetManager Cleanup thread pool reset manager
 - 
numWorkerThreadsprotected int numWorkerThreads 
 - 
numDeleteThreadsprotected int numDeleteThreads 
 - 
numCleanupThreadsprotected int numCleanupThreads 
 - 
numExpireThreadsprotected int numExpireThreads 
 - 
lowWaterFactorprotected float lowWaterFactor 
 - 
stuffAmtFactorprotected float stuffAmtFactor 
 - 
processIDprotected java.lang.String processID Process identifier for this agent
 
- 
 - 
Constructor Detail- 
CrawlerAgentpublic CrawlerAgent() throws ManifoldCFExceptionConstructor.- Throws:
- ManifoldCFException
 
 
- 
 - 
Method Detail- 
initializepublic void initialize(IThreadContext threadContext) throws ManifoldCFException Initialize agent environment. This is called before any of the other operations are called, and is meant to insure that the environment is properly initialized.- Specified by:
- initializein interface- IAgent
- Throws:
- ManifoldCFException
 
 - 
cleanUppublic void cleanUp(IThreadContext threadContext) throws ManifoldCFException Tear down agent environment. This is called after all the other operations are completed, and is meant to allow environment resources to be freed.- Specified by:
- cleanUpin interface- IAgent
- Throws:
- ManifoldCFException
 
 - 
installpublic void install(IThreadContext threadContext) throws ManifoldCFException Install agent. This usually installs the agent's database tables etc.- Specified by:
- installin interface- IAgent
- Throws:
- ManifoldCFException
 
 - 
deinstallpublic void deinstall(IThreadContext threadContext) throws ManifoldCFException Uninstall agent. This must clean up everything the agent is responsible for.- Specified by:
- deinstallin interface- IAgent
- Throws:
- ManifoldCFException
 
 - 
clusterInitpublic void clusterInit(IThreadContext threadContext) throws ManifoldCFException Called ONLY when no other active services of this kind are running. Meant to be used after the cluster has been down for an indeterminate period of time.- Specified by:
- clusterInitin interface- IAgent
- Throws:
- ManifoldCFException
 
 - 
cleanUpAllAgentDatapublic void cleanUpAllAgentData(IThreadContext threadContext, java.lang.String currentProcessID) throws ManifoldCFException Cleanup after ALL agents processes. Call this method to clean up dangling persistent state when a cluster is just starting to come up. This method CANNOT be called when there are any active agents processes at all.- Specified by:
- cleanUpAllAgentDatain interface- IAgent
- Parameters:
- currentProcessID- is the current process ID.
- Throws:
- ManifoldCFException
 
 - 
cleanUpAgentDatapublic void cleanUpAgentData(IThreadContext threadContext, java.lang.String currentProcessID, java.lang.String cleanupProcessID) throws ManifoldCFException Cleanup after agents process. Call this method to clean up dangling persistent state after agent has been stopped. This method CANNOT be called when the agent is active, but it can be called at any time and by any process in order to guarantee that a terminated agent does not block other agents from completing their tasks.- Specified by:
- cleanUpAgentDatain interface- IAgent
- Parameters:
- currentProcessID- is the current process ID.
- cleanupProcessID- is the process ID of the agent to clean up after.
- Throws:
- ManifoldCFException
 
 - 
startAgentpublic void startAgent(IThreadContext threadContext, java.lang.String processID) throws ManifoldCFException Start the agent. This method should spin up the agent threads, and then return.- Specified by:
- startAgentin interface- IAgent
- processID- is the process ID to start up an agent for.
- Throws:
- ManifoldCFException
 
 - 
stopAgentpublic void stopAgent(IThreadContext threadContext) throws ManifoldCFException Stop the agent. This should shut down the agent threads etc.- Specified by:
- stopAgentin interface- IAgent
- Throws:
- ManifoldCFException
 
 - 
isOutputConnectionInUsepublic boolean isOutputConnectionInUse(IThreadContext threadContext, java.lang.String connName) throws ManifoldCFException Request permission from agent to delete an output connection.- Specified by:
- isOutputConnectionInUsein interface- IAgent
- Parameters:
- connName- is the name of the output connection.
- Returns:
- true if the connection is in use, false otherwise.
- Throws:
- ManifoldCFException
 
 - 
noteOutputConnectorDeregistrationpublic void noteOutputConnectorDeregistration(IThreadContext threadContext, java.lang.String[] connectionNames) throws ManifoldCFException Note the deregistration of a set of output connections.- Specified by:
- noteOutputConnectorDeregistrationin interface- IAgent
- Parameters:
- connectionNames- are the names of the connections being deregistered.
- Throws:
- ManifoldCFException
 
 - 
noteOutputConnectorRegistrationpublic void noteOutputConnectorRegistration(IThreadContext threadContext, java.lang.String[] connectionNames) throws ManifoldCFException Note the registration of a set of output connections.- Specified by:
- noteOutputConnectorRegistrationin interface- IAgent
- Parameters:
- connectionNames- are the names of the connections being registered.
- Throws:
- ManifoldCFException
 
 - 
noteOutputConnectionChangepublic void noteOutputConnectionChange(IThreadContext threadContext, java.lang.String connectionName) throws ManifoldCFException Note a change in configuration for an output connection.- Specified by:
- noteOutputConnectionChangein interface- IAgent
- Parameters:
- connectionName- is the name of the connections being changed.
- Throws:
- ManifoldCFException
 
 - 
isTransformationConnectionInUsepublic boolean isTransformationConnectionInUse(IThreadContext threadContext, java.lang.String connName) throws ManifoldCFException Request permission from agent to delete a transformation connection.- Specified by:
- isTransformationConnectionInUsein interface- IAgent
- Parameters:
- connName- is the name of the transformation connection.
- Returns:
- true if the connection is in use, false otherwise.
- Throws:
- ManifoldCFException
 
 - 
noteTransformationConnectorDeregistrationpublic void noteTransformationConnectorDeregistration(IThreadContext threadContext, java.lang.String[] connectionNames) throws ManifoldCFException Note the deregistration of a set of transformation connections.- Specified by:
- noteTransformationConnectorDeregistrationin interface- IAgent
- Parameters:
- connectionNames- are the names of the connections being deregistered.
- Throws:
- ManifoldCFException
 
 - 
noteTransformationConnectorRegistrationpublic void noteTransformationConnectorRegistration(IThreadContext threadContext, java.lang.String[] connectionNames) throws ManifoldCFException Note the registration of a set of transformation connections.- Specified by:
- noteTransformationConnectorRegistrationin interface- IAgent
- Parameters:
- connectionNames- are the names of the connections being registered.
- Throws:
- ManifoldCFException
 
 - 
noteTransformationConnectionChangepublic void noteTransformationConnectionChange(IThreadContext threadContext, java.lang.String connectionName) throws ManifoldCFException Note a change in configuration for a transformation connection.- Specified by:
- noteTransformationConnectionChangein interface- IAgent
- Parameters:
- connectionName- is the name of the connection being changed.
- Throws:
- ManifoldCFException
 
 - 
startSystempublic void startSystem(IThreadContext threadContext) throws ManifoldCFException Start everything.- Throws:
- ManifoldCFException
 
 - 
stopSystempublic void stopSystem(IThreadContext threadContext) throws ManifoldCFException Stop the system.- Throws:
- ManifoldCFException
 
 
- 
 
-