org.apache.cassandra.analytics
Class DBAnalyticsSource

java.lang.Object
  extended by org.apache.cassandra.analytics.DBAnalyticsSource
All Implemented Interfaces:
IAnalyticsSource

public class DBAnalyticsSource
extends java.lang.Object
implements IAnalyticsSource

This class sets up the analytics package to report metrics into Ganglia for the various DB operations such as: reads per second, average read latency, writes per second, average write latency. Author : Avinash Lakshman ( alakshman@facebook.com) & Prashant Malik ( pmalik@facebook.com ) & Karthik Ranganathan ( kranganathan@facebook.com )


Constructor Summary
DBAnalyticsSource()
          Create all the required records we intend to display, and register with the AnalyticsContext.
 
Method Summary
 void doUpdates(AnalyticsContext context)
          Update each of the records with the relevant data
 void updateReadStatistics(long latency)
          Update the read statistics.
 void updateWriteStatistics(long latency)
          Update the write statistics.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DBAnalyticsSource

public DBAnalyticsSource()
Create all the required records we intend to display, and register with the AnalyticsContext.

Method Detail

doUpdates

public void doUpdates(AnalyticsContext context)
Update each of the records with the relevant data

Specified by:
doUpdates in interface IAnalyticsSource
Parameters:
context - the reference to the context which has called this callback

updateReadStatistics

public void updateReadStatistics(long latency)
Update the read statistics.


updateWriteStatistics

public void updateWriteStatistics(long latency)
Update the write statistics.



Copyright © 2009 The Apache Software Foundation