public interface AgentContextAware
Modifier and Type | Method and Description |
---|---|
void |
init(AgentContext agentContext)
Called when the agent context is initializing, and is called before
start(AgentContext) . |
void |
start(AgentContext agentContext)
Called when the agent context is started.
|
void |
stop()
Called when the agent context is stopped.
|
void init(AgentContext agentContext) throws java.lang.Exception
start(AgentContext)
.
Use this method to register event listeners and/or perform other forms of initialization related tasks that need
to be done prior to start(AgentContext)
being called.
agentContext
- the agent context that is initializing, never null
.java.lang.Exception
- if the component fails to initialize, which is logged and ignored by the agent.void start(AgentContext agentContext) throws java.lang.Exception
agentContext
- the agent context that is started, never null
.java.lang.Exception
- if the component fails to start, which is logged and ignored by the agent.void stop() throws java.lang.Exception
java.lang.Exception
- if the component fails to stop, which is logged and ignored by the agent.