All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.aws.autoscaling.inputs.LifecycleHookState Maven / Gradle / Ivy

// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***

package com.pulumi.aws.autoscaling.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class LifecycleHookState extends com.pulumi.resources.ResourceArgs {

    public static final LifecycleHookState Empty = new LifecycleHookState();

    /**
     * Name of the Auto Scaling group to which you want to assign the lifecycle hook
     * 
     */
    @Import(name="autoscalingGroupName")
    private @Nullable Output autoscalingGroupName;

    /**
     * @return Name of the Auto Scaling group to which you want to assign the lifecycle hook
     * 
     */
    public Optional> autoscalingGroupName() {
        return Optional.ofNullable(this.autoscalingGroupName);
    }

    /**
     * Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. The value for this parameter can be either CONTINUE or ABANDON. The default value for this parameter is ABANDON.
     * 
     */
    @Import(name="defaultResult")
    private @Nullable Output defaultResult;

    /**
     * @return Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. The value for this parameter can be either CONTINUE or ABANDON. The default value for this parameter is ABANDON.
     * 
     */
    public Optional> defaultResult() {
        return Optional.ofNullable(this.defaultResult);
    }

    /**
     * Defines 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 action defined in the DefaultResult parameter
     * 
     */
    @Import(name="heartbeatTimeout")
    private @Nullable Output heartbeatTimeout;

    /**
     * @return Defines 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 action defined in the DefaultResult parameter
     * 
     */
    public Optional> heartbeatTimeout() {
        return Optional.ofNullable(this.heartbeatTimeout);
    }

    /**
     * Instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see [describe-lifecycle-hook-types](https://docs.aws.amazon.com/cli/latest/reference/autoscaling/describe-lifecycle-hook-types.html#examples)
     * 
     */
    @Import(name="lifecycleTransition")
    private @Nullable Output lifecycleTransition;

    /**
     * @return Instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see [describe-lifecycle-hook-types](https://docs.aws.amazon.com/cli/latest/reference/autoscaling/describe-lifecycle-hook-types.html#examples)
     * 
     */
    public Optional> lifecycleTransition() {
        return Optional.ofNullable(this.lifecycleTransition);
    }

    /**
     * Name of the lifecycle hook.
     * 
     */
    @Import(name="name")
    private @Nullable Output name;

    /**
     * @return Name of the lifecycle hook.
     * 
     */
    public Optional> name() {
        return Optional.ofNullable(this.name);
    }

    /**
     * Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.
     * 
     */
    @Import(name="notificationMetadata")
    private @Nullable Output notificationMetadata;

    /**
     * @return Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.
     * 
     */
    public Optional> notificationMetadata() {
        return Optional.ofNullable(this.notificationMetadata);
    }

    /**
     * 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 ARN target can be either an SQS queue or an SNS topic.
     * 
     */
    @Import(name="notificationTargetArn")
    private @Nullable Output notificationTargetArn;

    /**
     * @return 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 ARN target can be either an SQS queue or an SNS topic.
     * 
     */
    public Optional> notificationTargetArn() {
        return Optional.ofNullable(this.notificationTargetArn);
    }

    /**
     * ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.
     * 
     */
    @Import(name="roleArn")
    private @Nullable Output roleArn;

    /**
     * @return ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.
     * 
     */
    public Optional> roleArn() {
        return Optional.ofNullable(this.roleArn);
    }

    private LifecycleHookState() {}

    private LifecycleHookState(LifecycleHookState $) {
        this.autoscalingGroupName = $.autoscalingGroupName;
        this.defaultResult = $.defaultResult;
        this.heartbeatTimeout = $.heartbeatTimeout;
        this.lifecycleTransition = $.lifecycleTransition;
        this.name = $.name;
        this.notificationMetadata = $.notificationMetadata;
        this.notificationTargetArn = $.notificationTargetArn;
        this.roleArn = $.roleArn;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(LifecycleHookState defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private LifecycleHookState $;

        public Builder() {
            $ = new LifecycleHookState();
        }

        public Builder(LifecycleHookState defaults) {
            $ = new LifecycleHookState(Objects.requireNonNull(defaults));
        }

        /**
         * @param autoscalingGroupName Name of the Auto Scaling group to which you want to assign the lifecycle hook
         * 
         * @return builder
         * 
         */
        public Builder autoscalingGroupName(@Nullable Output autoscalingGroupName) {
            $.autoscalingGroupName = autoscalingGroupName;
            return this;
        }

        /**
         * @param autoscalingGroupName Name of the Auto Scaling group to which you want to assign the lifecycle hook
         * 
         * @return builder
         * 
         */
        public Builder autoscalingGroupName(String autoscalingGroupName) {
            return autoscalingGroupName(Output.of(autoscalingGroupName));
        }

        /**
         * @param defaultResult Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. The value for this parameter can be either CONTINUE or ABANDON. The default value for this parameter is ABANDON.
         * 
         * @return builder
         * 
         */
        public Builder defaultResult(@Nullable Output defaultResult) {
            $.defaultResult = defaultResult;
            return this;
        }

        /**
         * @param defaultResult Defines the action the Auto Scaling group should take when the lifecycle hook timeout elapses or if an unexpected failure occurs. The value for this parameter can be either CONTINUE or ABANDON. The default value for this parameter is ABANDON.
         * 
         * @return builder
         * 
         */
        public Builder defaultResult(String defaultResult) {
            return defaultResult(Output.of(defaultResult));
        }

        /**
         * @param heartbeatTimeout Defines 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 action defined in the DefaultResult parameter
         * 
         * @return builder
         * 
         */
        public Builder heartbeatTimeout(@Nullable Output heartbeatTimeout) {
            $.heartbeatTimeout = heartbeatTimeout;
            return this;
        }

        /**
         * @param heartbeatTimeout Defines 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 action defined in the DefaultResult parameter
         * 
         * @return builder
         * 
         */
        public Builder heartbeatTimeout(Integer heartbeatTimeout) {
            return heartbeatTimeout(Output.of(heartbeatTimeout));
        }

        /**
         * @param lifecycleTransition Instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see [describe-lifecycle-hook-types](https://docs.aws.amazon.com/cli/latest/reference/autoscaling/describe-lifecycle-hook-types.html#examples)
         * 
         * @return builder
         * 
         */
        public Builder lifecycleTransition(@Nullable Output lifecycleTransition) {
            $.lifecycleTransition = lifecycleTransition;
            return this;
        }

        /**
         * @param lifecycleTransition Instance state to which you want to attach the lifecycle hook. For a list of lifecycle hook types, see [describe-lifecycle-hook-types](https://docs.aws.amazon.com/cli/latest/reference/autoscaling/describe-lifecycle-hook-types.html#examples)
         * 
         * @return builder
         * 
         */
        public Builder lifecycleTransition(String lifecycleTransition) {
            return lifecycleTransition(Output.of(lifecycleTransition));
        }

        /**
         * @param name Name of the lifecycle hook.
         * 
         * @return builder
         * 
         */
        public Builder name(@Nullable Output name) {
            $.name = name;
            return this;
        }

        /**
         * @param name Name of the lifecycle hook.
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param notificationMetadata Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.
         * 
         * @return builder
         * 
         */
        public Builder notificationMetadata(@Nullable Output notificationMetadata) {
            $.notificationMetadata = notificationMetadata;
            return this;
        }

        /**
         * @param notificationMetadata Contains additional information that you want to include any time Auto Scaling sends a message to the notification target.
         * 
         * @return builder
         * 
         */
        public Builder notificationMetadata(String notificationMetadata) {
            return notificationMetadata(Output.of(notificationMetadata));
        }

        /**
         * @param notificationTargetArn 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 ARN target can be either an SQS queue or an SNS topic.
         * 
         * @return builder
         * 
         */
        public Builder notificationTargetArn(@Nullable Output notificationTargetArn) {
            $.notificationTargetArn = notificationTargetArn;
            return this;
        }

        /**
         * @param notificationTargetArn 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 ARN target can be either an SQS queue or an SNS topic.
         * 
         * @return builder
         * 
         */
        public Builder notificationTargetArn(String notificationTargetArn) {
            return notificationTargetArn(Output.of(notificationTargetArn));
        }

        /**
         * @param roleArn ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.
         * 
         * @return builder
         * 
         */
        public Builder roleArn(@Nullable Output roleArn) {
            $.roleArn = roleArn;
            return this;
        }

        /**
         * @param roleArn ARN of the IAM role that allows the Auto Scaling group to publish to the specified notification target.
         * 
         * @return builder
         * 
         */
        public Builder roleArn(String roleArn) {
            return roleArn(Output.of(roleArn));
        }

        public LifecycleHookState build() {
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy