Example usage for com.amazonaws.services.autoscaling.model SetDesiredCapacityRequest SetDesiredCapacityRequest

List of usage examples for com.amazonaws.services.autoscaling.model SetDesiredCapacityRequest SetDesiredCapacityRequest

Introduction

In this page you can find the example usage for com.amazonaws.services.autoscaling.model SetDesiredCapacityRequest SetDesiredCapacityRequest.

Prototype

SetDesiredCapacityRequest

Source Link

Usage

From source file:com.zotoh.cloudapi.aws.EC2AutoScale.java

License:Open Source License

@Override
public void setDesiredCapacity(String group, int capacity) throws CloudException, InternalException {
    tstEStrArg("autoscale-group-name", group);
    tstNonNegIntArg("capacity", capacity);
    _svc.getCloud().getAutoScale().setDesiredCapacity(
            new SetDesiredCapacityRequest().withDesiredCapacity(capacity).withAutoScalingGroupName(group));
}

From source file:web.component.impl.aws.AWSAutoScalingImpl.java

@Override
public void setDesiredCapacity(String autoScalingGroupName, int desiredCapacity) {

    awsHttpClient.setDesiredCapacity(new SetDesiredCapacityRequest()
            .withAutoScalingGroupName(autoScalingGroupName).withDesiredCapacity(desiredCapacity));

}