modifyLoadBalancerAttributes

Modifies the attributes of the specified load balancer.

You can modify the load balancer attributes, such as AccessLogs, ConnectionDraining, and CrossZoneLoadBalancing by either enabling or disabling them. Or, you can modify the load balancer attribute ConnectionSettings by specifying an idle connection timeout value for your load balancer.

For more information, see the following in the Classic Load Balancers Guide:

Samples


fun main() { 
   //sampleStart 
   // This example enables cross zone load balancing for the specified load balancer.
val resp = elasticLoadBalancingClient.modifyLoadBalancerAttributes {
    loadBalancerName = "my-load-balancer"
    loadBalancerAttributes = LoadBalancerAttributes {
        crossZoneLoadBalancing = CrossZoneLoadBalancing {
            enabled = true
        }
    }
} 
   //sampleEnd
}