Kieker 1.2

kieker.monitoring.core
Class ControlFlowRegistry

java.lang.Object
  extended by kieker.monitoring.core.ControlFlowRegistry

public class ControlFlowRegistry
extends Object

Author:
Andre van Hoorn

Method Summary
 long getAndStoreUniqueThreadLocalTraceId()
          This method returns a thread-local traceid which is globally unique and stored it local for the thread.
static ControlFlowRegistry getInstance()
           
 long getUniqueTraceId()
          This methods returns a globally unique trace id.
 int incrementAndRecallThreadLocalEOI()
          Since this method accesses a ThreadLocal variable, it is not (necessary to be) thread-safe.
 int recallAndIncrementThreadLocalESS()
          Since this method accesses a ThreadLocal variable, it is not (necessary to be) thread-safe.
 int recallThreadLocalEOI()
          This method returns the thread-local curEoi previously registered using the method registerTraceId(curTraceId).
 int recallThreadLocalESS()
          This method returns the thread-local curEss previously registered using the method registerTraceId(curTraceId).
 long recallThreadLocalTraceId()
          This method returns the thread-local traceid previously registered using the method registerTraceId(curTraceId).
 void storeThreadLocalEOI(int eoi)
          Used to explicitly register an curEoi.
 void storeThreadLocalESS(int ess)
          Used to explicitly register a sessionid that is to be collected within a servlet method (that knows the request object).
 void storeThreadLocalTraceId(long traceId)
          This method stores a thread-local curTraceId.
 void unsetThreadLocalEOI()
          This method unsets a previously registered traceid.
 void unsetThreadLocalESS()
          This method unsets a previously registered curEss.
 void unsetThreadLocalTraceId()
          This method unsets a previously registered traceid.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static final ControlFlowRegistry getInstance()

getUniqueTraceId

public final long getUniqueTraceId()
This methods returns a globally unique trace id.

Returns:

getAndStoreUniqueThreadLocalTraceId

public final long getAndStoreUniqueThreadLocalTraceId()
This method returns a thread-local traceid which is globally unique and stored it local for the thread. The thread is responsible for invalidating the stored curTraceId using the method unsetThreadLocalTraceId()!


storeThreadLocalTraceId

public final void storeThreadLocalTraceId(long traceId)
This method stores a thread-local curTraceId. The thread is responsible for invalidating the stored curTraceId using the method unsetThreadLocalTraceId()!


recallThreadLocalTraceId

public final long recallThreadLocalTraceId()
This method returns the thread-local traceid previously registered using the method registerTraceId(curTraceId).

Returns:
the traceid. -1 if no curTraceId has been registered for this thread.

unsetThreadLocalTraceId

public final void unsetThreadLocalTraceId()
This method unsets a previously registered traceid.


storeThreadLocalEOI

public final void storeThreadLocalEOI(int eoi)
Used to explicitly register an curEoi. The thread is responsible for invalidating the stored curTraceId using the method unsetThreadLocalEOI()!


incrementAndRecallThreadLocalEOI

public final int incrementAndRecallThreadLocalEOI()
Since this method accesses a ThreadLocal variable, it is not (necessary to be) thread-safe.


recallThreadLocalEOI

public final int recallThreadLocalEOI()
This method returns the thread-local curEoi previously registered using the method registerTraceId(curTraceId).

Returns:
the sessionid. -1 if no curEoi registered.

unsetThreadLocalEOI

public final void unsetThreadLocalEOI()
This method unsets a previously registered traceid.


storeThreadLocalESS

public final void storeThreadLocalESS(int ess)
Used to explicitly register a sessionid that is to be collected within a servlet method (that knows the request object). The thread is responsible for invalidating the stored curTraceId using the method unsetThreadLocalSessionId()!


recallAndIncrementThreadLocalESS

public final int recallAndIncrementThreadLocalESS()
Since this method accesses a ThreadLocal variable, it is not (necessary to be) thread-safe.


recallThreadLocalESS

public final int recallThreadLocalESS()
This method returns the thread-local curEss previously registered using the method registerTraceId(curTraceId).

Returns:
the sessionid. -1 if no curEss registered.

unsetThreadLocalESS

public final void unsetThreadLocalESS()
This method unsets a previously registered curEss.


Kieker 1.2

Copyright 2010 the Kieker Project, http://kieker.sourceforge.net