Kieker 1.5

kieker.monitoring.writer.database
Class SyncDbWriter

java.lang.Object
  extended by kieker.monitoring.writer.AbstractMonitoringWriter
      extended by kieker.monitoring.writer.database.SyncDbWriter
All Implemented Interfaces:
IMonitoringRecordReceiver, IMonitoringWriter

public final class SyncDbWriter
extends AbstractMonitoringWriter

Stores monitoring data into a database. Warning! This class is an academic prototype and not intended for usage in any critical system.

Author:
Jan Waller

Field Summary
static String CONFIG_CONNECTIONSTRING
           
static String CONFIG_DRIVERCLASSNAME
           
static String CONFIG_OVERWRITE
           
static String CONFIG_TABLEPREFIX
           
 
Constructor Summary
SyncDbWriter(Configuration configuration)
           
 
Method Summary
 void init()
          Implementing classes should indicate an initialization error by throwing an Exception.
 boolean newMonitoringRecord(IMonitoringRecord record)
          Called for each new record.
 void terminate()
          Called by the Monitoring Controller to announce a shutdown of monitoring.
 String toString()
           
 
Methods inherited from class kieker.monitoring.writer.AbstractMonitoringWriter
getConfiguration, setController
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

CONFIG_DRIVERCLASSNAME

public static final String CONFIG_DRIVERCLASSNAME

CONFIG_CONNECTIONSTRING

public static final String CONFIG_CONNECTIONSTRING

CONFIG_TABLEPREFIX

public static final String CONFIG_TABLEPREFIX

CONFIG_OVERWRITE

public static final String CONFIG_OVERWRITE
Constructor Detail

SyncDbWriter

public SyncDbWriter(Configuration configuration)
             throws Exception
Throws:
Exception
Method Detail

init

public final void init()
                throws Exception
Description copied from class: AbstractMonitoringWriter
Implementing classes should indicate an initialization error by throwing an Exception.

Throws:
Exception

newMonitoringRecord

public final boolean newMonitoringRecord(IMonitoringRecord record)
Description copied from interface: IMonitoringRecordReceiver
Called for each new record. Notice, that this method should not throw an exception, but indicate an error by the return value false.

Parameters:
record - the record.
Returns:
true on success; false in case of an error.

terminate

public void terminate()
Description copied from interface: IMonitoringWriter
Called by the Monitoring Controller to announce a shutdown of monitoring. Writers should return as soon as it is safe to terminate Kieker.


toString

public String toString()
Specified by:
toString in interface IMonitoringWriter
Overrides:
toString in class AbstractMonitoringWriter

Kieker 1.5

Copyright 2012 the Kieker Project, http://kieker-monitoring.net