com.amazonaws.services.elasticloadbalancing.model
Class CreateLoadBalancerRequest

java.lang.Object
  extended by com.amazonaws.AmazonWebServiceRequest
      extended by com.amazonaws.services.elasticloadbalancing.model.CreateLoadBalancerRequest

public class CreateLoadBalancerRequest
extends AmazonWebServiceRequest

Container for the parameters to the CreateLoadBalancer operation.

Creates a new LoadBalancer.

After the call has completed successfully, a new LoadBalancer is created; however, it will not be usable until at least one instance has been registered. When the LoadBalancer creation is completed, the client can check whether or not it is usable by using the DescribeInstanceHealth API. The LoadBalancer is usable as soon as any registered instance is InService .

NOTE: Currently, the client's quota of LoadBalancers is limited to ten per Region.

NOTE: LoadBalancer DNS names vary depending on the Region they're created in. For LoadBalancers created in the United States, the DNS name ends with: us-east-1.elb.amazonaws.com (for the US Standard Region) us-west-1.elb.amazonaws.com (for the Northern California Region) For LoadBalancers created in the EU (Ireland) Region, the DNS name ends with: eu-west-1.elb.amazonaws.com

See Also:
AmazonElasticLoadBalancing.createLoadBalancer(CreateLoadBalancerRequest)

Constructor Summary
CreateLoadBalancerRequest()
          Default constructor for a new CreateLoadBalancerRequest object.
CreateLoadBalancerRequest(String loadBalancerName)
          Constructs a new CreateLoadBalancerRequest object.
CreateLoadBalancerRequest(String loadBalancerName, List<Listener> listeners, List<String> availabilityZones)
          Constructs a new CreateLoadBalancerRequest object.
 
Method Summary
 boolean equals(Object obj)
           
 List<String> getAvailabilityZones()
          A list of Availability Zones.
 List<Listener> getListeners()
          A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.
 String getLoadBalancerName()
          The name associated with the LoadBalancer.
 String getScheme()
          The type of a LoadBalancer.
 List<String> getSecurityGroups()
          The security groups assigned to your LoadBalancer within your VPC.
 List<String> getSubnets()
          A list of subnet IDs in your VPC to attach to your LoadBalancer.
 int hashCode()
           
 void setAvailabilityZones(Collection<String> availabilityZones)
          A list of Availability Zones.
 void setListeners(Collection<Listener> listeners)
          A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.
 void setLoadBalancerName(String loadBalancerName)
          The name associated with the LoadBalancer.
 void setScheme(String scheme)
          The type of a LoadBalancer.
 void setSecurityGroups(Collection<String> securityGroups)
          The security groups assigned to your LoadBalancer within your VPC.
 void setSubnets(Collection<String> subnets)
          A list of subnet IDs in your VPC to attach to your LoadBalancer.
 String toString()
          Returns a string representation of this object; useful for testing and debugging.
 CreateLoadBalancerRequest withAvailabilityZones(Collection<String> availabilityZones)
          A list of Availability Zones.
 CreateLoadBalancerRequest withAvailabilityZones(String... availabilityZones)
          A list of Availability Zones.
 CreateLoadBalancerRequest withListeners(Collection<Listener> listeners)
          A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.
 CreateLoadBalancerRequest withListeners(Listener... listeners)
          A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.
 CreateLoadBalancerRequest withLoadBalancerName(String loadBalancerName)
          The name associated with the LoadBalancer.
 CreateLoadBalancerRequest withScheme(String scheme)
          The type of a LoadBalancer.
 CreateLoadBalancerRequest withSecurityGroups(Collection<String> securityGroups)
          The security groups assigned to your LoadBalancer within your VPC.
 CreateLoadBalancerRequest withSecurityGroups(String... securityGroups)
          The security groups assigned to your LoadBalancer within your VPC.
 CreateLoadBalancerRequest withSubnets(Collection<String> subnets)
          A list of subnet IDs in your VPC to attach to your LoadBalancer.
 CreateLoadBalancerRequest withSubnets(String... subnets)
          A list of subnet IDs in your VPC to attach to your LoadBalancer.
 
Methods inherited from class com.amazonaws.AmazonWebServiceRequest
copyPrivateRequestParameters, getDelegationToken, getRequestClientOptions, getRequestCredentials, setDelegationToken, setRequestCredentials
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CreateLoadBalancerRequest

public CreateLoadBalancerRequest()
Default constructor for a new CreateLoadBalancerRequest object. Callers should use the setter or fluent setter (with...) methods to initialize this object after creating it.


CreateLoadBalancerRequest

