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

com.pulumi.aws.cloudfront.inputs.ContinuousDeploymentPolicyTrafficConfigArgs 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.cloudfront.inputs;

import com.pulumi.aws.cloudfront.inputs.ContinuousDeploymentPolicyTrafficConfigSingleHeaderConfigArgs;
import com.pulumi.aws.cloudfront.inputs.ContinuousDeploymentPolicyTrafficConfigSingleWeightConfigArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final ContinuousDeploymentPolicyTrafficConfigArgs Empty = new ContinuousDeploymentPolicyTrafficConfigArgs();

    /**
     * Determines which HTTP requests are sent to the staging distribution. See `single_header_config`.
     * 
     */
    @Import(name="singleHeaderConfig")
    private @Nullable Output singleHeaderConfig;

    /**
     * @return Determines which HTTP requests are sent to the staging distribution. See `single_header_config`.
     * 
     */
    public Optional> singleHeaderConfig() {
        return Optional.ofNullable(this.singleHeaderConfig);
    }

    /**
     * Contains the percentage of traffic to send to the staging distribution. See `single_weight_config`.
     * 
     */
    @Import(name="singleWeightConfig")
    private @Nullable Output singleWeightConfig;

    /**
     * @return Contains the percentage of traffic to send to the staging distribution. See `single_weight_config`.
     * 
     */
    public Optional> singleWeightConfig() {
        return Optional.ofNullable(this.singleWeightConfig);
    }

    /**
     * Type of traffic configuration. Valid values are `SingleWeight` and `SingleHeader`.
     * 
     */
    @Import(name="type", required=true)
    private Output type;

    /**
     * @return Type of traffic configuration. Valid values are `SingleWeight` and `SingleHeader`.
     * 
     */
    public Output type() {
        return this.type;
    }

    private ContinuousDeploymentPolicyTrafficConfigArgs() {}

    private ContinuousDeploymentPolicyTrafficConfigArgs(ContinuousDeploymentPolicyTrafficConfigArgs $) {
        this.singleHeaderConfig = $.singleHeaderConfig;
        this.singleWeightConfig = $.singleWeightConfig;
        this.type = $.type;
    }

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

    public static final class Builder {
        private ContinuousDeploymentPolicyTrafficConfigArgs $;

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

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

        /**
         * @param singleHeaderConfig Determines which HTTP requests are sent to the staging distribution. See `single_header_config`.
         * 
         * @return builder
         * 
         */
        public Builder singleHeaderConfig(@Nullable Output singleHeaderConfig) {
            $.singleHeaderConfig = singleHeaderConfig;
            return this;
        }

        /**
         * @param singleHeaderConfig Determines which HTTP requests are sent to the staging distribution. See `single_header_config`.
         * 
         * @return builder
         * 
         */
        public Builder singleHeaderConfig(ContinuousDeploymentPolicyTrafficConfigSingleHeaderConfigArgs singleHeaderConfig) {
            return singleHeaderConfig(Output.of(singleHeaderConfig));
        }

        /**
         * @param singleWeightConfig Contains the percentage of traffic to send to the staging distribution. See `single_weight_config`.
         * 
         * @return builder
         * 
         */
        public Builder singleWeightConfig(@Nullable Output singleWeightConfig) {
            $.singleWeightConfig = singleWeightConfig;
            return this;
        }

        /**
         * @param singleWeightConfig Contains the percentage of traffic to send to the staging distribution. See `single_weight_config`.
         * 
         * @return builder
         * 
         */
        public Builder singleWeightConfig(ContinuousDeploymentPolicyTrafficConfigSingleWeightConfigArgs singleWeightConfig) {
            return singleWeightConfig(Output.of(singleWeightConfig));
        }

        /**
         * @param type Type of traffic configuration. Valid values are `SingleWeight` and `SingleHeader`.
         * 
         * @return builder
         * 
         */
        public Builder type(Output type) {
            $.type = type;
            return this;
        }

        /**
         * @param type Type of traffic configuration. Valid values are `SingleWeight` and `SingleHeader`.
         * 
         * @return builder
         * 
         */
        public Builder type(String type) {
            return type(Output.of(type));
        }

        public ContinuousDeploymentPolicyTrafficConfigArgs build() {
            if ($.type == null) {
                throw new MissingRequiredPropertyException("ContinuousDeploymentPolicyTrafficConfigArgs", "type");
            }
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy