Class OAbstractProfiler
java.lang.Object
com.orientechnologies.common.concur.resource.OSharedResourceAbstract
com.orientechnologies.common.profiler.OAbstractProfiler
- All Implemented Interfaces:
OProfiler,OProfilerMXBean,OService,OOrientStartupListener
- Direct Known Subclasses:
OEnterpriseProfiler,OProfilerStub
public abstract class OAbstractProfiler
extends OSharedResourceAbstract
implements OProfiler, OOrientStartupListener, OProfilerMXBean
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassclassstatic interfaceNested classes/interfaces inherited from interface com.orientechnologies.common.profiler.OProfiler
OProfiler.METRIC_TYPE -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected TimerTaskprotected final ConcurrentHashMap<String,String> protected final Map<String,OAbstractProfiler.OProfilerHookRuntime> protected List<OProfilerListener>protected longprotected final ConcurrentHashMap<String,OProfiler.METRIC_TYPE> Fields inherited from class com.orientechnologies.common.concur.resource.OSharedResourceAbstract
lock -
Constructor Summary
ConstructorsConstructorDescriptionOAbstractProfiler(boolean registerListener) OAbstractProfiler(OAbstractProfiler profiler) -
Method Summary
Modifier and TypeMethodDescriptiondump()voiddump(PrintStream out) static StringdumpEnvironment(String dumpType) String[]String[]getDatabaseMetric(String iDatabaseName, String iMetricName) String[]getName()getProcessMetric(String iMetricName) getSystemMetric(String iMetricName) protected abstract AtomicIntegerprotected voidbooleanvoidvoidregisterHookValue(String iName, String iDescription, OProfiler.METRIC_TYPE iType, OAbstractProfiler.OProfilerHookValue iHookValue) voidregisterHookValue(String iName, String iDescription, OProfiler.METRIC_TYPE iType, OAbstractProfiler.OProfilerHookValue iHookValue, String iMetadataName) voidregisterListener(OProfilerListener listener) intvoidsetAutoDump(int iSeconds) protected abstract voidsetTip(String iMessage, AtomicInteger counter) voidshutdown()longbooleanvoidstartup()longstopChrono(String iName, String iDescription, long iStartTime) longstopChrono(String iName, String iDescription, long iStartTime, String iDictionary) booleanvoidunregisterHookValue(String iName) voidunregisterListener(OProfilerListener listener) voidupdateCounter(String iStatName, String iDescription, long iPlus) protected voidupdateMetadata(String iName, String iDescription, OProfiler.METRIC_TYPE iType) Updates the metric metadata.Methods inherited from class com.orientechnologies.common.concur.resource.OSharedResourceAbstract
acquireExclusiveLock, acquireSharedLock, releaseExclusiveLock, releaseSharedLockMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.orientechnologies.common.profiler.OProfiler
configure, getChronos, getContext, getCounter, getHookValue, getStatsAsJson, isEnterpriseEdition, resetRealtime, stopChrono, stopChrono, updateCounterMethods inherited from interface com.orientechnologies.common.profiler.OProfilerMXBean
getCounter, resetRealtime
-
Field Details
-
hooks
-
dictionary
-
types
-
recordingFrom
protected long recordingFrom -
autoDumpTask
-
listeners
-
-
Constructor Details
-
OAbstractProfiler
public OAbstractProfiler() -
OAbstractProfiler
public OAbstractProfiler(boolean registerListener) -
OAbstractProfiler
-
-
Method Details
-
setTip
-
getTip
-
dumpEnvironment
-
onStartup
public void onStartup()- Specified by:
onStartupin interfaceOOrientStartupListener
-
shutdown
public void shutdown() -
reportTip
-
startRecording
public boolean startRecording()- Specified by:
startRecordingin interfaceOProfiler- Specified by:
startRecordingin interfaceOProfilerMXBean
-
stopRecording
public boolean stopRecording()- Specified by:
stopRecordingin interfaceOProfiler- Specified by:
stopRecordingin interfaceOProfilerMXBean
-
isRecording
public boolean isRecording()- Specified by:
isRecordingin interfaceOProfiler- Specified by:
isRecordingin interfaceOProfilerMXBean
-
updateCounter
- Specified by:
updateCounterin interfaceOProfiler
-
getName
-
startup
public void startup() -
dump
- Specified by:
dumpin interfaceOProfiler- Specified by:
dumpin interfaceOProfilerMXBean
-
dump
-
dump
-
dumpCounters
- Specified by:
dumpCountersin interfaceOProfiler- Specified by:
dumpCountersin interfaceOProfilerMXBean
-
getChrono
-
startChrono
public long startChrono()- Specified by:
startChronoin interfaceOProfiler
-
stopChrono
- Specified by:
stopChronoin interfaceOProfiler
-
stopChrono
- Specified by:
stopChronoin interfaceOProfiler
-
dumpChronos
- Specified by:
dumpChronosin interfaceOProfiler- Specified by:
dumpChronosin interfaceOProfilerMXBean
-
getCountersAsString
- Specified by:
getCountersAsStringin interfaceOProfiler- Specified by:
getCountersAsStringin interfaceOProfilerMXBean
-
getChronosAsString
- Specified by:
getChronosAsStringin interfaceOProfilerMXBean
-
getLastReset
- Specified by:
getLastResetin interfaceOProfiler- Specified by:
getLastResetin interfaceOProfilerMXBean
-
setAutoDump
public void setAutoDump(int iSeconds) - Specified by:
setAutoDumpin interfaceOProfiler- Specified by:
setAutoDumpin interfaceOProfilerMXBean
-
metadataToJSON
- Specified by:
metadataToJSONin interfaceOProfiler- Specified by:
metadataToJSONin interfaceOProfilerMXBean
-
getMetadata
- Specified by:
getMetadatain interfaceOProfiler
-
getHookAsString
- Specified by:
getHookAsStringin interfaceOProfiler
-
registerHookValue
public void registerHookValue(String iName, String iDescription, OProfiler.METRIC_TYPE iType, OAbstractProfiler.OProfilerHookValue iHookValue) - Specified by:
registerHookValuein interfaceOProfiler
-
registerHookValue
public void registerHookValue(String iName, String iDescription, OProfiler.METRIC_TYPE iType, OAbstractProfiler.OProfilerHookValue iHookValue, String iMetadataName) - Specified by:
registerHookValuein interfaceOProfiler
-
unregisterHookValue
- Specified by:
unregisterHookValuein interfaceOProfiler
-
getSystemMetric
- Specified by:
getSystemMetricin interfaceOProfiler- Specified by:
getSystemMetricin interfaceOProfilerMXBean
-
getProcessMetric
- Specified by:
getProcessMetricin interfaceOProfiler- Specified by:
getProcessMetricin interfaceOProfilerMXBean
-
getDatabaseMetric
- Specified by:
getDatabaseMetricin interfaceOProfiler- Specified by:
getDatabaseMetricin interfaceOProfilerMXBean
-
toJSON
-
installMemoryChecker
protected void installMemoryChecker() -
updateMetadata
Updates the metric metadata. -
registerListener
- Specified by:
registerListenerin interfaceOProfiler
-
unregisterListener
- Specified by:
unregisterListenerin interfaceOProfiler
-
threadDump
- Specified by:
threadDumpin interfaceOProfiler
-
getType
-