public CreateLoadBalancerRequest(String loadBalancerName)
Constructs a new CreateLoadBalancerRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.

Parameters:
loadBalancerName - The name associated with the LoadBalancer. The name must be unique within your set of LoadBalancers.

CreateLoadBalancerRequest

public CreateLoadBalancerRequest(String loadBalancerName,
                                 List<Listener> listeners,
                                 List<String> availabilityZones)
Constructs a new CreateLoadBalancerRequest object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.

Parameters:
loadBalancerName - The name associated with the LoadBalancer. The name must be unique within your set of LoadBalancers.
listeners - A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.
availabilityZones - A list of Availability Zones.

At least one Availability Zone must be specified. Specified Availability Zones must be in the same EC2 Region as the LoadBalancer. Traffic will be equally distributed across all zones.

This list can be modified after the creation of the LoadBalancer.

Method Detail

getLoadBalancerName

public String getLoadBalancerName()
The name associated with the LoadBalancer. The name must be unique within your set of LoadBalancers.

Returns:
The name associated with the LoadBalancer. The name must be unique within your set of LoadBalancers.

setLoadBalancerName

public void setLoadBalancerName(String loadBalancerName)
The name associated with the LoadBalancer. The name must be unique within your set of LoadBalancers.

Parameters:
loadBalancerName - The name associated with the LoadBalancer. The name must be unique within your set of LoadBalancers.

withLoadBalancerName

public CreateLoadBalancerRequest withLoadBalancerName(String loadBalancerName)
The name associated with the LoadBalancer. The name must be unique within your set of LoadBalancers.

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

Parameters:
loadBalancerName - The name associated with the LoadBalancer. The name must be unique within your set of LoadBalancers.
Returns:
A reference to this updated object so that method calls can be chained together.

getListeners

public List<Listener> getListeners()
A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.

Returns:
A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.

setListeners

public void setListeners(Collection<Listener> listeners)
A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.

Parameters:
listeners - A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.

withListeners

public CreateLoadBalancerRequest withListeners(Listener... listeners)
A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.

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

Parameters:
listeners - A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.
Returns:
A reference to this updated object so that method calls can be chained together.

withListeners

public CreateLoadBalancerRequest withListeners(Collection<Listener> listeners)
A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.

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

Parameters:
listeners - A list of the following tuples: LoadBalancerPort, InstancePort, and Protocol.
Returns:
A reference to this updated object so that method calls can be chained together.

getAvailabilityZones

public List<String> getAvailabilityZones()
A list of Availability Zones.

At least one Availability Zone must be specified. Specified Availability Zones must be in the same EC2 Region as the LoadBalancer. Traffic will be equally distributed across all zones.

This list can be modified after the creation of the LoadBalancer.

Returns:
A list of Availability Zones.

At least one Availability Zone must be specified. Specified Availability Zones must be in the same EC2 Region as the LoadBalancer. Traffic will be equally distributed across all zones.

This list can be modified after the creation of the LoadBalancer.


setAvailabilityZones

public void setAvailabilityZones(Collection<String> availabilityZones)
A list of Availability Zones.

At least one Availability Zone must be specified. Specified Availability Zones must be in the same EC2 Region as the LoadBalancer. Traffic will be equally distributed across all zones.

This list can be modified after the creation of the LoadBalancer.

Parameters:
availabilityZones - A list of Availability Zones.

At least one Availability Zone must be specified. Specified Availability Zones must be in the same EC2 Region as the LoadBalancer. Traffic will be equally distributed across all zones.

This list can be modified after the creation of the LoadBalancer.


withAvailabilityZones

public CreateLoadBalancerRequest withAvailabilityZones(String... availabilityZones)
A list of Availability Zones.

At least one Availability Zone must be specified. Specified Availability Zones must be in the same EC2 Region as the LoadBalancer. Traffic will be equally distributed across all zones.

This list can be modified after the creation of the LoadBalancer.

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

Parameters:
availabilityZones - A list of Availability Zones.

At least one Availability Zone must be specified. Specified Availability Zones must be in the same EC2 Region as the LoadBalancer. Traffic will be equally distributed across all zones.

This list can be modified after the creation of the LoadBalancer.

Returns:
A reference to this updated object so that method calls can be chained together.

withAvailabilityZones

public CreateLoadBalancerRequest withAvailabilityZones(Collection<String> availabilityZones)
A list of Availability Zones.

At least one Availability Zone must be specified. Specified Availability Zones must be in the same EC2 Region as the LoadBalancer. Traffic will be equally distributed across all zones.

This list can be modified after the creation of the LoadBalancer.

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

Parameters:
availabilityZones - A list of Availability Zones.

