Package org.openspaces.admin.vm
Interface VirtualMachineStatistics
- All Known Implementing Classes:
DefaultVirtualMachineStatistics
public interface VirtualMachineStatistics
Statistics on a single virtual machine level.
- Author:
- kimchy
-
Method Summary
Modifier and TypeMethodDescriptionlongReturns a timestamp that is in sync with where the admin API is running.doubleReturns the cpu percentage this virtual machine is using.doublegetCpuPercAverage(long requestedTotalTime, TimeUnit timeUnit) Calculates the average number of cpu cores used by the java virtual machine over the specified period of time.Returns the details of the virtual machine.longReturns the total number of times GC was invoked for this virtual machinedoubleThe percentage of the gc collection time between the current sampled statistics and the previous one.longReturns the total time in milliseconds that this virtual machine spent doing GClongdoubledoubledoubleReturns the memory heap percentage from used to committed.longdoubledoubledoubleReturns the memory heap percentage from used to the max.longdoubledoubledoubleReturns the memory non heap percentage from used to committed.longdoubledoubledoubleReturns the memory non heap percentage from used to the max.intReturns the maximum number of of threads that were running in the VM since it has startedReturns the previous statistics sampled.longReturns the previous timestamp of the statistics sampled,-1if this is the first one.intReturns the number of currently running threads in this virtual machineReturns the timeline (from newest to oldest) history statistics, including this one.longReturn the timestamp when the statistics were taken.longbooleanisNA()Returnstrueif this is not valid statistics.
-
Method Details
-
isNA
boolean isNA()Returnstrueif this is not valid statistics. -
getDetails
VirtualMachineDetails getDetails()Returns the details of the virtual machine. -
getTimeline
List<VirtualMachineStatistics> getTimeline()Returns the timeline (from newest to oldest) history statistics, including this one. -
getPrevious
VirtualMachineStatistics getPrevious()Returns the previous statistics sampled.nullif this is the first one or bounded by the history size. -
getPreviousTimestamp
long getPreviousTimestamp()Returns the previous timestamp of the statistics sampled,-1if this is the first one. -
getTimestamp
long getTimestamp()Return the timestamp when the statistics were taken. -
getAdminTimestamp
long getAdminTimestamp()Returns a timestamp that is in sync with where the admin API is running. Can return -1 if the clocks have are not sync yet. -
getUptime
long getUptime() -
getMemoryHeapCommittedInBytes
long getMemoryHeapCommittedInBytes() -
getMemoryHeapCommittedInMB
double getMemoryHeapCommittedInMB() -
getMemoryHeapCommittedInGB
double getMemoryHeapCommittedInGB() -
getMemoryHeapUsedInBytes
long getMemoryHeapUsedInBytes() -
getMemoryHeapUsedInMB
double getMemoryHeapUsedInMB() -
getMemoryHeapUsedInGB
double getMemoryHeapUsedInGB() -
getMemoryHeapUsedPerc
double getMemoryHeapUsedPerc()Returns the memory heap percentage from used to the max. -
getMemoryHeapCommittedUsedPerc
double getMemoryHeapCommittedUsedPerc()Returns the memory heap percentage from used to committed. -
getMemoryNonHeapCommittedInBytes
long getMemoryNonHeapCommittedInBytes() -
getMemoryNonHeapCommittedInMB
double getMemoryNonHeapCommittedInMB() -
getMemoryNonHeapCommittedInGB
double getMemoryNonHeapCommittedInGB() -
getMemoryNonHeapUsedInBytes
long getMemoryNonHeapUsedInBytes() -
getMemoryNonHeapUsedInMB
double getMemoryNonHeapUsedInMB() -
getMemoryNonHeapUsedInGB
double getMemoryNonHeapUsedInGB() -
getMemoryNonHeapUsedPerc
double getMemoryNonHeapUsedPerc()Returns the memory non heap percentage from used to the max. -
getMemoryNonHeapCommittedUsedPerc
double getMemoryNonHeapCommittedUsedPerc()Returns the memory non heap percentage from used to committed. -
getThreadCount
int getThreadCount()Returns the number of currently running threads in this virtual machine -
getPeakThreadCount
int getPeakThreadCount()Returns the maximum number of of threads that were running in the VM since it has started -
getGcCollectionCount
long getGcCollectionCount()Returns the total number of times GC was invoked for this virtual machine -
getGcCollectionTime
long getGcCollectionTime()Returns the total time in milliseconds that this virtual machine spent doing GC -
getGcCollectionPerc
double getGcCollectionPerc()The percentage of the gc collection time between the current sampled statistics and the previous one. If there is no previous one, will return -1. -
getCpuPerc
double getCpuPerc()Returns the cpu percentage this virtual machine is using. -
getCpuPercFormatted
String getCpuPercFormatted() -
getCpuPercAverage
Calculates the average number of cpu cores used by the java virtual machine over the specified period of time. If not enough statistics have been accumulated, -1 is returned. In that case either call this method again after enough time has elapsed, or increase history sizeStatisticsMonitor.setStatisticsHistorySize(int)or increase statistics intervalStatisticsMonitor.setStatisticsInterval(long, TimeUnit).- Parameters:
requestedTotalTime- The period of time to average the cpu percentage starting with this statisticstimeUnit- Time units for totalTime- Returns:
- A value between 0 and number of CPU cores representing the average number of CPU cores used, or -1 if not enough statistics have been accumulated.
- Since:
- 8.0.3
-