public class InstanceGroup
extends java.lang.Object
implements java.io.Serializable, java.lang.Cloneable
This entity represents an instance group, which is a group of instances that have common purpose. For example, CORE instance group is used for HDFS.
Modifier and Type | Field and Description |
---|---|
private java.lang.String |
bidPrice
The bid price for each EC2 instance in the instance group when launching
nodes as Spot Instances, expressed in USD.
|
private SdkInternalList<Configuration> |
configurations
|
private SdkInternalList<EbsBlockDevice> |
ebsBlockDevices
The EBS block devices that are mapped to this instance group.
|
private java.lang.Boolean |
ebsOptimized
If the instance group is EBS-optimized.
|
private java.lang.String |
id
The identifier of the instance group.
|
private java.lang.String |
instanceGroupType
The type of the instance group.
|
private java.lang.String |
instanceType
The EC2 instance type for all instances in the instance group.
|
private java.lang.String |
market
The marketplace to provision instances for this group.
|
private java.lang.String |
name
The name of the instance group.
|
private java.lang.Integer |
requestedInstanceCount
The target number of instances for the instance group.
|
private java.lang.Integer |
runningInstanceCount
The number of instances currently running in this instance group.
|
private ShrinkPolicy |
shrinkPolicy
Policy for customizing shrink operations.
|
private InstanceGroupStatus |
status
The current status of the instance group.
|
Constructor and Description |
---|
InstanceGroup() |
Modifier and Type | Method and Description |
---|---|
InstanceGroup |
clone() |
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getBidPrice()
The bid price for each EC2 instance in the instance group when launching
nodes as Spot Instances, expressed in USD.
|
java.util.List<Configuration> |
getConfigurations()
|
java.util.List<EbsBlockDevice> |
getEbsBlockDevices()
The EBS block devices that are mapped to this instance group.
|
java.lang.Boolean |
getEbsOptimized()
If the instance group is EBS-optimized.
|
java.lang.String |
getId()
The identifier of the instance group.
|
java.lang.String |
getInstanceGroupType()
The type of the instance group.
|
java.lang.String |
getInstanceType()
The EC2 instance type for all instances in the instance group.
|
java.lang.String |
getMarket()
The marketplace to provision instances for this group.
|
java.lang.String |
getName()
The name of the instance group.
|
java.lang.Integer |
getRequestedInstanceCount()
The target number of instances for the instance group.
|
java.lang.Integer |
getRunningInstanceCount()
The number of instances currently running in this instance group.
|
ShrinkPolicy |
getShrinkPolicy()
Policy for customizing shrink operations.
|
InstanceGroupStatus |
getStatus()
The current status of the instance group.
|
int |
hashCode() |
java.lang.Boolean |
isEbsOptimized()
If the instance group is EBS-optimized.
|
void |
setBidPrice(java.lang.String bidPrice)
The bid price for each EC2 instance in the instance group when launching
nodes as Spot Instances, expressed in USD.
|
void |
setConfigurations(java.util.Collection<Configuration> configurations)
|
void |
setEbsBlockDevices(java.util.Collection<EbsBlockDevice> ebsBlockDevices)
The EBS block devices that are mapped to this instance group.
|
void |
setEbsOptimized(java.lang.Boolean ebsOptimized)
If the instance group is EBS-optimized.
|
void |
setId(java.lang.String id)
The identifier of the instance group.
|
void |
setInstanceGroupType(InstanceGroupType instanceGroupType)
The type of the instance group.
|
void |
setInstanceGroupType(java.lang.String instanceGroupType)
The type of the instance group.
|
void |
setInstanceType(java.lang.String instanceType)
The EC2 instance type for all instances in the instance group.
|
void |
setMarket(MarketType market)
The marketplace to provision instances for this group.
|
void |
setMarket(java.lang.String market)
The marketplace to provision instances for this group.
|
void |
setName(java.lang.String name)
The name of the instance group.
|
void |
setRequestedInstanceCount(java.lang.Integer requestedInstanceCount)
The target number of instances for the instance group.
|
void |
setRunningInstanceCount(java.lang.Integer runningInstanceCount)
The number of instances currently running in this instance group.
|
void |
setShrinkPolicy(ShrinkPolicy shrinkPolicy)
Policy for customizing shrink operations.
|
void |
setStatus(InstanceGroupStatus status)
The current status of the instance group.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
InstanceGroup |
withBidPrice(java.lang.String bidPrice)
The bid price for each EC2 instance in the instance group when launching
nodes as Spot Instances, expressed in USD.
|
InstanceGroup |
withConfigurations(java.util.Collection<Configuration> configurations)
|
InstanceGroup |
withConfigurations(Configuration... configurations)
|
InstanceGroup |
withEbsBlockDevices(java.util.Collection<EbsBlockDevice> ebsBlockDevices)
The EBS block devices that are mapped to this instance group.
|
InstanceGroup |
withEbsBlockDevices(EbsBlockDevice... ebsBlockDevices)
The EBS block devices that are mapped to this instance group.
|
InstanceGroup |
withEbsOptimized(java.lang.Boolean ebsOptimized)
If the instance group is EBS-optimized.
|
InstanceGroup |
withId(java.lang.String id)
The identifier of the instance group.
|
InstanceGroup |
withInstanceGroupType(InstanceGroupType instanceGroupType)
The type of the instance group.
|
InstanceGroup |
withInstanceGroupType(java.lang.String instanceGroupType)
The type of the instance group.
|
InstanceGroup |
withInstanceType(java.lang.String instanceType)
The EC2 instance type for all instances in the instance group.
|
InstanceGroup |
withMarket(MarketType market)
The marketplace to provision instances for this group.
|
InstanceGroup |
withMarket(java.lang.String market)
The marketplace to provision instances for this group.
|
InstanceGroup |
withName(java.lang.String name)
The name of the instance group.
|
InstanceGroup |
withRequestedInstanceCount(java.lang.Integer requestedInstanceCount)
The target number of instances for the instance group.
|
InstanceGroup |
withRunningInstanceCount(java.lang.Integer runningInstanceCount)
The number of instances currently running in this instance group.
|
InstanceGroup |
withShrinkPolicy(ShrinkPolicy shrinkPolicy)
Policy for customizing shrink operations.
|
InstanceGroup |
withStatus(InstanceGroupStatus status)
The current status of the instance group.
|
private java.lang.String id
The identifier of the instance group.
private java.lang.String name
The name of the instance group.
private java.lang.String market
The marketplace to provision instances for this group. Valid values are ON_DEMAND or SPOT.
private java.lang.String instanceGroupType
The type of the instance group. Valid values are MASTER, CORE or TASK.
private java.lang.String bidPrice
The bid price for each EC2 instance in the instance group when launching nodes as Spot Instances, expressed in USD.
private java.lang.String instanceType
The EC2 instance type for all instances in the instance group.
private java.lang.Integer requestedInstanceCount
The target number of instances for the instance group.
private java.lang.Integer runningInstanceCount
The number of instances currently running in this instance group.
private InstanceGroupStatus status
The current status of the instance group.
private SdkInternalList<Configuration> configurations
Amazon EMR releases 4.x or later.
The list of configurations supplied for an EMR cluster instance group. You can specify a separate configuration for each instance group (master, core, and task).
private SdkInternalList<EbsBlockDevice> ebsBlockDevices
The EBS block devices that are mapped to this instance group.
private java.lang.Boolean ebsOptimized
If the instance group is EBS-optimized. An Amazon EBS–optimized instance uses an optimized configuration stack and provides additional, dedicated capacity for Amazon EBS I/O.
private ShrinkPolicy shrinkPolicy
Policy for customizing shrink operations.
public void setId(java.lang.String id)
The identifier of the instance group.
id
- The identifier of the instance group.public java.lang.String getId()
The identifier of the instance group.
public InstanceGroup withId(java.lang.String id)
The identifier of the instance group.
id
- The identifier of the instance group.public void setName(java.lang.String name)
The name of the instance group.
name
- The name of the instance group.public java.lang.String getName()
The name of the instance group.
public InstanceGroup withName(java.lang.String name)
The name of the instance group.
name
- The name of the instance group.public void setMarket(java.lang.String market)
The marketplace to provision instances for this group. Valid values are ON_DEMAND or SPOT.
market
- The marketplace to provision instances for this group. Valid
values are ON_DEMAND or SPOT.MarketType
public java.lang.String getMarket()
The marketplace to provision instances for this group. Valid values are ON_DEMAND or SPOT.
MarketType
public InstanceGroup withMarket(java.lang.String market)
The marketplace to provision instances for this group. Valid values are ON_DEMAND or SPOT.
market
- The marketplace to provision instances for this group. Valid
values are ON_DEMAND or SPOT.MarketType
public void setMarket(MarketType market)
The marketplace to provision instances for this group. Valid values are ON_DEMAND or SPOT.
market
- The marketplace to provision instances for this group. Valid
values are ON_DEMAND or SPOT.MarketType
public InstanceGroup withMarket(MarketType market)
The marketplace to provision instances for this group. Valid values are ON_DEMAND or SPOT.
market
- The marketplace to provision instances for this group. Valid
values are ON_DEMAND or SPOT.MarketType
public void setInstanceGroupType(java.lang.String instanceGroupType)
The type of the instance group. Valid values are MASTER, CORE or TASK.
instanceGroupType
- The type of the instance group. Valid values are MASTER, CORE or
TASK.InstanceGroupType
public java.lang.String getInstanceGroupType()
The type of the instance group. Valid values are MASTER, CORE or TASK.
InstanceGroupType
public InstanceGroup withInstanceGroupType(java.lang.String instanceGroupType)
The type of the instance group. Valid values are MASTER, CORE or TASK.
instanceGroupType
- The type of the instance group. Valid values are MASTER, CORE or
TASK.InstanceGroupType
public void setInstanceGroupType(InstanceGroupType instanceGroupType)
The type of the instance group. Valid values are MASTER, CORE or TASK.
instanceGroupType
- The type of the instance group. Valid values are MASTER, CORE or
TASK.InstanceGroupType
public InstanceGroup withInstanceGroupType(InstanceGroupType instanceGroupType)
The type of the instance group. Valid values are MASTER, CORE or TASK.
instanceGroupType
- The type of the instance group. Valid values are MASTER, CORE or
TASK.InstanceGroupType
public void setBidPrice(java.lang.String bidPrice)
The bid price for each EC2 instance in the instance group when launching nodes as Spot Instances, expressed in USD.
bidPrice
- The bid price for each EC2 instance in the instance group when
launching nodes as Spot Instances, expressed in USD.public java.lang.String getBidPrice()
The bid price for each EC2 instance in the instance group when launching nodes as Spot Instances, expressed in USD.
public InstanceGroup withBidPrice(java.lang.String bidPrice)
The bid price for each EC2 instance in the instance group when launching nodes as Spot Instances, expressed in USD.
bidPrice
- The bid price for each EC2 instance in the instance group when
launching nodes as Spot Instances, expressed in USD.public void setInstanceType(java.lang.String instanceType)
The EC2 instance type for all instances in the instance group.
instanceType
- The EC2 instance type for all instances in the instance group.public java.lang.String getInstanceType()
The EC2 instance type for all instances in the instance group.
public InstanceGroup withInstanceType(java.lang.String instanceType)
The EC2 instance type for all instances in the instance group.
instanceType
- The EC2 instance type for all instances in the instance group.public void setRequestedInstanceCount(java.lang.Integer requestedInstanceCount)
The target number of instances for the instance group.
requestedInstanceCount
- The target number of instances for the instance group.public java.lang.Integer getRequestedInstanceCount()
The target number of instances for the instance group.
public InstanceGroup withRequestedInstanceCount(java.lang.Integer requestedInstanceCount)
The target number of instances for the instance group.
requestedInstanceCount
- The target number of instances for the instance group.public void setRunningInstanceCount(java.lang.Integer runningInstanceCount)
The number of instances currently running in this instance group.
runningInstanceCount
- The number of instances currently running in this instance group.public java.lang.Integer getRunningInstanceCount()
The number of instances currently running in this instance group.
public InstanceGroup withRunningInstanceCount(java.lang.Integer runningInstanceCount)
The number of instances currently running in this instance group.
runningInstanceCount
- The number of instances currently running in this instance group.public void setStatus(InstanceGroupStatus status)
The current status of the instance group.
status
- The current status of the instance group.public InstanceGroupStatus getStatus()
The current status of the instance group.
public InstanceGroup withStatus(InstanceGroupStatus status)
The current status of the instance group.
status
- The current status of the instance group.public java.util.List<Configuration> getConfigurations()
Amazon EMR releases 4.x or later.
The list of configurations supplied for an EMR cluster instance group. You can specify a separate configuration for each instance group (master, core, and task).
public void setConfigurations(java.util.Collection<Configuration> configurations)
Amazon EMR releases 4.x or later.
The list of configurations supplied for an EMR cluster instance group. You can specify a separate configuration for each instance group (master, core, and task).
configurations
- Amazon EMR releases 4.x or later.public InstanceGroup withConfigurations(Configuration... configurations)
Amazon EMR releases 4.x or later.
The list of configurations supplied for an EMR cluster instance group. You can specify a separate configuration for each instance group (master, core, and task).
NOTE: This method appends the values to the existing list (if
any). Use setConfigurations(java.util.Collection)
or
withConfigurations(java.util.Collection)
if you want to override
the existing values.
configurations
- Amazon EMR releases 4.x or later.public InstanceGroup withConfigurations(java.util.Collection<Configuration> configurations)
Amazon EMR releases 4.x or later.
The list of configurations supplied for an EMR cluster instance group. You can specify a separate configuration for each instance group (master, core, and task).
configurations
- Amazon EMR releases 4.x or later.public java.util.List<EbsBlockDevice> getEbsBlockDevices()
The EBS block devices that are mapped to this instance group.
public void setEbsBlockDevices(java.util.Collection<EbsBlockDevice> ebsBlockDevices)
The EBS block devices that are mapped to this instance group.
ebsBlockDevices
- The EBS block devices that are mapped to this instance group.public InstanceGroup withEbsBlockDevices(EbsBlockDevice... ebsBlockDevices)
The EBS block devices that are mapped to this instance group.
NOTE: This method appends the values to the existing list (if
any). Use setEbsBlockDevices(java.util.Collection)
or
withEbsBlockDevices(java.util.Collection)
if you want to
override the existing values.
ebsBlockDevices
- The EBS block devices that are mapped to this instance group.public InstanceGroup withEbsBlockDevices(java.util.Collection<EbsBlockDevice> ebsBlockDevices)
The EBS block devices that are mapped to this instance group.
ebsBlockDevices
- The EBS block devices that are mapped to this instance group.public void setEbsOptimized(java.lang.Boolean ebsOptimized)
If the instance group is EBS-optimized. An Amazon EBS–optimized instance uses an optimized configuration stack and provides additional, dedicated capacity for Amazon EBS I/O.
ebsOptimized
- If the instance group is EBS-optimized. An Amazon EBS–optimized
instance uses an optimized configuration stack and provides
additional, dedicated capacity for Amazon EBS I/O.public java.lang.Boolean getEbsOptimized()
If the instance group is EBS-optimized. An Amazon EBS–optimized instance uses an optimized configuration stack and provides additional, dedicated capacity for Amazon EBS I/O.
public InstanceGroup withEbsOptimized(java.lang.Boolean ebsOptimized)
If the instance group is EBS-optimized. An Amazon EBS–optimized instance uses an optimized configuration stack and provides additional, dedicated capacity for Amazon EBS I/O.
ebsOptimized
- If the instance group is EBS-optimized. An Amazon EBS–optimized
instance uses an optimized configuration stack and provides
additional, dedicated capacity for Amazon EBS I/O.public java.lang.Boolean isEbsOptimized()
If the instance group is EBS-optimized. An Amazon EBS–optimized instance uses an optimized configuration stack and provides additional, dedicated capacity for Amazon EBS I/O.
public void setShrinkPolicy(ShrinkPolicy shrinkPolicy)
Policy for customizing shrink operations.
shrinkPolicy
- Policy for customizing shrink operations.public ShrinkPolicy getShrinkPolicy()
Policy for customizing shrink operations.
public InstanceGroup withShrinkPolicy(ShrinkPolicy shrinkPolicy)
Policy for customizing shrink operations.
shrinkPolicy
- Policy for customizing shrink operations.public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public InstanceGroup clone()
clone
in class java.lang.Object