At least one Availability Zone must be specified. Specified Availability Zones must be in the same EC2 Region as the LoadBalancer. Traffic will be equally distributed across all zones.

This list can be modified after the creation of the LoadBalancer.

Returns:
A reference to this updated object so that method calls can be chained together.

getSubnets

public List<String> getSubnets()
A list of subnet IDs in your VPC to attach to your LoadBalancer.

Returns:
A list of subnet IDs in your VPC to attach to your LoadBalancer.

setSubnets

public void setSubnets(Collection<String> subnets)
A list of subnet IDs in your VPC to attach to your LoadBalancer.

Parameters:
subnets - A list of subnet IDs in your VPC to attach to your LoadBalancer.

withSubnets

public CreateLoadBalancerRequest withSubnets(String... subnets)
A list of subnet IDs in your VPC to attach to your LoadBalancer.

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

Parameters:
subnets - A list of subnet IDs in your VPC to attach to your LoadBalancer.
Returns:
A reference to this updated object so that method calls can be chained together.

withSubnets

public CreateLoadBalancerRequest withSubnets(Collection<String> subnets)
A list of subnet IDs in your VPC to attach to your LoadBalancer.

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

Parameters:
subnets - A list of subnet IDs in your VPC to attach to your LoadBalancer.
Returns:
A reference to this updated object so that method calls can be chained together.

getSecurityGroups

public List<String> getSecurityGroups()
The security groups assigned to your LoadBalancer within your VPC.

Returns:
The security groups assigned to your LoadBalancer within your VPC.

setSecurityGroups

public void setSecurityGroups(Collection<String> securityGroups)
The security groups assigned to your LoadBalancer within your VPC.

Parameters:
securityGroups - The security groups assigned to your LoadBalancer within your VPC.

withSecurityGroups

public CreateLoadBalancerRequest withSecurityGroups(String... securityGroups)
The security groups assigned to your LoadBalancer within your VPC.

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

Parameters:
securityGroups - The security groups assigned to your LoadBalancer within your VPC.
Returns:
A reference to this updated object so that method calls can be chained together.

withSecurityGroups

public CreateLoadBalancerRequest withSecurityGroups(Collection<String> securityGroups)
The security groups assigned to your LoadBalancer within your VPC.

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

Parameters:
securityGroups - The security groups assigned to your LoadBalancer within your VPC.
Returns:
A reference to this updated object so that method calls can be chained together.

getScheme

public String getScheme()
The type of a LoadBalancer. This option is only available for LoadBalancers attached to a Amazon VPC. By default, Elastic Load Balancer creates an internet-facing load balancer with publicly resolvable DNS name that resolves to public IP addresses. Specify the value internal for this option to create an internal load balancer with a DNS name that resolves to private IP addresses.

Returns:
The type of a LoadBalancer. This option is only available for LoadBalancers attached to a Amazon VPC. By default, Elastic Load Balancer creates an internet-facing load balancer with publicly resolvable DNS name that resolves to public IP addresses. Specify the value internal for this option to create an internal load balancer with a DNS name that resolves to private IP addresses.

setScheme

public void setScheme(String scheme)
The type of a LoadBalancer. This option is only available for LoadBalancers attached to a Amazon VPC. By default, Elastic Load Balancer creates an internet-facing load balancer with publicly resolvable DNS name that resolves to public IP addresses. Specify the value internal for this option to create an internal load balancer with a DNS name that resolves to private IP addresses.

Parameters:
scheme - The type of a LoadBalancer. This option is only available for LoadBalancers attached to a Amazon VPC. By default, Elastic Load Balancer creates an internet-facing load balancer with publicly resolvable DNS name that resolves to public IP addresses. Specify the value internal for this option to create an internal load balancer with a DNS name that resolves to private IP addresses.

withScheme

public CreateLoadBalancerRequest withScheme(String scheme)
The type of a LoadBalancer. This option is only available for LoadBalancers attached to a Amazon VPC. By default, Elastic Load Balancer creates an internet-facing load balancer with publicly resolvable DNS name that resolves to public IP addresses. Specify the value internal for this option to create an internal load balancer with a DNS name that resolves to private IP addresses.

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

Parameters:
scheme - The type of a LoadBalancer. This option is only available for LoadBalancers attached to a Amazon VPC. By default, Elastic Load Balancer creates an internet-facing load balancer with publicly resolvable DNS name that resolves to public IP addresses. Specify the value internal for this option to create an internal load balancer with a DNS name that resolves to private IP addresses.
Returns:
A reference to this updated 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:
Object.toString()

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

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


Copyright © 2010 Amazon Web Services, Inc. All Rights Reserved.