Class Ec2InstanceAttributes

java.lang.Object
com.amazonaws.services.elasticmapreduce.model.Ec2InstanceAttributes
All Implemented Interfaces:
Serializable, Cloneable

public class Ec2InstanceAttributes extends Object implements Serializable, Cloneable

Provides information about the EC2 instances in a cluster grouped by category. For example, key name, subnet ID, IAM instance profile, and so on.

See Also:
  • Constructor Details

    • Ec2InstanceAttributes

      public Ec2InstanceAttributes()
  • Method Details

    • setEc2KeyName

      public void setEc2KeyName(String ec2KeyName)

      The name of the Amazon EC2 key pair to use when connecting with SSH into the master node as a user named "hadoop".

      Parameters:
      ec2KeyName - The name of the Amazon EC2 key pair to use when connecting with SSH into the master node as a user named "hadoop".
    • getEc2KeyName

      public String getEc2KeyName()

      The name of the Amazon EC2 key pair to use when connecting with SSH into the master node as a user named "hadoop".

      Returns:
      The name of the Amazon EC2 key pair to use when connecting with SSH into the master node as a user named "hadoop".
    • withEc2KeyName

      public Ec2InstanceAttributes withEc2KeyName(String ec2KeyName)

      The name of the Amazon EC2 key pair to use when connecting with SSH into the master node as a user named "hadoop".

      Parameters:
      ec2KeyName - The name of the Amazon EC2 key pair to use when connecting with SSH into the master node as a user named "hadoop".
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setEc2SubnetId

      public void setEc2SubnetId(String ec2SubnetId)

      To launch the job flow in Amazon VPC, set this parameter to the identifier of the Amazon VPC subnet where you want the job flow to launch. If you do not specify this value, the job flow is launched in the normal AWS cloud, outside of a VPC.

      Amazon VPC currently does not support cluster compute quadruple extra large (cc1.4xlarge) instances. Thus, you cannot specify the cc1.4xlarge instance type for nodes of a job flow launched in a VPC.

      Parameters:
      ec2SubnetId - To launch the job flow in Amazon VPC, set this parameter to the identifier of the Amazon VPC subnet where you want the job flow to launch. If you do not specify this value, the job flow is launched in the normal AWS cloud, outside of a VPC.

      Amazon VPC currently does not support cluster compute quadruple extra large (cc1.4xlarge) instances. Thus, you cannot specify the cc1.4xlarge instance type for nodes of a job flow launched in a VPC.

    • getEc2SubnetId

      public String getEc2SubnetId()

      To launch the job flow in Amazon VPC, set this parameter to the identifier of the Amazon VPC subnet where you want the job flow to launch. If you do not specify this value, the job flow is launched in the normal AWS cloud, outside of a VPC.

      Amazon VPC currently does not support cluster compute quadruple extra large (cc1.4xlarge) instances. Thus, you cannot specify the cc1.4xlarge instance type for nodes of a job flow launched in a VPC.

      Returns:
      To launch the job flow in Amazon VPC, set this parameter to the identifier of the Amazon VPC subnet where you want the job flow to launch. If you do not specify this value, the job flow is launched in the normal AWS cloud, outside of a VPC.

      Amazon VPC currently does not support cluster compute quadruple extra large (cc1.4xlarge) instances. Thus, you cannot specify the cc1.4xlarge instance type for nodes of a job flow launched in a VPC.

    • withEc2SubnetId

      public Ec2InstanceAttributes withEc2SubnetId(String ec2SubnetId)

      To launch the job flow in Amazon VPC, set this parameter to the identifier of the Amazon VPC subnet where you want the job flow to launch. If you do not specify this value, the job flow is launched in the normal AWS cloud, outside of a VPC.

      Amazon VPC currently does not support cluster compute quadruple extra large (cc1.4xlarge) instances. Thus, you cannot specify the cc1.4xlarge instance type for nodes of a job flow launched in a VPC.

      Parameters:
      ec2SubnetId - To launch the job flow in Amazon VPC, set this parameter to the identifier of the Amazon VPC subnet where you want the job flow to launch. If you do not specify this value, the job flow is launched in the normal AWS cloud, outside of a VPC.

      Amazon VPC currently does not support cluster compute quadruple extra large (cc1.4xlarge) instances. Thus, you cannot specify the cc1.4xlarge instance type for nodes of a job flow launched in a VPC.

      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setEc2AvailabilityZone

      public void setEc2AvailabilityZone(String ec2AvailabilityZone)

      The Availability Zone in which the cluster will run.

      Parameters:
      ec2AvailabilityZone - The Availability Zone in which the cluster will run.
    • getEc2AvailabilityZone

      public String getEc2AvailabilityZone()

      The Availability Zone in which the cluster will run.

      Returns:
      The Availability Zone in which the cluster will run.
    • withEc2AvailabilityZone

      public Ec2InstanceAttributes withEc2AvailabilityZone(String ec2AvailabilityZone)

      The Availability Zone in which the cluster will run.

      Parameters:
      ec2AvailabilityZone - The Availability Zone in which the cluster will run.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setIamInstanceProfile

      public void setIamInstanceProfile(String iamInstanceProfile)

      The IAM role that was specified when the job flow was launched. The EC2 instances of the job flow assume this role.

      Parameters:
      iamInstanceProfile - The IAM role that was specified when the job flow was launched. The EC2 instances of the job flow assume this role.
    • getIamInstanceProfile

      public String getIamInstanceProfile()

      The IAM role that was specified when the job flow was launched. The EC2 instances of the job flow assume this role.

      Returns:
      The IAM role that was specified when the job flow was launched. The EC2 instances of the job flow assume this role.
    • withIamInstanceProfile

      public Ec2InstanceAttributes withIamInstanceProfile(String iamInstanceProfile)

      The IAM role that was specified when the job flow was launched. The EC2 instances of the job flow assume this role.

      Parameters:
      iamInstanceProfile - The IAM role that was specified when the job flow was launched. The EC2 instances of the job flow assume this role.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setEmrManagedMasterSecurityGroup

      public void setEmrManagedMasterSecurityGroup(String emrManagedMasterSecurityGroup)

      The identifier of the Amazon EC2 security group for the master node.

      Parameters:
      emrManagedMasterSecurityGroup - The identifier of the Amazon EC2 security group for the master node.
    • getEmrManagedMasterSecurityGroup

      public String getEmrManagedMasterSecurityGroup()

      The identifier of the Amazon EC2 security group for the master node.

      Returns:
      The identifier of the Amazon EC2 security group for the master node.
    • withEmrManagedMasterSecurityGroup

      public Ec2InstanceAttributes withEmrManagedMasterSecurityGroup(String emrManagedMasterSecurityGroup)

      The identifier of the Amazon EC2 security group for the master node.

      Parameters:
      emrManagedMasterSecurityGroup - The identifier of the Amazon EC2 security group for the master node.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setEmrManagedSlaveSecurityGroup

      public void setEmrManagedSlaveSecurityGroup(String emrManagedSlaveSecurityGroup)

      The identifier of the Amazon EC2 security group for the slave nodes.

      Parameters:
      emrManagedSlaveSecurityGroup - The identifier of the Amazon EC2 security group for the slave nodes.
    • getEmrManagedSlaveSecurityGroup

      public String getEmrManagedSlaveSecurityGroup()

      The identifier of the Amazon EC2 security group for the slave nodes.

      Returns:
      The identifier of the Amazon EC2 security group for the slave nodes.
    • withEmrManagedSlaveSecurityGroup

      public Ec2InstanceAttributes withEmrManagedSlaveSecurityGroup(String emrManagedSlaveSecurityGroup)

      The identifier of the Amazon EC2 security group for the slave nodes.

      Parameters:
      emrManagedSlaveSecurityGroup - The identifier of the Amazon EC2 security group for the slave nodes.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setServiceAccessSecurityGroup

      public void setServiceAccessSecurityGroup(String serviceAccessSecurityGroup)

      The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.

      Parameters:
      serviceAccessSecurityGroup - The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.
    • getServiceAccessSecurityGroup

      public String getServiceAccessSecurityGroup()

      The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.

      Returns:
      The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.
    • withServiceAccessSecurityGroup

      public Ec2InstanceAttributes withServiceAccessSecurityGroup(String serviceAccessSecurityGroup)

      The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.

      Parameters:
      serviceAccessSecurityGroup - The identifier of the Amazon EC2 security group for the Amazon EMR service to access clusters in VPC private subnets.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • getAdditionalMasterSecurityGroups

      public List<String> getAdditionalMasterSecurityGroups()

      A list of additional Amazon EC2 security group IDs for the master node.

      Returns:
      A list of additional Amazon EC2 security group IDs for the master node.
    • setAdditionalMasterSecurityGroups

      public void setAdditionalMasterSecurityGroups(Collection<String> additionalMasterSecurityGroups)

      A list of additional Amazon EC2 security group IDs for the master node.

      Parameters:
      additionalMasterSecurityGroups - A list of additional Amazon EC2 security group IDs for the master node.
    • withAdditionalMasterSecurityGroups

      public Ec2InstanceAttributes withAdditionalMasterSecurityGroups(String... additionalMasterSecurityGroups)

      A list of additional Amazon EC2 security group IDs for the master node.

      NOTE: This method appends the values to the existing list (if any). Use setAdditionalMasterSecurityGroups(java.util.Collection) or withAdditionalMasterSecurityGroups(java.util.Collection) if you want to override the existing values.

      Parameters:
      additionalMasterSecurityGroups - A list of additional Amazon EC2 security group IDs for the master node.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • withAdditionalMasterSecurityGroups

      public Ec2InstanceAttributes withAdditionalMasterSecurityGroups(Collection<String> additionalMasterSecurityGroups)

      A list of additional Amazon EC2 security group IDs for the master node.

      Parameters:
      additionalMasterSecurityGroups - A list of additional Amazon EC2 security group IDs for the master node.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • getAdditionalSlaveSecurityGroups

      public List<String> getAdditionalSlaveSecurityGroups()

      A list of additional Amazon EC2 security group IDs for the slave nodes.

      Returns:
      A list of additional Amazon EC2 security group IDs for the slave nodes.
    • setAdditionalSlaveSecurityGroups

      public void setAdditionalSlaveSecurityGroups(Collection<String> additionalSlaveSecurityGroups)

      A list of additional Amazon EC2 security group IDs for the slave nodes.

      Parameters:
      additionalSlaveSecurityGroups - A list of additional Amazon EC2 security group IDs for the slave nodes.
    • withAdditionalSlaveSecurityGroups

      public Ec2InstanceAttributes withAdditionalSlaveSecurityGroups(String... additionalSlaveSecurityGroups)

      A list of additional Amazon EC2 security group IDs for the slave nodes.

      NOTE: This method appends the values to the existing list (if any). Use setAdditionalSlaveSecurityGroups(java.util.Collection) or withAdditionalSlaveSecurityGroups(java.util.Collection) if you want to override the existing values.

      Parameters:
      additionalSlaveSecurityGroups - A list of additional Amazon EC2 security group IDs for the slave nodes.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • withAdditionalSlaveSecurityGroups

      public Ec2InstanceAttributes withAdditionalSlaveSecurityGroups(Collection<String> additionalSlaveSecurityGroups)

      A list of additional Amazon EC2 security group IDs for the slave nodes.

      Parameters:
      additionalSlaveSecurityGroups - A list of additional Amazon EC2 security group IDs for the slave nodes.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • toString

      public String toString()
      Returns a string representation of this object; useful for testing and debugging.
      Overrides:
      toString in class Object
      Returns:
      A string representation of this object.
      See Also:
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • clone

      public Ec2InstanceAttributes clone()
      Overrides:
      clone in class Object