net.wgen.op.logging
Class Snapshot

java.lang.Object
  extended bynet.wgen.op.logging.Snapshot

public class Snapshot
extends java.lang.Object

Aggregator of stats to log every so often for an indication of load.

Version:
$Id: Snapshot.html,v 1.2 2007/01/28 04:09:37 paulfeuer Exp $
Author:
Paul Feuer, Wireless Generation, Inc.

Field Summary
private static long _resetTime
           
private static java.util.Map _snapShotPerApp
           
private  int connectionsUsed
           
private  int databaseTime
           
private  int dbCallsExecuted
           
private  int dbErrorsOccurred
           
private static boolean IS_PROD
           
private static org.apache.log4j.Logger LOG
           
private  java.lang.String moduleName
           
private  int opsExecuted
           
private  int profileRequests
           
private  int reqErrorsOccurred
           
private  int requestsMade
           
private  int requestTime
           
private static long RESET_INTERVAL
           
private  int rowsAccessed
           
static java.text.SimpleDateFormat SDF
           
private  int tempKeysUsed
           
private static int THRESH_CALLS
           
private static int THRESH_CX
           
private static int THRESH_ROWS
           
private static java.util.Timer TIMER
           
private  int traceRequests
           
 
Constructor Summary
Snapshot(java.lang.String appName)
           
 
Method Summary
static void aggregateCall(WebAppStats.DBCallRecord rec)
           
static void aggregateRequest(TraceKey key)
           
private static void dumpSnapshot()
          Internal dump method.
private static Snapshot getSnapshot(java.lang.String appName)
           
 void reset()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_snapShotPerApp

private static final java.util.Map _snapShotPerApp

SDF

public static final java.text.SimpleDateFormat SDF

IS_PROD

private static final boolean IS_PROD

RESET_INTERVAL

private static final long RESET_INTERVAL
See Also:
Constant Field Values

THRESH_ROWS

private static final int THRESH_ROWS

THRESH_CX

private static final int THRESH_CX

THRESH_CALLS

private static final int THRESH_CALLS

_resetTime

private static long _resetTime

TIMER

private static final java.util.Timer TIMER

LOG

private static final org.apache.log4j.Logger LOG

moduleName

private java.lang.String moduleName

rowsAccessed

private int rowsAccessed

opsExecuted

private int opsExecuted

dbCallsExecuted

private int dbCallsExecuted

connectionsUsed

private int connectionsUsed

requestsMade

private int requestsMade

dbErrorsOccurred

private int dbErrorsOccurred

reqErrorsOccurred

private int reqErrorsOccurred

databaseTime

private int databaseTime

requestTime

private int requestTime

traceRequests

private int traceRequests

profileRequests

private int profileRequests

tempKeysUsed

private int tempKeysUsed
Constructor Detail

Snapshot

public Snapshot(java.lang.String appName)
Method Detail

aggregateCall

public static void aggregateCall(WebAppStats.DBCallRecord rec)

aggregateRequest

public static void aggregateRequest(TraceKey key)

reset

public void reset()

toString

public java.lang.String toString()

getSnapshot

private static Snapshot getSnapshot(java.lang.String appName)
Parameters:
appName -
Returns:
the snapshot for the app

dumpSnapshot

private static void dumpSnapshot()
Internal dump method.