Class PutLifecycleHookRequest

    • Constructor Detail

      • PutLifecycleHookRequest

        public PutLifecycleHookRequest()
    • Method Detail

      • setLifecycleHookName

        public void setLifecycleHookName​(String lifecycleHookName)

        The name of the lifecycle hook.

        Parameters:
        lifecycleHookName - The name of the lifecycle hook.
      • getLifecycleHookName

        public String getLifecycleHookName()

        The name of the lifecycle hook.

        Returns:
        The name of the lifecycle hook.
      • withLifecycleHookName

        public PutLifecycleHookRequest withLifecycleHookName​(String lifecycleHookName)

        The name of the lifecycle hook.

        Parameters:
        lifecycleHookName - The name of the lifecycle hook.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setAutoScalingGroupName

        public void setAutoScalingGroupName​(String autoScalingGroupName)

        The name of the Auto Scaling group to which you want to assign the lifecycle hook.

        Parameters:
        autoScalingGroupName - The name of the Auto Scaling group to which you want to assign the lifecycle hook.
      • getAutoScalingGroupName

        public String getAutoScalingGroupName()

        The name of the Auto Scaling group to which you want to assign the lifecycle hook.

        Returns:
        The name of the Auto Scaling group to which you want to assign the lifecycle hook.
      • withAutoScalingGroupName

        public PutLifecycleHookRequest withAutoScalingGroupName​(String autoScalingGroupName)

        The name of the Auto Scaling group to which you want to assign the lifecycle hook.

        Parameters:
        autoScalingGroupName - The name of the Auto Scaling group to which you want to assign the lifecycle hook.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setLifecycleTransition

        public void setLifecycleTransition​(String lifecycleTransition)

        The instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see DescribeLifecycleHookTypes.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

        Parameters:
        lifecycleTransition - The instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see DescribeLifecycleHookTypes.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

      • getLifecycleTransition

        public String getLifecycleTransition()

        The instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see DescribeLifecycleHookTypes.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

        Returns:
        The instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see DescribeLifecycleHookTypes.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

      • withLifecycleTransition

        public PutLifecycleHookRequest withLifecycleTransition​(String lifecycleTransition)

        The instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see DescribeLifecycleHookTypes.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

        Parameters:
        lifecycleTransition - The instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see DescribeLifecycleHookTypes.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setRoleARN

        public void setRoleARN​(String roleARN)

        The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

        Parameters:
        roleARN - The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

      • getRoleARN

        public String getRoleARN()

        The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

        Returns:
        The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

      • withRoleARN

        public PutLifecycleHookRequest withRoleARN​(String roleARN)

        The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

        Parameters:
        roleARN - The ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.

        This parameter is required for new lifecycle hooks, but optional when updating existing hooks.

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setNotificationTargetARN

        public void setNotificationTargetARN​(String notificationTargetARN)

        The ARN of the notification target that Auto Scaling will use to notify you when an instance is in the transition state for the lifecycle hook. This target can be either an SQS queue or an SNS topic. If you specify an empty string, this overrides the current ARN.

        The notification messages sent to the target include the following information:

        • AutoScalingGroupName. The name of the Auto Scaling group.
        • AccountId. The AWS account ID.
        • LifecycleTransition. The lifecycle hook type.
        • LifecycleActionToken. The lifecycle action token.
        • EC2InstanceId. The EC2 instance ID.
        • LifecycleHookName. The name of the lifecycle hook.
        • NotificationMetadata. User-defined information.

        This operation uses the JSON format when sending notifications to an Amazon SQS queue, and an email key/value pair format when sending notifications to an Amazon SNS topic.

        When you specify a notification target, Auto Scaling sends it a test message. Test messages contains the following additional key/value pair: "Event": "autoscaling:TEST_NOTIFICATION".

        Parameters:
        notificationTargetARN - The ARN of the notification target that Auto Scaling will use to notify you when an instance is in the transition state for the lifecycle hook. This target can be either an SQS queue or an SNS topic. If you specify an empty string, this overrides the current ARN.

        The notification messages sent to the target include the following information:

        • AutoScalingGroupName. The name of the Auto Scaling group.
        • AccountId. The AWS account ID.
        • LifecycleTransition. The lifecycle hook type.
        • LifecycleActionToken. The lifecycle action token.
        • EC2InstanceId. The EC2 instance ID.
        • LifecycleHookName. The name of the lifecycle hook.
        • NotificationMetadata. User-defined information.

        This operation uses the JSON format when sending notifications to an Amazon SQS queue, and an email key/value pair format when sending notifications to an Amazon SNS topic.

        When you specify a notification target, Auto Scaling sends it a test message. Test messages contains the following additional key/value pair: "Event": "autoscaling:TEST_NOTIFICATION".

      • getNotificationTargetARN

        public String getNotificationTargetARN()

        The ARN of the notification target that Auto Scaling will use to notify you when an instance is in the transition state for the lifecycle hook. This target can be either an SQS queue or an SNS topic. If you specify an empty string, this overrides the current ARN.

        The notification messages sent to the target include the following information:

        • AutoScalingGroupName. The name of the Auto Scaling group.
        • AccountId. The AWS account ID.
        • LifecycleTransition. The lifecycle hook type.
        • LifecycleActionToken. The lifecycle action token.
        • EC2InstanceId. The EC2 instance ID.
        • LifecycleHookName. The name of the lifecycle hook.
        • NotificationMetadata. User-defined information.

        This operation uses the JSON format when sending notifications to an Amazon SQS queue, and an email key/value pair format when sending notifications to an Amazon SNS topic.

        When you specify a notification target, Auto Scaling sends it a test message. Test messages contains the following additional key/value pair: "Event": "autoscaling:TEST_NOTIFICATION".

        Returns:
        The ARN of the notification target that Auto Scaling will use to notify you when an instance is in the transition state for the lifecycle hook. This target can be either an SQS queue or an SNS topic. If you specify an empty string, this overrides the current ARN.

        The notification messages sent to the target include the following information:

        • AutoScalingGroupName. The name of the Auto Scaling group.
        • AccountId. The AWS account ID.
        • LifecycleTransition. The lifecycle hook type.
        • LifecycleActionToken. The lifecycle action token.
        • EC2InstanceId. The EC2 instance ID.
        • LifecycleHookName. The name of the lifecycle hook.
        • NotificationMetadata. User-defined information.

        This operation uses the JSON format when sending notifications to an Amazon SQS queue, and an email key/value pair format when sending notifications to an Amazon SNS topic.

        When you specify a notification target, Auto Scaling sends it a test message. Test messages contains the following additional key/value pair: "Event": "autoscaling:TEST_NOTIFICATION".

      • withNotificationTargetARN

        public PutLifecycleHookRequest withNotificationTargetARN​(String notificationTargetARN)

        The ARN of the notification target that Auto Scaling will use to notify you when an instance is in the transition state for the lifecycle hook. This target can be either an SQS queue or an SNS topic. If you specify an empty string, this overrides the current ARN.

        The notification messages sent to the target include the following information:

        • AutoScalingGroupName. The name of the Auto Scaling group.
        • AccountId. The AWS account ID.
        • LifecycleTransition. The lifecycle hook type.
        • LifecycleActionToken. The lifecycle action token.
        • EC2InstanceId. The EC2 instance ID.
        • LifecycleHookName. The name of the lifecycle hook.
        • NotificationMetadata. User-defined information.

        This operation uses the JSON format when sending notifications to an Amazon SQS queue, and an email key/value pair format when sending notifications to an Amazon SNS topic.

        When you specify a notification target, Auto Scaling sends it a test message. Test messages contains the following additional key/value pair: "Event": "autoscaling:TEST_NOTIFICATION".

        Parameters:
        notificationTargetARN - The ARN of the notification target that Auto Scaling will use to notify you when an instance is in the transition state for the lifecycle hook. This target can be either an SQS queue or an SNS topic. If you specify an empty string, this overrides the current ARN.

        The notification messages sent to the target include the following information:

        • AutoScalingGroupName. The name of the Auto Scaling group.
        • AccountId. The AWS account ID.
        • LifecycleTransition. The lifecycle hook type.
        • LifecycleActionToken. The lifecycle action token.
        • EC2InstanceId. The EC2 instance ID.
        • LifecycleHookName. The name of the lifecycle hook.
        • NotificationMetadata. User-defined information.

        This operation uses the JSON format when sending notifications to an Amazon SQS queue, and an email key/value pair format when sending notifications to an Amazon SNS topic.

        When you specify a notification target, Auto Scaling sends it a test message. Test messages contains the following additional key/value pair: "Event": "autoscaling:TEST_NOTIFICATION".

        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setNotificationMetadata

        public void setNotificationMetadata​(String notificationMetadata)

        Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.

        Parameters:
        notificationMetadata - Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.
      • getNotificationMetadata

        public String getNotificationMetadata()

        Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.

        Returns:
        Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.
      • withNotificationMetadata

        public PutLifecycleHookRequest withNotificationMetadata​(String notificationMetadata)

        Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.

        Parameters:
        notificationMetadata - Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setHeartbeatTimeout

        public void setHeartbeatTimeout​(Integer heartbeatTimeout)

        The amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the default action. You can prevent the lifecycle hook from timing out by calling RecordLifecycleActionHeartbeat. The default is 3600 seconds (1 hour).

        Parameters:
        heartbeatTimeout - The amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the default action. You can prevent the lifecycle hook from timing out by calling RecordLifecycleActionHeartbeat. The default is 3600 seconds (1 hour).
      • getHeartbeatTimeout

        public Integer getHeartbeatTimeout()

        The amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the default action. You can prevent the lifecycle hook from timing out by calling RecordLifecycleActionHeartbeat. The default is 3600 seconds (1 hour).

        Returns:
        The amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the default action. You can prevent the lifecycle hook from timing out by calling RecordLifecycleActionHeartbeat. The default is 3600 seconds (1 hour).
      • withHeartbeatTimeout

        public PutLifecycleHookRequest withHeartbeatTimeout​(Integer heartbeatTimeout)

        The amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the default action. You can prevent the lifecycle hook from timing out by calling RecordLifecycleActionHeartbeat. The default is 3600 seconds (1 hour).

        Parameters:
        heartbeatTimeout - The amount of time, in seconds, that can elapse before the lifecycle hook times out. When the lifecycle hook times out, Auto Scaling performs the default action. You can prevent the lifecycle hook from timing out by calling RecordLifecycleActionHeartbeat. The default is 3600 seconds (1 hour).
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • setDefaultResult

        public void setDefaultResult​(String defaultResult)

        Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. This parameter can be either CONTINUE or ABANDON. The default value is ABANDON.

        Parameters:
        defaultResult - Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. This parameter can be either CONTINUE or ABANDON. The default value is ABANDON.
      • getDefaultResult

        public String getDefaultResult()

        Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. This parameter can be either CONTINUE or ABANDON. The default value is ABANDON.

        Returns:
        Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. This parameter can be either CONTINUE or ABANDON. The default value is ABANDON.
      • withDefaultResult

        public PutLifecycleHookRequest withDefaultResult​(String defaultResult)

        Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. This parameter can be either CONTINUE or ABANDON. The default value is ABANDON.

        Parameters:
        defaultResult - Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. This parameter can be either CONTINUE or ABANDON. The default value is ABANDON.
        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