public abstract class MultipleTimerAgent extends BaseAgent
Modifier and Type | Class and Description |
---|---|
class |
MultipleTimerAgent.MultipleTimerTask
A MultipleTimerTask is a TimerTask with its run() method
implemented to post a request to the agent request queue,
and an abstract method for execution of the task.
|
IfsServer.ServerRequest
ERROR_COUNT_CUMULATIVE, ERROR_COUNT_LAST_ACTIVATION
LEVEL_HIGH, LEVEL_LOW, LEVEL_MEDIUM, LEVEL_OFF
SERVERSTATUS_DISPOSED, SERVERSTATUS_RUNNING, SERVERSTATUS_STARTING, SERVERSTATUS_STOPPED, SERVERSTATUS_STOPPING, SERVERSTATUS_SUSPENDED, SERVERSTATUS_UNKNOWN
Constructor and Description |
---|
MultipleTimerAgent()
Constructs the MultipleTimerAgent.
|
Modifier and Type | Method and Description |
---|---|
protected void |
activate()
Dummy implementation for activate.
|
IfsLogger |
getLogger()
Gets the appropriate logger for this server.
|
protected void |
handleRequest(IfsServer.ServerRequest request)
Handles the specified pending request.
|
protected void |
initOnRun()
Perform Initialization at start of run method.
|
void |
postRun()
Performs post-run tasks.
|
protected abstract void |
registerTasks()
Perform Initialization at start of run method.
|
protected void |
registerTimerTask(MultipleTimerAgent.MultipleTimerTask task,
String execPeriod,
String baseTimeOfDay,
String timeFormat)
Registers a MultipleTimerTask.
|
addToProperty, handleResumeRequest, handleStopRequest, handleSuspendRequest, handleTimerExpired, incrementProperty, initialize, isAgent, processWithinRun, publishProperty, run, standardPostRun, supportsSuspendResume
cancelRegistration, checkRegistration, deriveAgentIdentifier, deriveRunningServerIdentifier, getAgentIdentifier, getAgentIdentifierPrefix, getRegistrationPeriod, getRunningNodeIdentifier, getRunningNodeName, getRunningServerIdentifier, initializeRegistration, isRegistered, isServerRunning, isTokenNonCompeting
checkSession, connectSession, constructSession, convertTimerInterval, convertTimerInterval, convertTimerInterval, dispose, getLastTimerActivation, getNextTimerActivation, getService, getTimerActivationPeriod, getTimerClassName, getTimerConfiguration, handlePriorityChangeRequest, handlePropertyChangeRequest, handlePropertyChangeRequest, handleRequests, handleServerStateControllerRequest, isNonCompeting, isPropertyReadonly, isServiceAvailable, isTimerActive, postCheckServerStateRequest, postRequest, preRun, processEvent, processEvents, queueEvent, resetTimer, restart, resume, serviceAvailabilityCheckNeeded, setPriority, setProperty, setProperty, start, startTimer, stop, stopRequested, stopTimer, suspend, timerExpired, waitForServiceAvailability, waitServer
acquireSession, constructLibrarySessionPool, createServerState, deregister, disconnectSession, getConfigurationOverridesTable, getConfigurationTable, getCredential, getDesiredStatus, getIfsHome, getInitialConfigurationTable, getLoggerForLegacyLogging, getName, getNode, getNodeName, getOracleHome, getParameterTable, getPriority, getProperties, getProperty, getServerConfigurationName, getServerState, getServerStateValue, getServerType, getServiceName, getSession, getStateTable, getStatus, getSystemUserCredential, handleServerConfigurationOverrideRequest, handleServerStateEvent, initialize, initialize, isDisposed, isInitialized, isLogged, log, log, log, releaseSession, releaseSession, setDesiredStatus, setDesiredStatus, setSessionTimeoutPrevented, setStateProperty, setStatus, startStandalone, startStandalone, supportsPriority, toStatusLabel, toStatusLabel, toStatusLabel, verifyNotDisposed, verifyNotDisposed
public MultipleTimerAgent() throws IfsException
IfsException
- if the operation failspublic IfsLogger getLogger()
Typically overridden by subclasses to return the IfsLogger associatged with the specific server.
protected void initOnRun() throws Exception
protected abstract void registerTasks() throws IfsException
IfsException
public void postRun()
protected void registerTimerTask(MultipleTimerAgent.MultipleTimerTask task, String execPeriod, String baseTimeOfDay, String timeFormat) throws IfsException
task
- the taskexecPeriod
- the execution period (e.g. "12H")baseTimeOfDay
- the base time of daytimeFormat
- the time format; if null, use "HH:mm:ss"IfsException
- if the operation failsprotected void handleRequest(IfsServer.ServerRequest request) throws IfsException
Overridden to handle the custom requests for this agent. Defers to super for the standard request types.
handleRequest
in class IfsServer
request
- the request to handleIfsException
- if the operation failsprotected void activate() throws IfsException
activate
in class BaseAgent
IfsException
- if operation failsCopyright © 2023. All rights reserved.