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

com.pulumi.aws.ec2.inputs.InstanceInstanceMarketOptionsSpotOptionsArgs Maven / Gradle / Ivy

Go to download

A Pulumi package for creating and managing Amazon Web Services (AWS) cloud resources.

There is a newer version: 6.60.0-alpha.1731982519
Show newest version
// *** 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.ec2.inputs;

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


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

    public static final InstanceInstanceMarketOptionsSpotOptionsArgs Empty = new InstanceInstanceMarketOptionsSpotOptionsArgs();

    /**
     * The behavior when a Spot Instance is interrupted. Valid values include `hibernate`, `stop`, `terminate` . The default is `terminate`.
     * 
     */
    @Import(name="instanceInterruptionBehavior")
    private @Nullable Output instanceInterruptionBehavior;

    /**
     * @return The behavior when a Spot Instance is interrupted. Valid values include `hibernate`, `stop`, `terminate` . The default is `terminate`.
     * 
     */
    public Optional> instanceInterruptionBehavior() {
        return Optional.ofNullable(this.instanceInterruptionBehavior);
    }

    /**
     * The maximum hourly price that you're willing to pay for a Spot Instance.
     * 
     */
    @Import(name="maxPrice")
    private @Nullable Output maxPrice;

    /**
     * @return The maximum hourly price that you're willing to pay for a Spot Instance.
     * 
     */
    public Optional> maxPrice() {
        return Optional.ofNullable(this.maxPrice);
    }

    /**
     * The Spot Instance request type. Valid values include `one-time`, `persistent`. Persistent Spot Instance requests are only supported when the instance interruption behavior is either hibernate or stop. The default is `one-time`.
     * 
     */
    @Import(name="spotInstanceType")
    private @Nullable Output spotInstanceType;

    /**
     * @return The Spot Instance request type. Valid values include `one-time`, `persistent`. Persistent Spot Instance requests are only supported when the instance interruption behavior is either hibernate or stop. The default is `one-time`.
     * 
     */
    public Optional> spotInstanceType() {
        return Optional.ofNullable(this.spotInstanceType);
    }

    /**
     * The end date of the request, in UTC format (YYYY-MM-DDTHH:MM:SSZ). Supported only for persistent requests.
     * 
     */
    @Import(name="validUntil")
    private @Nullable Output validUntil;

    /**
     * @return The end date of the request, in UTC format (YYYY-MM-DDTHH:MM:SSZ). Supported only for persistent requests.
     * 
     */
    public Optional> validUntil() {
        return Optional.ofNullable(this.validUntil);
    }

    private InstanceInstanceMarketOptionsSpotOptionsArgs() {}

    private InstanceInstanceMarketOptionsSpotOptionsArgs(InstanceInstanceMarketOptionsSpotOptionsArgs $) {
        this.instanceInterruptionBehavior = $.instanceInterruptionBehavior;
        this.maxPrice = $.maxPrice;
        this.spotInstanceType = $.spotInstanceType;
        this.validUntil = $.validUntil;
    }

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

    public static final class Builder {
        private InstanceInstanceMarketOptionsSpotOptionsArgs $;

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

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

        /**
         * @param instanceInterruptionBehavior The behavior when a Spot Instance is interrupted. Valid values include `hibernate`, `stop`, `terminate` . The default is `terminate`.
         * 
         * @return builder
         * 
         */
        public Builder instanceInterruptionBehavior(@Nullable Output instanceInterruptionBehavior) {
            $.instanceInterruptionBehavior = instanceInterruptionBehavior;
            return this;
        }

        /**
         * @param instanceInterruptionBehavior The behavior when a Spot Instance is interrupted. Valid values include `hibernate`, `stop`, `terminate` . The default is `terminate`.
         * 
         * @return builder
         * 
         */
        public Builder instanceInterruptionBehavior(String instanceInterruptionBehavior) {
            return instanceInterruptionBehavior(Output.of(instanceInterruptionBehavior));
        }

        /**
         * @param maxPrice The maximum hourly price that you're willing to pay for a Spot Instance.
         * 
         * @return builder
         * 
         */
        public Builder maxPrice(@Nullable Output maxPrice) {
            $.maxPrice = maxPrice;
            return this;
        }

        /**
         * @param maxPrice The maximum hourly price that you're willing to pay for a Spot Instance.
         * 
         * @return builder
         * 
         */
        public Builder maxPrice(String maxPrice) {
            return maxPrice(Output.of(maxPrice));
        }

        /**
         * @param spotInstanceType The Spot Instance request type. Valid values include `one-time`, `persistent`. Persistent Spot Instance requests are only supported when the instance interruption behavior is either hibernate or stop. The default is `one-time`.
         * 
         * @return builder
         * 
         */
        public Builder spotInstanceType(@Nullable Output spotInstanceType) {
            $.spotInstanceType = spotInstanceType;
            return this;
        }

        /**
         * @param spotInstanceType The Spot Instance request type. Valid values include `one-time`, `persistent`. Persistent Spot Instance requests are only supported when the instance interruption behavior is either hibernate or stop. The default is `one-time`.
         * 
         * @return builder
         * 
         */
        public Builder spotInstanceType(String spotInstanceType) {
            return spotInstanceType(Output.of(spotInstanceType));
        }

        /**
         * @param validUntil The end date of the request, in UTC format (YYYY-MM-DDTHH:MM:SSZ). Supported only for persistent requests.
         * 
         * @return builder
         * 
         */
        public Builder validUntil(@Nullable Output validUntil) {
            $.validUntil = validUntil;
            return this;
        }

        /**
         * @param validUntil The end date of the request, in UTC format (YYYY-MM-DDTHH:MM:SSZ). Supported only for persistent requests.
         * 
         * @return builder
         * 
         */
        public Builder validUntil(String validUntil) {
            return validUntil(Output.of(validUntil));
        }

        public InstanceInstanceMarketOptionsSpotOptionsArgs build() {
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy