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

com.pulumi.aws.s3.inputs.BucketReplicationConfigRuleArgs 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.s3.inputs;

import com.pulumi.aws.s3.inputs.BucketReplicationConfigRuleDeleteMarkerReplicationArgs;
import com.pulumi.aws.s3.inputs.BucketReplicationConfigRuleDestinationArgs;
import com.pulumi.aws.s3.inputs.BucketReplicationConfigRuleExistingObjectReplicationArgs;
import com.pulumi.aws.s3.inputs.BucketReplicationConfigRuleFilterArgs;
import com.pulumi.aws.s3.inputs.BucketReplicationConfigRuleSourceSelectionCriteriaArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final BucketReplicationConfigRuleArgs Empty = new BucketReplicationConfigRuleArgs();

    /**
     * Whether delete markers are replicated. This argument is only valid with V2 replication configurations (i.e., when `filter` is used)documented below.
     * 
     */
    @Import(name="deleteMarkerReplication")
    private @Nullable Output deleteMarkerReplication;

    /**
     * @return Whether delete markers are replicated. This argument is only valid with V2 replication configurations (i.e., when `filter` is used)documented below.
     * 
     */
    public Optional> deleteMarkerReplication() {
        return Optional.ofNullable(this.deleteMarkerReplication);
    }

    /**
     * Specifies the destination for the rule. See below.
     * 
     */
    @Import(name="destination", required=true)
    private Output destination;

    /**
     * @return Specifies the destination for the rule. See below.
     * 
     */
    public Output destination() {
        return this.destination;
    }

    /**
     * Replicate existing objects in the source bucket according to the rule configurations. See below.
     * 
     */
    @Import(name="existingObjectReplication")
    private @Nullable Output existingObjectReplication;

    /**
     * @return Replicate existing objects in the source bucket according to the rule configurations. See below.
     * 
     */
    public Optional> existingObjectReplication() {
        return Optional.ofNullable(this.existingObjectReplication);
    }

    /**
     * Filter that identifies subset of objects to which the replication rule applies. See below. If not specified, the `rule` will default to using `prefix`.
     * 
     */
    @Import(name="filter")
    private @Nullable Output filter;

    /**
     * @return Filter that identifies subset of objects to which the replication rule applies. See below. If not specified, the `rule` will default to using `prefix`.
     * 
     */
    public Optional> filter() {
        return Optional.ofNullable(this.filter);
    }

    /**
     * Unique identifier for the rule. Must be less than or equal to 255 characters in length.
     * 
     */
    @Import(name="id")
    private @Nullable Output id;

    /**
     * @return Unique identifier for the rule. Must be less than or equal to 255 characters in length.
     * 
     */
    public Optional> id() {
        return Optional.ofNullable(this.id);
    }

    /**
     * Object key name prefix identifying one or more objects to which the rule applies. Must be less than or equal to 1024 characters in length. Defaults to an empty string (`""`) if `filter` is not specified.
     * 
     * @deprecated
     * Use filter instead
     * 
     */
    @Deprecated /* Use filter instead */
    @Import(name="prefix")
    private @Nullable Output prefix;

    /**
     * @return Object key name prefix identifying one or more objects to which the rule applies. Must be less than or equal to 1024 characters in length. Defaults to an empty string (`""`) if `filter` is not specified.
     * 
     * @deprecated
     * Use filter instead
     * 
     */
    @Deprecated /* Use filter instead */
    public Optional> prefix() {
        return Optional.ofNullable(this.prefix);
    }

    /**
     * Priority associated with the rule. Priority should only be set if `filter` is configured. If not provided, defaults to `0`. Priority must be unique between multiple rules.
     * 
     */
    @Import(name="priority")
    private @Nullable Output priority;

    /**
     * @return Priority associated with the rule. Priority should only be set if `filter` is configured. If not provided, defaults to `0`. Priority must be unique between multiple rules.
     * 
     */
    public Optional> priority() {
        return Optional.ofNullable(this.priority);
    }

    /**
     * Specifies special object selection criteria. See below.
     * 
     */
    @Import(name="sourceSelectionCriteria")
    private @Nullable Output sourceSelectionCriteria;

    /**
     * @return Specifies special object selection criteria. See below.
     * 
     */
    public Optional> sourceSelectionCriteria() {
        return Optional.ofNullable(this.sourceSelectionCriteria);
    }

    /**
     * Status of the rule. Either `"Enabled"` or `"Disabled"`. The rule is ignored if status is not "Enabled".
     * 
     */
    @Import(name="status", required=true)
    private Output status;

    /**
     * @return Status of the rule. Either `"Enabled"` or `"Disabled"`. The rule is ignored if status is not "Enabled".
     * 
     */
    public Output status() {
        return this.status;
    }

    private BucketReplicationConfigRuleArgs() {}

    private BucketReplicationConfigRuleArgs(BucketReplicationConfigRuleArgs $) {
        this.deleteMarkerReplication = $.deleteMarkerReplication;
        this.destination = $.destination;
        this.existingObjectReplication = $.existingObjectReplication;
        this.filter = $.filter;
        this.id = $.id;
        this.prefix = $.prefix;
        this.priority = $.priority;
        this.sourceSelectionCriteria = $.sourceSelectionCriteria;
        this.status = $.status;
    }

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

    public static final class Builder {
        private BucketReplicationConfigRuleArgs $;

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

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

        /**
         * @param deleteMarkerReplication Whether delete markers are replicated. This argument is only valid with V2 replication configurations (i.e., when `filter` is used)documented below.
         * 
         * @return builder
         * 
         */
        public Builder deleteMarkerReplication(@Nullable Output deleteMarkerReplication) {
            $.deleteMarkerReplication = deleteMarkerReplication;
            return this;
        }

        /**
         * @param deleteMarkerReplication Whether delete markers are replicated. This argument is only valid with V2 replication configurations (i.e., when `filter` is used)documented below.
         * 
         * @return builder
         * 
         */
        public Builder deleteMarkerReplication(BucketReplicationConfigRuleDeleteMarkerReplicationArgs deleteMarkerReplication) {
            return deleteMarkerReplication(Output.of(deleteMarkerReplication));
        }

        /**
         * @param destination Specifies the destination for the rule. See below.
         * 
         * @return builder
         * 
         */
        public Builder destination(Output destination) {
            $.destination = destination;
            return this;
        }

        /**
         * @param destination Specifies the destination for the rule. See below.
         * 
         * @return builder
         * 
         */
        public Builder destination(BucketReplicationConfigRuleDestinationArgs destination) {
            return destination(Output.of(destination));
        }

        /**
         * @param existingObjectReplication Replicate existing objects in the source bucket according to the rule configurations. See below.
         * 
         * @return builder
         * 
         */
        public Builder existingObjectReplication(@Nullable Output existingObjectReplication) {
            $.existingObjectReplication = existingObjectReplication;
            return this;
        }

        /**
         * @param existingObjectReplication Replicate existing objects in the source bucket according to the rule configurations. See below.
         * 
         * @return builder
         * 
         */
        public Builder existingObjectReplication(BucketReplicationConfigRuleExistingObjectReplicationArgs existingObjectReplication) {
            return existingObjectReplication(Output.of(existingObjectReplication));
        }

        /**
         * @param filter Filter that identifies subset of objects to which the replication rule applies. See below. If not specified, the `rule` will default to using `prefix`.
         * 
         * @return builder
         * 
         */
        public Builder filter(@Nullable Output filter) {
            $.filter = filter;
            return this;
        }

        /**
         * @param filter Filter that identifies subset of objects to which the replication rule applies. See below. If not specified, the `rule` will default to using `prefix`.
         * 
         * @return builder
         * 
         */
        public Builder filter(BucketReplicationConfigRuleFilterArgs filter) {
            return filter(Output.of(filter));
        }

        /**
         * @param id Unique identifier for the rule. Must be less than or equal to 255 characters in length.
         * 
         * @return builder
         * 
         */
        public Builder id(@Nullable Output id) {
            $.id = id;
            return this;
        }

        /**
         * @param id Unique identifier for the rule. Must be less than or equal to 255 characters in length.
         * 
         * @return builder
         * 
         */
        public Builder id(String id) {
            return id(Output.of(id));
        }

        /**
         * @param prefix Object key name prefix identifying one or more objects to which the rule applies. Must be less than or equal to 1024 characters in length. Defaults to an empty string (`""`) if `filter` is not specified.
         * 
         * @return builder
         * 
         * @deprecated
         * Use filter instead
         * 
         */
        @Deprecated /* Use filter instead */
        public Builder prefix(@Nullable Output prefix) {
            $.prefix = prefix;
            return this;
        }

        /**
         * @param prefix Object key name prefix identifying one or more objects to which the rule applies. Must be less than or equal to 1024 characters in length. Defaults to an empty string (`""`) if `filter` is not specified.
         * 
         * @return builder
         * 
         * @deprecated
         * Use filter instead
         * 
         */
        @Deprecated /* Use filter instead */
        public Builder prefix(String prefix) {
            return prefix(Output.of(prefix));
        }

        /**
         * @param priority Priority associated with the rule. Priority should only be set if `filter` is configured. If not provided, defaults to `0`. Priority must be unique between multiple rules.
         * 
         * @return builder
         * 
         */
        public Builder priority(@Nullable Output priority) {
            $.priority = priority;
            return this;
        }

        /**
         * @param priority Priority associated with the rule. Priority should only be set if `filter` is configured. If not provided, defaults to `0`. Priority must be unique between multiple rules.
         * 
         * @return builder
         * 
         */
        public Builder priority(Integer priority) {
            return priority(Output.of(priority));
        }

        /**
         * @param sourceSelectionCriteria Specifies special object selection criteria. See below.
         * 
         * @return builder
         * 
         */
        public Builder sourceSelectionCriteria(@Nullable Output sourceSelectionCriteria) {
            $.sourceSelectionCriteria = sourceSelectionCriteria;
            return this;
        }

        /**
         * @param sourceSelectionCriteria Specifies special object selection criteria. See below.
         * 
         * @return builder
         * 
         */
        public Builder sourceSelectionCriteria(BucketReplicationConfigRuleSourceSelectionCriteriaArgs sourceSelectionCriteria) {
            return sourceSelectionCriteria(Output.of(sourceSelectionCriteria));
        }

        /**
         * @param status Status of the rule. Either `"Enabled"` or `"Disabled"`. The rule is ignored if status is not "Enabled".
         * 
         * @return builder
         * 
         */
        public Builder status(Output status) {
            $.status = status;
            return this;
        }

        /**
         * @param status Status of the rule. Either `"Enabled"` or `"Disabled"`. The rule is ignored if status is not "Enabled".
         * 
         * @return builder
         * 
         */
        public Builder status(String status) {
            return status(Output.of(status));
        }

        public BucketReplicationConfigRuleArgs build() {
            if ($.destination == null) {
                throw new MissingRequiredPropertyException("BucketReplicationConfigRuleArgs", "destination");
            }
            if ($.status == null) {
                throw new MissingRequiredPropertyException("BucketReplicationConfigRuleArgs", "status");
            }
            return $;
        }
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy