|
OpenNMS API 1.1.3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.opennms.netmgt.outage.OutageManager
The OutageManager receives events selectively and maintains a historical archive of each outage for all devices in the database
Field Summary | |
private static java.lang.String |
LOG4J_CATEGORY
The log4j category used to log debug messsages and statements. |
private BroadcastEventProcessor |
m_eventReceiver
The events receiver |
private java.util.Map |
m_serviceTableMap
The service table map |
private static OutageManager |
m_singleton
The singleton instance of this class |
private int |
m_status
Current status of this fiber |
private RunnableConsumerThreadPool |
m_writerPool
The RunnableConsumerThreadPool that runs writers that update the database |
private static int |
NUM_THREADS
The number of threads that must be started. |
Fields inherited from interface org.opennms.core.fiber.PausableFiber |
PAUSE_PENDING, PAUSED, RESUME_PENDING |
Fields inherited from interface org.opennms.core.fiber.Fiber |
RUNNING, START_PENDING, STARTING, STATUS_NAMES, STOP_PENDING, STOPPED |
Constructor Summary | |
OutageManager()
The constructor for the OutageManager |
Method Summary | |
void |
addServiceMapping(java.lang.String svcname,
long serviceid)
Add the svcname/svcid mapping to the servicetable map |
private void |
buildServiceTableMap(java.sql.Connection dbConn)
Build the servicename to serviceid map - this map is used so as to avoid a database lookup for each incoming event |
private void |
closeOutages(java.sql.Connection dbConn)
Close the currently open outages for services and interfaces that are currently unmanaged |
static OutageManager |
getInstance()
Return a handle to the OutageManager |
java.lang.String |
getName()
Returns a name/id for this process |
long |
getServiceID(java.lang.String svcname)
Return the service id for the name passed |
int |
getStatus()
Returns the current status |
void |
init()
|
void |
pause()
Pauses all the threads |
void |
resume()
Resumes all the threads |
void |
start()
Read the configuration xml, create and start all the subthreads. |
void |
stop()
Stops all the threads |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final java.lang.String LOG4J_CATEGORY
private static final OutageManager m_singleton
private static final int NUM_THREADS
private java.util.Map m_serviceTableMap
private BroadcastEventProcessor m_eventReceiver
private RunnableConsumerThreadPool m_writerPool
private int m_status
Constructor Detail |
public OutageManager()
Method Detail |
private void buildServiceTableMap(java.sql.Connection dbConn) throws java.sql.SQLException
java.sql.SQLException
private void closeOutages(java.sql.Connection dbConn) throws java.sql.SQLException
java.sql.SQLException
public java.lang.String getName()
getName
in interface Fiber
Fiber
.public int getStatus()
getStatus
in interface Fiber
Fiber
.public void init()
public void start()
start
in interface Fiber
public void pause()
pause
in interface PausableFiber
public void resume()
resume
in interface PausableFiber
public void stop()
stop
in interface Fiber
public long getServiceID(java.lang.String svcname)
svcname
- the service name whose service id is required
public void addServiceMapping(java.lang.String svcname, long serviceid)
public static OutageManager getInstance()
|
OpenNMS API 1.1.3 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |