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

com.pulumi.azure.cosmosdb.inputs.MongoCollectionState Maven / Gradle / Ivy

Go to download

A Pulumi package for creating and managing Microsoft Azure cloud resources, based on the Terraform azurerm provider. We recommend using the [Azure Native provider](https://github.com/pulumi/pulumi-azure-native) to provision Azure infrastructure. Azure Native provides complete coverage of Azure resources and same-day access to new resources and resource updates.

There is a newer version: 6.10.0-alpha.1731737215
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.azure.cosmosdb.inputs;

import com.pulumi.azure.cosmosdb.inputs.MongoCollectionAutoscaleSettingsArgs;
import com.pulumi.azure.cosmosdb.inputs.MongoCollectionIndexArgs;
import com.pulumi.azure.cosmosdb.inputs.MongoCollectionSystemIndexArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import java.lang.Integer;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final MongoCollectionState Empty = new MongoCollectionState();

    /**
     * The name of the Cosmos DB Account in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="accountName")
    private @Nullable Output accountName;

    /**
     * @return The name of the Cosmos DB Account in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
     * 
     */
    public Optional> accountName() {
        return Optional.ofNullable(this.accountName);
    }

    /**
     * The default time to live of Analytical Storage for this Mongo Collection. If present and the value is set to `-1`, it is equal to infinity, and items don’t expire by default. If present and the value is set to some number `n` – items will expire `n` seconds after their last modified time.
     * 
     */
    @Import(name="analyticalStorageTtl")
    private @Nullable Output analyticalStorageTtl;

    /**
     * @return The default time to live of Analytical Storage for this Mongo Collection. If present and the value is set to `-1`, it is equal to infinity, and items don’t expire by default. If present and the value is set to some number `n` – items will expire `n` seconds after their last modified time.
     * 
     */
    public Optional> analyticalStorageTtl() {
        return Optional.ofNullable(this.analyticalStorageTtl);
    }

    @Import(name="autoscaleSettings")
    private @Nullable Output autoscaleSettings;

    public Optional> autoscaleSettings() {
        return Optional.ofNullable(this.autoscaleSettings);
    }

    /**
     * The name of the Cosmos DB Mongo Database in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="databaseName")
    private @Nullable Output databaseName;

    /**
     * @return The name of the Cosmos DB Mongo Database in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
     * 
     */
    public Optional> databaseName() {
        return Optional.ofNullable(this.databaseName);
    }

    /**
     * The default Time To Live in seconds. If the value is `-1`, items are not automatically expired.
     * 
     */
    @Import(name="defaultTtlSeconds")
    private @Nullable Output defaultTtlSeconds;

    /**
     * @return The default Time To Live in seconds. If the value is `-1`, items are not automatically expired.
     * 
     */
    public Optional> defaultTtlSeconds() {
        return Optional.ofNullable(this.defaultTtlSeconds);
    }

    /**
     * One or more `index` blocks as defined below.
     * 
     */
    @Import(name="indices")
    private @Nullable Output> indices;

    /**
     * @return One or more `index` blocks as defined below.
     * 
     */
    public Optional>> indices() {
        return Optional.ofNullable(this.indices);
    }

    /**
     * Specifies the name of the Cosmos DB Mongo Collection. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="name")
    private @Nullable Output name;

    /**
     * @return Specifies the name of the Cosmos DB Mongo Collection. Changing this forces a new resource to be created.
     * 
     */
    public Optional> name() {
        return Optional.ofNullable(this.name);
    }

    /**
     * The name of the resource group in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="resourceGroupName")
    private @Nullable Output resourceGroupName;

    /**
     * @return The name of the resource group in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
     * 
     */
    public Optional> resourceGroupName() {
        return Optional.ofNullable(this.resourceGroupName);
    }

    /**
     * The name of the key to partition on for sharding. There must not be any other unique index keys. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="shardKey")
    private @Nullable Output shardKey;

    /**
     * @return The name of the key to partition on for sharding. There must not be any other unique index keys. Changing this forces a new resource to be created.
     * 
     */
    public Optional> shardKey() {
        return Optional.ofNullable(this.shardKey);
    }

    /**
     * One or more `system_indexes` blocks as defined below.
     * 
     */
    @Import(name="systemIndexes")
    private @Nullable Output> systemIndexes;

    /**
     * @return One or more `system_indexes` blocks as defined below.
     * 
     */
    public Optional>> systemIndexes() {
        return Optional.ofNullable(this.systemIndexes);
    }

    @Import(name="throughput")
    private @Nullable Output throughput;

    public Optional> throughput() {
        return Optional.ofNullable(this.throughput);
    }

    private MongoCollectionState() {}

    private MongoCollectionState(MongoCollectionState $) {
        this.accountName = $.accountName;
        this.analyticalStorageTtl = $.analyticalStorageTtl;
        this.autoscaleSettings = $.autoscaleSettings;
        this.databaseName = $.databaseName;
        this.defaultTtlSeconds = $.defaultTtlSeconds;
        this.indices = $.indices;
        this.name = $.name;
        this.resourceGroupName = $.resourceGroupName;
        this.shardKey = $.shardKey;
        this.systemIndexes = $.systemIndexes;
        this.throughput = $.throughput;
    }

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

    public static final class Builder {
        private MongoCollectionState $;

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

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

        /**
         * @param accountName The name of the Cosmos DB Account in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder accountName(@Nullable Output accountName) {
            $.accountName = accountName;
            return this;
        }

        /**
         * @param accountName The name of the Cosmos DB Account in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder accountName(String accountName) {
            return accountName(Output.of(accountName));
        }

        /**
         * @param analyticalStorageTtl The default time to live of Analytical Storage for this Mongo Collection. If present and the value is set to `-1`, it is equal to infinity, and items don’t expire by default. If present and the value is set to some number `n` – items will expire `n` seconds after their last modified time.
         * 
         * @return builder
         * 
         */
        public Builder analyticalStorageTtl(@Nullable Output analyticalStorageTtl) {
            $.analyticalStorageTtl = analyticalStorageTtl;
            return this;
        }

        /**
         * @param analyticalStorageTtl The default time to live of Analytical Storage for this Mongo Collection. If present and the value is set to `-1`, it is equal to infinity, and items don’t expire by default. If present and the value is set to some number `n` – items will expire `n` seconds after their last modified time.
         * 
         * @return builder
         * 
         */
        public Builder analyticalStorageTtl(Integer analyticalStorageTtl) {
            return analyticalStorageTtl(Output.of(analyticalStorageTtl));
        }

        public Builder autoscaleSettings(@Nullable Output autoscaleSettings) {
            $.autoscaleSettings = autoscaleSettings;
            return this;
        }

        public Builder autoscaleSettings(MongoCollectionAutoscaleSettingsArgs autoscaleSettings) {
            return autoscaleSettings(Output.of(autoscaleSettings));
        }

        /**
         * @param databaseName The name of the Cosmos DB Mongo Database in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder databaseName(@Nullable Output databaseName) {
            $.databaseName = databaseName;
            return this;
        }

        /**
         * @param databaseName The name of the Cosmos DB Mongo Database in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder databaseName(String databaseName) {
            return databaseName(Output.of(databaseName));
        }

        /**
         * @param defaultTtlSeconds The default Time To Live in seconds. If the value is `-1`, items are not automatically expired.
         * 
         * @return builder
         * 
         */
        public Builder defaultTtlSeconds(@Nullable Output defaultTtlSeconds) {
            $.defaultTtlSeconds = defaultTtlSeconds;
            return this;
        }

        /**
         * @param defaultTtlSeconds The default Time To Live in seconds. If the value is `-1`, items are not automatically expired.
         * 
         * @return builder
         * 
         */
        public Builder defaultTtlSeconds(Integer defaultTtlSeconds) {
            return defaultTtlSeconds(Output.of(defaultTtlSeconds));
        }

        /**
         * @param indices One or more `index` blocks as defined below.
         * 
         * @return builder
         * 
         */
        public Builder indices(@Nullable Output> indices) {
            $.indices = indices;
            return this;
        }

        /**
         * @param indices One or more `index` blocks as defined below.
         * 
         * @return builder
         * 
         */
        public Builder indices(List indices) {
            return indices(Output.of(indices));
        }

        /**
         * @param indices One or more `index` blocks as defined below.
         * 
         * @return builder
         * 
         */
        public Builder indices(MongoCollectionIndexArgs... indices) {
            return indices(List.of(indices));
        }

        /**
         * @param name Specifies the name of the Cosmos DB Mongo Collection. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder name(@Nullable Output name) {
            $.name = name;
            return this;
        }

        /**
         * @param name Specifies the name of the Cosmos DB Mongo Collection. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder name(String name) {
            return name(Output.of(name));
        }

        /**
         * @param resourceGroupName The name of the resource group in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(@Nullable Output resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the resource group in which the Cosmos DB Mongo Collection is created. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param shardKey The name of the key to partition on for sharding. There must not be any other unique index keys. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder shardKey(@Nullable Output shardKey) {
            $.shardKey = shardKey;
            return this;
        }

        /**
         * @param shardKey The name of the key to partition on for sharding. There must not be any other unique index keys. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder shardKey(String shardKey) {
            return shardKey(Output.of(shardKey));
        }

        /**
         * @param systemIndexes One or more `system_indexes` blocks as defined below.
         * 
         * @return builder
         * 
         */
        public Builder systemIndexes(@Nullable Output> systemIndexes) {
            $.systemIndexes = systemIndexes;
            return this;
        }

        /**
         * @param systemIndexes One or more `system_indexes` blocks as defined below.
         * 
         * @return builder
         * 
         */
        public Builder systemIndexes(List systemIndexes) {
            return systemIndexes(Output.of(systemIndexes));
        }

        /**
         * @param systemIndexes One or more `system_indexes` blocks as defined below.
         * 
         * @return builder
         * 
         */
        public Builder systemIndexes(MongoCollectionSystemIndexArgs... systemIndexes) {
            return systemIndexes(List.of(systemIndexes));
        }

        public Builder throughput(@Nullable Output throughput) {
            $.throughput = throughput;
            return this;
        }

        public Builder throughput(Integer throughput) {
            return throughput(Output.of(throughput));
        }

        public MongoCollectionState build() {
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy