delete_load_balancer ( $load_balancer_name, $opt )

Deletes the specified LoadBalancer.

If attempting to recreate the LoadBalancer, the client must reconfigure all the settings. The DNS name associated with a deleted LoadBalancer will no longer be usable. Once deleted, the name and associated DNS record of the LoadBalancer no longer exist and traffic sent to any of its IP addresses will no longer be delivered to client instances. The client will not receive the same DNS name even if a new LoadBalancer with same LoadBalancerName is created.

To successfully call this API, the client must provide the same account credentials as were used to create the LoadBalancer.

By design, if the LoadBalancer does not exist or has already been deleted, DeleteLoadBalancer still succeeds.

Access

public

Parameters

Parameter

Type

Required

Description

$load_balancer_name

string

Required

The name associated with the LoadBalancer. The name must be unique within the client AWS account.

$opt

array

Optional

An associative array of parameters that can have the following keys:

  • curlopts - array - Optional - A set of values to pass directly into curl_setopt(), where the key is a pre-defined CURLOPT_* constant.
  • returnCurlHandle - boolean - Optional - A private toggle specifying that the cURL handle be returned rather than actually completing the request. This toggle is useful for manually managed batch requests.

Returns

Type

Description

CFResponse

A CFResponse object containing a parsed HTTP response.

Examples

Delete a load balancer.

$elb = new AmazonELB();

$response = $elb->delete_load_balancer('my-load-balancer');
$response = $elb->delete_load_balancer('my-load-balancer2');

// Success?
var_dump($response->isOK());
Result:
bool(true)

Related Methods

Source

Method defined in services/elb.class.php | Toggle source view (7 lines) | View on GitHub

public function delete_load_balancer($load_balancer_name, $opt = null)
{
    if (!$opt) $opt = array();
    $opt['LoadBalancerName'] = $load_balancer_name;
    
    return $this->authenticate('DeleteLoadBalancer', $opt);
}

Copyright © 2010–2013 Amazon Web Services, LLC


Feedback