Class PoolSizeSummary
- java.lang.Object
-
- com.elastisys.scale.cloudpool.api.types.PoolSizeSummary
-
public class PoolSizeSummary extends java.lang.ObjectResponse message of theCloudPool.getPoolSize()operation that returns information about the pool size -- both desired and actual size.
-
-
Constructor Summary
Constructors Constructor Description PoolSizeSummary(int desiredSize, int allocated, int active)PoolSizeSummary(org.joda.time.DateTime timestamp, int desiredSize, int allocated, int active)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(java.lang.Object obj)intgetActive()The number of active machines in the poolMachine.isActiveMember().intgetAllocated()Returns the number of allocated machines in the pool (seeMachine.isAllocated().intgetDesiredSize()Returns the desired size of the machine pool.org.joda.time.DateTimegetTimestamp()Returns the time at which the pool size observation was made.inthashCode()java.lang.StringtoString()
-
-
-
Constructor Detail
-
PoolSizeSummary
public PoolSizeSummary(int desiredSize, int allocated, int active)- Parameters:
desiredSize- The desired size of the machine pool.allocated- The number of allocated machines in the pool (seeMachine.isAllocated().active- The number of active machines in the poolMachine.isActiveMember(). That is, the number of allocated machines that have also been marked with an active membership status.
-
PoolSizeSummary
public PoolSizeSummary(org.joda.time.DateTime timestamp, int desiredSize, int allocated, int active)
-
-
Method Detail
-
getTimestamp
public org.joda.time.DateTime getTimestamp()
Returns the time at which the pool size observation was made. Note that in case the cloud pool serves locally cached data, this field may be used by the client to determine if the data is fresh enough to be acted upon.- Returns:
-
getDesiredSize
public int getDesiredSize()
Returns the desired size of the machine pool.- Returns:
-
getAllocated
public int getAllocated()
Returns the number of allocated machines in the pool (seeMachine.isAllocated().- Returns:
-
getActive
public int getActive()
The number of active machines in the poolMachine.isActiveMember(). That is, the number of allocated machines that have also been marked with an active membership status.- Returns:
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-