Class ScalingPolicy

    • Constructor Detail

      • ScalingPolicy

        public ScalingPolicy()
    • Method Detail

      • setPolicyARN

        public void setPolicyARN​(String policyARN)

        The Amazon Resource Name (ARN) of the scaling policy.

        Parameters:
        policyARN - The Amazon Resource Name (ARN) of the scaling policy.
      • getPolicyARN

        public String getPolicyARN()

        The Amazon Resource Name (ARN) of the scaling policy.

        Returns:
        The Amazon Resource Name (ARN) of the scaling policy.
      • withPolicyARN

        public ScalingPolicy withPolicyARN​(String policyARN)

        The Amazon Resource Name (ARN) of the scaling policy.

        Parameters:
        policyARN - The Amazon Resource Name (ARN) of the scaling policy.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setPolicyName

        public void setPolicyName​(String policyName)

        The name of the scaling policy.

        Parameters:
        policyName - The name of the scaling policy.
      • getPolicyName

        public String getPolicyName()

        The name of the scaling policy.

        Returns:
        The name of the scaling policy.
      • withPolicyName

        public ScalingPolicy withPolicyName​(String policyName)

        The name of the scaling policy.

        Parameters:
        policyName - The name of the scaling policy.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setServiceNamespace

        public void setServiceNamespace​(String serviceNamespace)

        The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.

        Parameters:
        serviceNamespace - The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.
        See Also:
        ServiceNamespace
      • getServiceNamespace

        public String getServiceNamespace()

        The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.

        Returns:
        The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.
        See Also:
        ServiceNamespace
      • withServiceNamespace

        public ScalingPolicy withServiceNamespace​(String serviceNamespace)

        The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.

        Parameters:
        serviceNamespace - The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        ServiceNamespace
      • setServiceNamespace

        public void setServiceNamespace​(ServiceNamespace serviceNamespace)

        The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.

        Parameters:
        serviceNamespace - The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.
        See Also:
        ServiceNamespace
      • withServiceNamespace

        public ScalingPolicy withServiceNamespace​(ServiceNamespace serviceNamespace)

        The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.

        Parameters:
        serviceNamespace - The namespace for the AWS service that the scaling policy is associated with. For more information, see AWS Service Namespaces in the Amazon Web Services General Reference.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        ServiceNamespace
      • setResourceId

        public void setResourceId​(String resourceId)

        The unique identifier string for the resource associated with the scaling policy. For Amazon ECS services, this value is the resource type, followed by the cluster name and service name, such as service/default/sample-webapp.

        Parameters:
        resourceId - The unique identifier string for the resource associated with the scaling policy. For Amazon ECS services, this value is the resource type, followed by the cluster name and service name, such as service/default/sample-webapp.
      • getResourceId

        public String getResourceId()

        The unique identifier string for the resource associated with the scaling policy. For Amazon ECS services, this value is the resource type, followed by the cluster name and service name, such as service/default/sample-webapp.

        Returns:
        The unique identifier string for the resource associated with the scaling policy. For Amazon ECS services, this value is the resource type, followed by the cluster name and service name, such as service/default/sample-webapp.
      • withResourceId

        public ScalingPolicy withResourceId​(String resourceId)

        The unique identifier string for the resource associated with the scaling policy. For Amazon ECS services, this value is the resource type, followed by the cluster name and service name, such as service/default/sample-webapp.

        Parameters:
        resourceId - The unique identifier string for the resource associated with the scaling policy. For Amazon ECS services, this value is the resource type, followed by the cluster name and service name, such as service/default/sample-webapp.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setScalableDimension

        public void setScalableDimension​(String scalableDimension)

        The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.

        Parameters:
        scalableDimension - The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.
        See Also:
        ScalableDimension
      • getScalableDimension

        public String getScalableDimension()

        The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.

        Returns:
        The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.
        See Also:
        ScalableDimension
      • withScalableDimension

        public ScalingPolicy withScalableDimension​(String scalableDimension)

        The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.

        Parameters:
        scalableDimension - The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        ScalableDimension
      • setScalableDimension

        public void setScalableDimension​(ScalableDimension scalableDimension)

        The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.

        Parameters:
        scalableDimension - The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.
        See Also:
        ScalableDimension
      • withScalableDimension

        public ScalingPolicy withScalableDimension​(ScalableDimension scalableDimension)

        The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.

        Parameters:
        scalableDimension - The scalable dimension associated with the scaling policy. The scalable dimension contains the service namespace, resource type, and scaling property, such as ecs:service:DesiredCount for the desired task count of an Amazon ECS service.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        ScalableDimension
      • setPolicyType

        public void setPolicyType​(String policyType)

        The scaling policy type.

        Parameters:
        policyType - The scaling policy type.
        See Also:
        PolicyType
      • getPolicyType

        public String getPolicyType()

        The scaling policy type.

        Returns:
        The scaling policy type.
        See Also:
        PolicyType
      • withPolicyType

        public ScalingPolicy withPolicyType​(String policyType)

        The scaling policy type.

        Parameters:
        policyType - The scaling policy type.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        PolicyType
      • setPolicyType

        public void setPolicyType​(PolicyType policyType)

        The scaling policy type.

        Parameters:
        policyType - The scaling policy type.
        See Also:
        PolicyType
      • withPolicyType

        public ScalingPolicy withPolicyType​(PolicyType policyType)

        The scaling policy type.

        Parameters:
        policyType - The scaling policy type.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        PolicyType
      • setStepScalingPolicyConfiguration

        public void setStepScalingPolicyConfiguration​(StepScalingPolicyConfiguration stepScalingPolicyConfiguration)

        The configuration for the step scaling policy.

        Parameters:
        stepScalingPolicyConfiguration - The configuration for the step scaling policy.
      • getStepScalingPolicyConfiguration

        public StepScalingPolicyConfiguration getStepScalingPolicyConfiguration()

        The configuration for the step scaling policy.

        Returns:
        The configuration for the step scaling policy.
      • withStepScalingPolicyConfiguration

        public ScalingPolicy withStepScalingPolicyConfiguration​(StepScalingPolicyConfiguration stepScalingPolicyConfiguration)

        The configuration for the step scaling policy.

        Parameters:
        stepScalingPolicyConfiguration - The configuration for the step scaling policy.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • getAlarms

        public List<Alarm> getAlarms()

        The CloudWatch alarms that are associated with the scaling policy.

        Returns:
        The CloudWatch alarms that are associated with the scaling policy.
      • setAlarms

        public void setAlarms​(Collection<Alarm> alarms)

        The CloudWatch alarms that are associated with the scaling policy.

        Parameters:
        alarms - The CloudWatch alarms that are associated with the scaling policy.
      • withAlarms

        public ScalingPolicy withAlarms​(Alarm... alarms)

        The CloudWatch alarms that are associated with the scaling policy.

        NOTE: This method appends the values to the existing list (if any). Use setAlarms(java.util.Collection) or withAlarms(java.util.Collection) if you want to override the existing values.

        Parameters:
        alarms - The CloudWatch alarms that are associated with the scaling policy.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • withAlarms

        public ScalingPolicy withAlarms​(Collection<Alarm> alarms)

        The CloudWatch alarms that are associated with the scaling policy.

        Parameters:
        alarms - The CloudWatch alarms that are associated with the scaling policy.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setCreationTime

        public void setCreationTime​(Date creationTime)

        The Unix timestamp for when the scaling policy was created.

        Parameters:
        creationTime - The Unix timestamp for when the scaling policy was created.
      • getCreationTime

        public Date getCreationTime()

        The Unix timestamp for when the scaling policy was created.

        Returns:
        The Unix timestamp for when the scaling policy was created.
      • withCreationTime

        public ScalingPolicy withCreationTime​(Date creationTime)

        The Unix timestamp for when the scaling policy was created.

        Parameters:
        creationTime - The Unix timestamp for when the scaling policy was created.
        Returns:
        Returns a reference to this 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