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

com.pulumi.aws.pipes.inputs.PipeTargetParametersEcsTaskParametersPlacementConstraintArgs 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.pipes.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 PipeTargetParametersEcsTaskParametersPlacementConstraintArgs extends com.pulumi.resources.ResourceArgs {

    public static final PipeTargetParametersEcsTaskParametersPlacementConstraintArgs Empty = new PipeTargetParametersEcsTaskParametersPlacementConstraintArgs();

    /**
     * A cluster query language expression to apply to the constraint. You cannot specify an expression if the constraint type is distinctInstance. Maximum length of 2,000.
     * 
     */
    @Import(name="expression")
    private @Nullable Output expression;

    /**
     * @return A cluster query language expression to apply to the constraint. You cannot specify an expression if the constraint type is distinctInstance. Maximum length of 2,000.
     * 
     */
    public Optional> expression() {
        return Optional.ofNullable(this.expression);
    }

    /**
     * The type of placement strategy. The random placement strategy randomly places tasks on available candidates. The spread placement strategy spreads placement across available candidates evenly based on the field parameter. The binpack strategy places tasks on available candidates that have the least available amount of the resource that is specified with the field parameter. For example, if you binpack on memory, a task is placed on the instance with the least amount of remaining memory (but still enough to run the task). Valid Values: random, spread, binpack.
     * 
     */
    @Import(name="type")
    private @Nullable Output type;

    /**
     * @return The type of placement strategy. The random placement strategy randomly places tasks on available candidates. The spread placement strategy spreads placement across available candidates evenly based on the field parameter. The binpack strategy places tasks on available candidates that have the least available amount of the resource that is specified with the field parameter. For example, if you binpack on memory, a task is placed on the instance with the least amount of remaining memory (but still enough to run the task). Valid Values: random, spread, binpack.
     * 
     */
    public Optional> type() {
        return Optional.ofNullable(this.type);
    }

    private PipeTargetParametersEcsTaskParametersPlacementConstraintArgs() {}

    private PipeTargetParametersEcsTaskParametersPlacementConstraintArgs(PipeTargetParametersEcsTaskParametersPlacementConstraintArgs $) {
        this.expression = $.expression;
        this.type = $.type;
    }

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

    public static final class Builder {
        private PipeTargetParametersEcsTaskParametersPlacementConstraintArgs $;

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

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

        /**
         * @param expression A cluster query language expression to apply to the constraint. You cannot specify an expression if the constraint type is distinctInstance. Maximum length of 2,000.
         * 
         * @return builder
         * 
         */
        public Builder expression(@Nullable Output expression) {
            $.expression = expression;
            return this;
        }

        /**
         * @param expression A cluster query language expression to apply to the constraint. You cannot specify an expression if the constraint type is distinctInstance. Maximum length of 2,000.
         * 
         * @return builder
         * 
         */
        public Builder expression(String expression) {
            return expression(Output.of(expression));
        }

        /**
         * @param type The type of placement strategy. The random placement strategy randomly places tasks on available candidates. The spread placement strategy spreads placement across available candidates evenly based on the field parameter. The binpack strategy places tasks on available candidates that have the least available amount of the resource that is specified with the field parameter. For example, if you binpack on memory, a task is placed on the instance with the least amount of remaining memory (but still enough to run the task). Valid Values: random, spread, binpack.
         * 
         * @return builder
         * 
         */
        public Builder type(@Nullable Output type) {
            $.type = type;
            return this;
        }

        /**
         * @param type The type of placement strategy. The random placement strategy randomly places tasks on available candidates. The spread placement strategy spreads placement across available candidates evenly based on the field parameter. The binpack strategy places tasks on available candidates that have the least available amount of the resource that is specified with the field parameter. For example, if you binpack on memory, a task is placed on the instance with the least amount of remaining memory (but still enough to run the task). Valid Values: random, spread, binpack.
         * 
         * @return builder
         * 
         */
        public Builder type(String type) {
            return type(Output.of(type));
        }

        public PipeTargetParametersEcsTaskParametersPlacementConstraintArgs build() {
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy