Package org.elasticsearch.monitor.os
Class OsStats.Cgroup.CpuStat
- java.lang.Object
-
- org.elasticsearch.monitor.os.OsStats.Cgroup.CpuStat
-
- All Implemented Interfaces:
Writeable
,ToXContent
,ToXContentFragment
- Enclosing class:
- OsStats.Cgroup
public static class OsStats.Cgroup.CpuStat extends java.lang.Object implements Writeable, ToXContentFragment
Encapsulates CPU time statistics.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
-
Field Summary
-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Constructor Summary
Constructors Constructor Description CpuStat(long numberOfElapsedPeriods, long numberOfTimesThrottled, long timeThrottledNanos)
-
Method Summary
Modifier and Type Method Description long
getNumberOfElapsedPeriods()
The number of elapsed periods.long
getNumberOfTimesThrottled()
The number of times tasks in the control group have been throttled.long
getTimeThrottledNanos()
The total time duration for which tasks in the control group have been throttled.XContentBuilder
toXContent(XContentBuilder builder, ToXContent.Params params)
void
writeTo(StreamOutput out)
Write this into the StreamOutput.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentFragment
isFragment
-
-
-
-
Method Detail
-
getNumberOfElapsedPeriods
public long getNumberOfElapsedPeriods()
The number of elapsed periods.- Returns:
- the number of elapsed periods as measured by
cpu.cfs_period_us
-
getNumberOfTimesThrottled
public long getNumberOfTimesThrottled()
The number of times tasks in the control group have been throttled.- Returns:
- the number of times
-
getTimeThrottledNanos
public long getTimeThrottledNanos()
The total time duration for which tasks in the control group have been throttled.- Returns:
- the total time in nanoseconds
-
writeTo
public void writeTo(StreamOutput out) throws java.io.IOException
Description copied from interface:Writeable
Write this into the StreamOutput.
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws java.io.IOException
- Specified by:
toXContent
in interfaceToXContent
- Throws:
java.io.IOException
-
-