Interface ResourceScaling
- All Known Implementing Classes:
ResourceScalingGradual,ResourceScalingInstantaneous
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
A
FunctionalInterface to define how the capacity of the resource to be scaled by
a VerticalVmScaling will be resized,
according to the defined scaling factor.
The interval in which the under and overload conditions are checked
is defined by the Datacenter.getSchedulingInterval().
This way, during one interval and another, there may be some
SLA violation if the resource is overloaded between these intervals.
There are some implementations of this functional interface such as
ResourceScalingGradual and ResourceScalingInstantaneous.
New ones can be defined using Lambda Expressions.
- Since:
- CloudSim 1.2.0
- Author:
- Manoel Campos da Silva Filho
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ResourceScalingAn attribute that implements the Null Object Design Pattern forResourceScalingobjects. -
Method Summary
Modifier and TypeMethodDescriptiondoublegetResourceAmountToScale(VerticalVmScaling vmScaling) Returns the computed amount of resource to scale up or down, depending on if the resource is over or underloaded, respectively.
-
Field Details
-
NULL
An attribute that implements the Null Object Design Pattern forResourceScalingobjects.
-
-
Method Details
-
getResourceAmountToScale
Returns the computed amount of resource to scale up or down, depending on if the resource is over or underloaded, respectively.- Parameters:
vmScaling- theVerticalVmScalingobject that is in charge to scale a resource.- Returns:
- the computed amount of resource to scale up or down, depending on if the resource is over or underloaded, respectively
-