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

com.pulumi.azure.cosmosdb.inputs.AccountRestoreArgs 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.AccountRestoreDatabaseArgs;
import com.pulumi.azure.cosmosdb.inputs.AccountRestoreGremlinDatabaseArgs;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final AccountRestoreArgs Empty = new AccountRestoreArgs();

    /**
     * A `database` block as defined below. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="databases")
    private @Nullable Output> databases;

    /**
     * @return A `database` block as defined below. Changing this forces a new resource to be created.
     * 
     */
    public Optional>> databases() {
        return Optional.ofNullable(this.databases);
    }

    /**
     * One or more `gremlin_database` blocks as defined below. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="gremlinDatabases")
    private @Nullable Output> gremlinDatabases;

    /**
     * @return One or more `gremlin_database` blocks as defined below. Changing this forces a new resource to be created.
     * 
     */
    public Optional>> gremlinDatabases() {
        return Optional.ofNullable(this.gremlinDatabases);
    }

    /**
     * The creation time of the database or the collection (Datetime Format `RFC 3339`). Changing this forces a new resource to be created.
     * 
     */
    @Import(name="restoreTimestampInUtc", required=true)
    private Output restoreTimestampInUtc;

    /**
     * @return The creation time of the database or the collection (Datetime Format `RFC 3339`). Changing this forces a new resource to be created.
     * 
     */
    public Output restoreTimestampInUtc() {
        return this.restoreTimestampInUtc;
    }

    /**
     * The resource ID of the restorable database account from which the restore has to be initiated. The example is `/subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{restorableDatabaseAccountName}`. Changing this forces a new resource to be created.
     * 
     * > **Note:** Any database account with `Continuous` type (live account or accounts deleted in last 30 days) is a restorable database account and there cannot be Create/Update/Delete operations on the restorable database accounts. They can only be read and retrieved by `azure.cosmosdb.getRestorableDatabaseAccounts`.
     * 
     */
    @Import(name="sourceCosmosdbAccountId", required=true)
    private Output sourceCosmosdbAccountId;

    /**
     * @return The resource ID of the restorable database account from which the restore has to be initiated. The example is `/subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{restorableDatabaseAccountName}`. Changing this forces a new resource to be created.
     * 
     * > **Note:** Any database account with `Continuous` type (live account or accounts deleted in last 30 days) is a restorable database account and there cannot be Create/Update/Delete operations on the restorable database accounts. They can only be read and retrieved by `azure.cosmosdb.getRestorableDatabaseAccounts`.
     * 
     */
    public Output sourceCosmosdbAccountId() {
        return this.sourceCosmosdbAccountId;
    }

    /**
     * A list of specific tables available for restore. Changing this forces a new resource to be created.
     * 
     */
    @Import(name="tablesToRestores")
    private @Nullable Output> tablesToRestores;

    /**
     * @return A list of specific tables available for restore. Changing this forces a new resource to be created.
     * 
     */
    public Optional>> tablesToRestores() {
        return Optional.ofNullable(this.tablesToRestores);
    }

    private AccountRestoreArgs() {}

    private AccountRestoreArgs(AccountRestoreArgs $) {
        this.databases = $.databases;
        this.gremlinDatabases = $.gremlinDatabases;
        this.restoreTimestampInUtc = $.restoreTimestampInUtc;
        this.sourceCosmosdbAccountId = $.sourceCosmosdbAccountId;
        this.tablesToRestores = $.tablesToRestores;
    }

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

    public static final class Builder {
        private AccountRestoreArgs $;

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

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

        /**
         * @param databases A `database` block as defined below. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder databases(@Nullable Output> databases) {
            $.databases = databases;
            return this;
        }

        /**
         * @param databases A `database` block as defined below. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder databases(List databases) {
            return databases(Output.of(databases));
        }

        /**
         * @param databases A `database` block as defined below. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder databases(AccountRestoreDatabaseArgs... databases) {
            return databases(List.of(databases));
        }

        /**
         * @param gremlinDatabases One or more `gremlin_database` blocks as defined below. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder gremlinDatabases(@Nullable Output> gremlinDatabases) {
            $.gremlinDatabases = gremlinDatabases;
            return this;
        }

        /**
         * @param gremlinDatabases One or more `gremlin_database` blocks as defined below. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder gremlinDatabases(List gremlinDatabases) {
            return gremlinDatabases(Output.of(gremlinDatabases));
        }

        /**
         * @param gremlinDatabases One or more `gremlin_database` blocks as defined below. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder gremlinDatabases(AccountRestoreGremlinDatabaseArgs... gremlinDatabases) {
            return gremlinDatabases(List.of(gremlinDatabases));
        }

        /**
         * @param restoreTimestampInUtc The creation time of the database or the collection (Datetime Format `RFC 3339`). Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder restoreTimestampInUtc(Output restoreTimestampInUtc) {
            $.restoreTimestampInUtc = restoreTimestampInUtc;
            return this;
        }

        /**
         * @param restoreTimestampInUtc The creation time of the database or the collection (Datetime Format `RFC 3339`). Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder restoreTimestampInUtc(String restoreTimestampInUtc) {
            return restoreTimestampInUtc(Output.of(restoreTimestampInUtc));
        }

        /**
         * @param sourceCosmosdbAccountId The resource ID of the restorable database account from which the restore has to be initiated. The example is `/subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{restorableDatabaseAccountName}`. Changing this forces a new resource to be created.
         * 
         * > **Note:** Any database account with `Continuous` type (live account or accounts deleted in last 30 days) is a restorable database account and there cannot be Create/Update/Delete operations on the restorable database accounts. They can only be read and retrieved by `azure.cosmosdb.getRestorableDatabaseAccounts`.
         * 
         * @return builder
         * 
         */
        public Builder sourceCosmosdbAccountId(Output sourceCosmosdbAccountId) {
            $.sourceCosmosdbAccountId = sourceCosmosdbAccountId;
            return this;
        }

        /**
         * @param sourceCosmosdbAccountId The resource ID of the restorable database account from which the restore has to be initiated. The example is `/subscriptions/{subscriptionId}/providers/Microsoft.DocumentDB/locations/{location}/restorableDatabaseAccounts/{restorableDatabaseAccountName}`. Changing this forces a new resource to be created.
         * 
         * > **Note:** Any database account with `Continuous` type (live account or accounts deleted in last 30 days) is a restorable database account and there cannot be Create/Update/Delete operations on the restorable database accounts. They can only be read and retrieved by `azure.cosmosdb.getRestorableDatabaseAccounts`.
         * 
         * @return builder
         * 
         */
        public Builder sourceCosmosdbAccountId(String sourceCosmosdbAccountId) {
            return sourceCosmosdbAccountId(Output.of(sourceCosmosdbAccountId));
        }

        /**
         * @param tablesToRestores A list of specific tables available for restore. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder tablesToRestores(@Nullable Output> tablesToRestores) {
            $.tablesToRestores = tablesToRestores;
            return this;
        }

        /**
         * @param tablesToRestores A list of specific tables available for restore. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder tablesToRestores(List tablesToRestores) {
            return tablesToRestores(Output.of(tablesToRestores));
        }

        /**
         * @param tablesToRestores A list of specific tables available for restore. Changing this forces a new resource to be created.
         * 
         * @return builder
         * 
         */
        public Builder tablesToRestores(String... tablesToRestores) {
            return tablesToRestores(List.of(tablesToRestores));
        }

        public AccountRestoreArgs build() {
            if ($.restoreTimestampInUtc == null) {
                throw new MissingRequiredPropertyException("AccountRestoreArgs", "restoreTimestampInUtc");
            }
            if ($.sourceCosmosdbAccountId == null) {
                throw new MissingRequiredPropertyException("AccountRestoreArgs", "sourceCosmosdbAccountId");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy