// AutoscalingGroupName derives the autoscaling group name for us
974540
func (b *KopsModelContext) AutoscalingGroupName(ig *kops.InstanceGroup) string {
	switch ig.Spec.Role {
	case kops.InstanceGroupRoleMaster:
		// We need to keep this back-compatible, so we introduce the masters name,
		// though the IG name suffices for uniqueness, and with sensible naming masters
		// should be redundant...
		return ig.ObjectMeta.Name + ".masters." + b.ClusterName()
	case kops.InstanceGroupRoleNode, kops.InstanceGroupRoleBastion:
		return ig.ObjectMeta.Name + "." + b.ClusterName()

	default:
		glog.Fatalf("unknown InstanceGroup Role: %v", ig.Spec.Role)
		return ""
	}
}
247593
func (s *Group) SetAutoScalingGroupName(v string) *Group {
	s.AutoScalingGroupName = &v
	return s
}
353053
func (s *ListJobsInput) SetThingGroupName(v string) *ListJobsInput {
	s.ThingGroupName = &v
	return s
}
1033264
func (s *DescribeLoadBalancersInput) SetAutoScalingGroupName(v string) *DescribeLoadBalancersInput {
	s.AutoScalingGroupName = &v
	return s
}
474249
func (s *CreateThingGroupOutput) SetThingGroupName(v string) *CreateThingGroupOutput {
	s.ThingGroupName = &v
	return s
}
518439
func (s *CreateBillingGroupInput) SetBillingGroupName(v string) *CreateBillingGroupInput {
	s.BillingGroupName = &v
	return s
}
652303
func ResizeInstanceGroup(asg ASG, instanceGroupName string, size int) error {
	request := &autoscaling.UpdateAutoScalingGroupInput{
		AutoScalingGroupName: aws.String(instanceGroupName),
		MinSize:              aws.Int64(int64(size)),
		MaxSize:              aws.Int64(int64(size)),
	}
	if _, err := asg.UpdateAutoScalingGroup(request); err != nil {
		return fmt.Errorf("error resizing AWS autoscaling group: %q", err)
	}
	return nil
}
1134444
func (s *DeploymentGroupInfo) SetAutoScalingGroups(v []*AutoScalingGroup) *DeploymentGroupInfo {
	s.AutoScalingGroups = v
	return s
}
985182
func (s *DescribeAutoScalingGroupsOutput) SetAutoScalingGroups(v []*Group) *DescribeAutoScalingGroupsOutput {
	s.AutoScalingGroups = v
	return s
}
95634
func (s *DescribePoliciesInput) SetAutoScalingGroupName(v string) *DescribePoliciesInput {
	s.AutoScalingGroupName = &v
	return s
}
207174
func (s *UpdateBillingGroupInput) SetBillingGroupName(v string) *UpdateBillingGroupInput {
	s.BillingGroupName = &v
	return s
}
870811
func (s *DeletePolicyInput) SetAutoScalingGroupName(v string) *DeletePolicyInput {
	s.AutoScalingGroupName = &v
	return s
}
780387
func (s *BatchDeleteScheduledActionInput) SetAutoScalingGroupName(v string) *BatchDeleteScheduledActionInput {
	s.AutoScalingGroupName = &v
	return s
}
602467
func (s *AgentPreview) SetAutoScalingGroup(v string) *AgentPreview {
	s.AutoScalingGroup = &v
	return s
}
846629
func (s *DetachLoadBalancersInput) SetAutoScalingGroupName(v string) *DetachLoadBalancersInput {
	s.AutoScalingGroupName = &v
	return s
}
224691
func (s *UpdateThingGroupInput) SetThingGroupName(v string) *UpdateThingGroupInput {
	s.ThingGroupName = &v
	return s
}
1358044
func (s *Group) SetAutoScalingGroupARN(v string) *Group {
	s.AutoScalingGroupARN = &v
	return s
}