Package io.netty.util.concurrent
Class AutoScalingEventExecutorChooserFactory.AutoScalingUtilizationMetric
- java.lang.Object
-
- io.netty.util.concurrent.AutoScalingEventExecutorChooserFactory.AutoScalingUtilizationMetric
-
- Enclosing class:
- AutoScalingEventExecutorChooserFactory
public static final class AutoScalingEventExecutorChooserFactory.AutoScalingUtilizationMetric extends java.lang.Object
A container for the utilization metric of a single EventExecutor. This object is intended to be created once and have itsutilization
field updated periodically.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description EventExecutor
executor()
Returns theEventExecutor
this metric belongs too.double
utilization()
Returns the most recently calculated utilization for the associated executor.
-
-
-
Method Detail
-
utilization
public double utilization()
Returns the most recently calculated utilization for the associated executor.- Returns:
- a value from 0.0 to 1.0.
-
executor
public EventExecutor executor()
Returns theEventExecutor
this metric belongs too.- Returns:
- the executor.
-
-