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

com.pulumi.azure.cosmosdb.SqlDatabaseArgs 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;

import com.pulumi.azure.cosmosdb.inputs.SqlDatabaseAutoscaleSettingsArgs;
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 SqlDatabaseArgs extends com.pulumi.resources.ResourceArgs {

    public static final SqlDatabaseArgs Empty = new SqlDatabaseArgs();

    /**
     * The name of the Cosmos DB SQL Database to create the table within. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="accountName", required=true)
    private Output accountName;

    /**
     * @return The name of the Cosmos DB SQL Database to create the table within. Changing this forces a new resource to be created.
     * 
     */
    public Output accountName() {
        return this.accountName;
    }

    /**
     * An `autoscale_settings` block as defined below. This must be set upon database creation otherwise it cannot be updated without a manual destroy-apply.
     * 
     * > **Note:** Switching between autoscale and manual throughput is not supported via this provider and must be completed via the Azure Portal and refreshed.
     * 
     */
    @Import(name="autoscaleSettings")
    private @Nullable Output autoscaleSettings;

    /**
     * @return An `autoscale_settings` block as defined below. This must be set upon database creation otherwise it cannot be updated without a manual destroy-apply.
     * 
     * > **Note:** Switching between autoscale and manual throughput is not supported via this provider and must be completed via the Azure Portal and refreshed.
     * 
     */
    public Optional> autoscaleSettings() {
        return Optional.ofNullable(this.autoscaleSettings);
    }

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

    /**
     * @return Specifies the name of the Cosmos DB SQL Database. 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 SQL Database is created. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="resourceGroupName", required=true)
    private Output resourceGroupName;

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

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

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

    private SqlDatabaseArgs() {}

    private SqlDatabaseArgs(SqlDatabaseArgs $) {
        this.accountName = $.accountName;
        this.autoscaleSettings = $.autoscaleSettings;
        this.name = $.name;
        this.resourceGroupName = $.resourceGroupName;
        this.throughput = $.throughput;
    }

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

    public static final class Builder {
        private SqlDatabaseArgs $;

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

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

        /**
         * @param accountName The name of the Cosmos DB SQL Database to create the table within. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder accountName(Output accountName) {
            $.accountName = accountName;
            return this;
        }

        /**
         * @param accountName The name of the Cosmos DB SQL Database to create the table within. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder accountName(String accountName) {
            return accountName(Output.of(accountName));
        }

        /**
         * @param autoscaleSettings An `autoscale_settings` block as defined below. This must be set upon database creation otherwise it cannot be updated without a manual destroy-apply.
         * 
         * > **Note:** Switching between autoscale and manual throughput is not supported via this provider and must be completed via the Azure Portal and refreshed.
         * 
         * @return builder
         * 
         */
        public Builder autoscaleSettings(@Nullable Output autoscaleSettings) {
            $.autoscaleSettings = autoscaleSettings;
            return this;
        }

        /**
         * @param autoscaleSettings An `autoscale_settings` block as defined below. This must be set upon database creation otherwise it cannot be updated without a manual destroy-apply.
         * 
         * > **Note:** Switching between autoscale and manual throughput is not supported via this provider and must be completed via the Azure Portal and refreshed.
         * 
         * @return builder
         * 
         */
        public Builder autoscaleSettings(SqlDatabaseAutoscaleSettingsArgs autoscaleSettings) {
            return autoscaleSettings(Output.of(autoscaleSettings));
        }

        /**
         * @param name Specifies the name of the Cosmos DB SQL Database. 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 SQL Database. 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 SQL Database is created. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(Output resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

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

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

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

        public SqlDatabaseArgs build() {
            if ($.accountName == null) {
                throw new MissingRequiredPropertyException("SqlDatabaseArgs", "accountName");
            }
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("SqlDatabaseArgs", "resourceGroupName");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy