raccoon.tibco.tibrv.hoststatus.db
Class DbWriter

java.lang.Object
  extended by raccoon.tibco.tibrv.hoststatus.db.DbWriter

public class DbWriter
extends java.lang.Object

Writes the statistical data to a database.

Since:
Raccoon v1.0
Version:
$Id:$
Author:
Cedric ROUVRAIS

Constructor Summary
DbWriter(java.sql.Connection pConnection, ILogger pLogger)
          Connects to the database.
 
Method Summary
 IConfig getConfig()
           
 void setConfig(IConfig pConfig)
           
 void unload()
          Method to be invoked when the insertion is finished.
 void update(java.lang.String pService, AdminGuiConfig pGuiConfig)
          Updates the information related to the Admin GUI of Rendezvous.
 void write(java.lang.String pService, AdminGuiConfig pGuiConfig)
          Inserts into the database a new Rendezvous enabled host
 void write(java.lang.String pHostAddress, java.lang.String pConfigKPI, MsgInfo pMsgInfo)
          Writes to the Host Information table the host.
 void write(java.lang.String pConfigKPI, TransportStat pStat)
          Inserts a statistical line into the database.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DbWriter

public DbWriter(java.sql.Connection pConnection,
                ILogger pLogger)
         throws java.sql.SQLException
Connects to the database.

Parameters:
pConnection - the database connection that this writer is to use
Throws:
java.sql.SQLException - if the prepared statement couldn't be created.
Method Detail

getConfig

public IConfig getConfig()

setConfig

public void setConfig(IConfig pConfig)

unload

public void unload()
            throws java.sql.SQLException
Method to be invoked when the insertion is finished.

Throws:
java.sql.SQLException - if the clearing fails for some reason.

write

public void write(java.lang.String pConfigKPI,
                  TransportStat pStat)
           throws RaccoonException
Inserts a statistical line into the database.

Parameters:
pConfigKPI - the KPI Configuration used.
pStat - the transport statistics.
Throws:
RaccoonException - if the element couldn't be inserted into the database.

write

public void write(java.lang.String pService,
                  AdminGuiConfig pGuiConfig)
Inserts into the database a new Rendezvous enabled host

Parameters:
pService - the Rendezvous service
pGuiConfig - the information related to th

update

public void update(java.lang.String pService,
                   AdminGuiConfig pGuiConfig)
Updates the information related to the Admin GUI of Rendezvous.

Parameters:
pService - the Rendezvous service
pGuiConfig - the information related to th

write

public void write(java.lang.String pHostAddress,
                  java.lang.String pConfigKPI,
                  MsgInfo pMsgInfo)
Writes to the Host Information table the host.

Parameters:
pHostAddress - the host address
pConfigKPI - the Rv configuration that provided this information.
pMsgInfo - the message information KPI, used for the Operatiing System.


Copyright null null. All Rights Reserved.