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

com.pulumi.azurenative.synapse.SqlPoolArgs Maven / Gradle / Ivy

There is a newer version: 2.72.0
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.azurenative.synapse;

import com.pulumi.azurenative.synapse.enums.CreateMode;
import com.pulumi.azurenative.synapse.enums.StorageAccountType;
import com.pulumi.azurenative.synapse.inputs.SkuArgs;
import com.pulumi.core.Either;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.core.internal.Codegen;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Double;
import java.lang.String;
import java.util.Map;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


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

    public static final SqlPoolArgs Empty = new SqlPoolArgs();

    /**
     * Collation mode
     * 
     */
    @Import(name="collation")
    private @Nullable Output collation;

    /**
     * @return Collation mode
     * 
     */
    public Optional> collation() {
        return Optional.ofNullable(this.collation);
    }

    /**
     * Specifies the mode of sql pool creation.
     * 
     * Default: regular sql pool creation.
     * 
     * PointInTimeRestore: Creates a sql pool by restoring a point in time backup of an existing sql pool. sourceDatabaseId must be specified as the resource ID of the existing sql pool, and restorePointInTime must be specified.
     * 
     * Recovery: Creates a sql pool by a geo-replicated backup. sourceDatabaseId  must be specified as the recoverableDatabaseId to restore.
     * 
     * Restore: Creates a sql pool by restoring a backup of a deleted sql  pool. SourceDatabaseId should be the sql pool's original resource ID. SourceDatabaseId and sourceDatabaseDeletionDate must be specified.
     * 
     */
    @Import(name="createMode")
    private @Nullable Output> createMode;

    /**
     * @return Specifies the mode of sql pool creation.
     * 
     * Default: regular sql pool creation.
     * 
     * PointInTimeRestore: Creates a sql pool by restoring a point in time backup of an existing sql pool. sourceDatabaseId must be specified as the resource ID of the existing sql pool, and restorePointInTime must be specified.
     * 
     * Recovery: Creates a sql pool by a geo-replicated backup. sourceDatabaseId  must be specified as the recoverableDatabaseId to restore.
     * 
     * Restore: Creates a sql pool by restoring a backup of a deleted sql  pool. SourceDatabaseId should be the sql pool's original resource ID. SourceDatabaseId and sourceDatabaseDeletionDate must be specified.
     * 
     */
    public Optional>> createMode() {
        return Optional.ofNullable(this.createMode);
    }

    /**
     * The geo-location where the resource lives
     * 
     */
    @Import(name="location")
    private @Nullable Output location;

    /**
     * @return The geo-location where the resource lives
     * 
     */
    public Optional> location() {
        return Optional.ofNullable(this.location);
    }

    /**
     * Maximum size in bytes
     * 
     */
    @Import(name="maxSizeBytes")
    private @Nullable Output maxSizeBytes;

    /**
     * @return Maximum size in bytes
     * 
     */
    public Optional> maxSizeBytes() {
        return Optional.ofNullable(this.maxSizeBytes);
    }

    /**
     * Resource state
     * 
     */
    @Import(name="provisioningState")
    private @Nullable Output provisioningState;

    /**
     * @return Resource state
     * 
     */
    public Optional> provisioningState() {
        return Optional.ofNullable(this.provisioningState);
    }

    /**
     * Backup database to restore from
     * 
     */
    @Import(name="recoverableDatabaseId")
    private @Nullable Output recoverableDatabaseId;

    /**
     * @return Backup database to restore from
     * 
     */
    public Optional> recoverableDatabaseId() {
        return Optional.ofNullable(this.recoverableDatabaseId);
    }

    /**
     * The name of the resource group. The name is case insensitive.
     * 
     */
    @Import(name="resourceGroupName", required=true)
    private Output resourceGroupName;

    /**
     * @return The name of the resource group. The name is case insensitive.
     * 
     */
    public Output resourceGroupName() {
        return this.resourceGroupName;
    }

    /**
     * Snapshot time to restore
     * 
     */
    @Import(name="restorePointInTime")
    private @Nullable Output restorePointInTime;

    /**
     * @return Snapshot time to restore
     * 
     */
    public Optional> restorePointInTime() {
        return Optional.ofNullable(this.restorePointInTime);
    }

    /**
     * SQL pool SKU
     * 
     */
    @Import(name="sku")
    private @Nullable Output sku;

    /**
     * @return SQL pool SKU
     * 
     */
    public Optional> sku() {
        return Optional.ofNullable(this.sku);
    }

    /**
     * Specifies the time that the sql pool was deleted
     * 
     */
    @Import(name="sourceDatabaseDeletionDate")
    private @Nullable Output sourceDatabaseDeletionDate;

    /**
     * @return Specifies the time that the sql pool was deleted
     * 
     */
    public Optional> sourceDatabaseDeletionDate() {
        return Optional.ofNullable(this.sourceDatabaseDeletionDate);
    }

    /**
     * Source database to create from
     * 
     */
    @Import(name="sourceDatabaseId")
    private @Nullable Output sourceDatabaseId;

    /**
     * @return Source database to create from
     * 
     */
    public Optional> sourceDatabaseId() {
        return Optional.ofNullable(this.sourceDatabaseId);
    }

    /**
     * SQL pool name
     * 
     */
    @Import(name="sqlPoolName")
    private @Nullable Output sqlPoolName;

    /**
     * @return SQL pool name
     * 
     */
    public Optional> sqlPoolName() {
        return Optional.ofNullable(this.sqlPoolName);
    }

    /**
     * The storage account type used to store backups for this sql pool.
     * 
     */
    @Import(name="storageAccountType")
    private @Nullable Output> storageAccountType;

    /**
     * @return The storage account type used to store backups for this sql pool.
     * 
     */
    public Optional>> storageAccountType() {
        return Optional.ofNullable(this.storageAccountType);
    }

    /**
     * Resource tags.
     * 
     */
    @Import(name="tags")
    private @Nullable Output> tags;

    /**
     * @return Resource tags.
     * 
     */
    public Optional>> tags() {
        return Optional.ofNullable(this.tags);
    }

    /**
     * The name of the workspace.
     * 
     */
    @Import(name="workspaceName", required=true)
    private Output workspaceName;

    /**
     * @return The name of the workspace.
     * 
     */
    public Output workspaceName() {
        return this.workspaceName;
    }

    private SqlPoolArgs() {}

    private SqlPoolArgs(SqlPoolArgs $) {
        this.collation = $.collation;
        this.createMode = $.createMode;
        this.location = $.location;
        this.maxSizeBytes = $.maxSizeBytes;
        this.provisioningState = $.provisioningState;
        this.recoverableDatabaseId = $.recoverableDatabaseId;
        this.resourceGroupName = $.resourceGroupName;
        this.restorePointInTime = $.restorePointInTime;
        this.sku = $.sku;
        this.sourceDatabaseDeletionDate = $.sourceDatabaseDeletionDate;
        this.sourceDatabaseId = $.sourceDatabaseId;
        this.sqlPoolName = $.sqlPoolName;
        this.storageAccountType = $.storageAccountType;
        this.tags = $.tags;
        this.workspaceName = $.workspaceName;
    }

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

    public static final class Builder {
        private SqlPoolArgs $;

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

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

        /**
         * @param collation Collation mode
         * 
         * @return builder
         * 
         */
        public Builder collation(@Nullable Output collation) {
            $.collation = collation;
            return this;
        }

        /**
         * @param collation Collation mode
         * 
         * @return builder
         * 
         */
        public Builder collation(String collation) {
            return collation(Output.of(collation));
        }

        /**
         * @param createMode Specifies the mode of sql pool creation.
         * 
         * Default: regular sql pool creation.
         * 
         * PointInTimeRestore: Creates a sql pool by restoring a point in time backup of an existing sql pool. sourceDatabaseId must be specified as the resource ID of the existing sql pool, and restorePointInTime must be specified.
         * 
         * Recovery: Creates a sql pool by a geo-replicated backup. sourceDatabaseId  must be specified as the recoverableDatabaseId to restore.
         * 
         * Restore: Creates a sql pool by restoring a backup of a deleted sql  pool. SourceDatabaseId should be the sql pool's original resource ID. SourceDatabaseId and sourceDatabaseDeletionDate must be specified.
         * 
         * @return builder
         * 
         */
        public Builder createMode(@Nullable Output> createMode) {
            $.createMode = createMode;
            return this;
        }

        /**
         * @param createMode Specifies the mode of sql pool creation.
         * 
         * Default: regular sql pool creation.
         * 
         * PointInTimeRestore: Creates a sql pool by restoring a point in time backup of an existing sql pool. sourceDatabaseId must be specified as the resource ID of the existing sql pool, and restorePointInTime must be specified.
         * 
         * Recovery: Creates a sql pool by a geo-replicated backup. sourceDatabaseId  must be specified as the recoverableDatabaseId to restore.
         * 
         * Restore: Creates a sql pool by restoring a backup of a deleted sql  pool. SourceDatabaseId should be the sql pool's original resource ID. SourceDatabaseId and sourceDatabaseDeletionDate must be specified.
         * 
         * @return builder
         * 
         */
        public Builder createMode(Either createMode) {
            return createMode(Output.of(createMode));
        }

        /**
         * @param createMode Specifies the mode of sql pool creation.
         * 
         * Default: regular sql pool creation.
         * 
         * PointInTimeRestore: Creates a sql pool by restoring a point in time backup of an existing sql pool. sourceDatabaseId must be specified as the resource ID of the existing sql pool, and restorePointInTime must be specified.
         * 
         * Recovery: Creates a sql pool by a geo-replicated backup. sourceDatabaseId  must be specified as the recoverableDatabaseId to restore.
         * 
         * Restore: Creates a sql pool by restoring a backup of a deleted sql  pool. SourceDatabaseId should be the sql pool's original resource ID. SourceDatabaseId and sourceDatabaseDeletionDate must be specified.
         * 
         * @return builder
         * 
         */
        public Builder createMode(String createMode) {
            return createMode(Either.ofLeft(createMode));
        }

        /**
         * @param createMode Specifies the mode of sql pool creation.
         * 
         * Default: regular sql pool creation.
         * 
         * PointInTimeRestore: Creates a sql pool by restoring a point in time backup of an existing sql pool. sourceDatabaseId must be specified as the resource ID of the existing sql pool, and restorePointInTime must be specified.
         * 
         * Recovery: Creates a sql pool by a geo-replicated backup. sourceDatabaseId  must be specified as the recoverableDatabaseId to restore.
         * 
         * Restore: Creates a sql pool by restoring a backup of a deleted sql  pool. SourceDatabaseId should be the sql pool's original resource ID. SourceDatabaseId and sourceDatabaseDeletionDate must be specified.
         * 
         * @return builder
         * 
         */
        public Builder createMode(CreateMode createMode) {
            return createMode(Either.ofRight(createMode));
        }

        /**
         * @param location The geo-location where the resource lives
         * 
         * @return builder
         * 
         */
        public Builder location(@Nullable Output location) {
            $.location = location;
            return this;
        }

        /**
         * @param location The geo-location where the resource lives
         * 
         * @return builder
         * 
         */
        public Builder location(String location) {
            return location(Output.of(location));
        }

        /**
         * @param maxSizeBytes Maximum size in bytes
         * 
         * @return builder
         * 
         */
        public Builder maxSizeBytes(@Nullable Output maxSizeBytes) {
            $.maxSizeBytes = maxSizeBytes;
            return this;
        }

        /**
         * @param maxSizeBytes Maximum size in bytes
         * 
         * @return builder
         * 
         */
        public Builder maxSizeBytes(Double maxSizeBytes) {
            return maxSizeBytes(Output.of(maxSizeBytes));
        }

        /**
         * @param provisioningState Resource state
         * 
         * @return builder
         * 
         */
        public Builder provisioningState(@Nullable Output provisioningState) {
            $.provisioningState = provisioningState;
            return this;
        }

        /**
         * @param provisioningState Resource state
         * 
         * @return builder
         * 
         */
        public Builder provisioningState(String provisioningState) {
            return provisioningState(Output.of(provisioningState));
        }

        /**
         * @param recoverableDatabaseId Backup database to restore from
         * 
         * @return builder
         * 
         */
        public Builder recoverableDatabaseId(@Nullable Output recoverableDatabaseId) {
            $.recoverableDatabaseId = recoverableDatabaseId;
            return this;
        }

        /**
         * @param recoverableDatabaseId Backup database to restore from
         * 
         * @return builder
         * 
         */
        public Builder recoverableDatabaseId(String recoverableDatabaseId) {
            return recoverableDatabaseId(Output.of(recoverableDatabaseId));
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(Output resourceGroupName) {
            $.resourceGroupName = resourceGroupName;
            return this;
        }

        /**
         * @param resourceGroupName The name of the resource group. The name is case insensitive.
         * 
         * @return builder
         * 
         */
        public Builder resourceGroupName(String resourceGroupName) {
            return resourceGroupName(Output.of(resourceGroupName));
        }

        /**
         * @param restorePointInTime Snapshot time to restore
         * 
         * @return builder
         * 
         */
        public Builder restorePointInTime(@Nullable Output restorePointInTime) {
            $.restorePointInTime = restorePointInTime;
            return this;
        }

        /**
         * @param restorePointInTime Snapshot time to restore
         * 
         * @return builder
         * 
         */
        public Builder restorePointInTime(String restorePointInTime) {
            return restorePointInTime(Output.of(restorePointInTime));
        }

        /**
         * @param sku SQL pool SKU
         * 
         * @return builder
         * 
         */
        public Builder sku(@Nullable Output sku) {
            $.sku = sku;
            return this;
        }

        /**
         * @param sku SQL pool SKU
         * 
         * @return builder
         * 
         */
        public Builder sku(SkuArgs sku) {
            return sku(Output.of(sku));
        }

        /**
         * @param sourceDatabaseDeletionDate Specifies the time that the sql pool was deleted
         * 
         * @return builder
         * 
         */
        public Builder sourceDatabaseDeletionDate(@Nullable Output sourceDatabaseDeletionDate) {
            $.sourceDatabaseDeletionDate = sourceDatabaseDeletionDate;
            return this;
        }

        /**
         * @param sourceDatabaseDeletionDate Specifies the time that the sql pool was deleted
         * 
         * @return builder
         * 
         */
        public Builder sourceDatabaseDeletionDate(String sourceDatabaseDeletionDate) {
            return sourceDatabaseDeletionDate(Output.of(sourceDatabaseDeletionDate));
        }

        /**
         * @param sourceDatabaseId Source database to create from
         * 
         * @return builder
         * 
         */
        public Builder sourceDatabaseId(@Nullable Output sourceDatabaseId) {
            $.sourceDatabaseId = sourceDatabaseId;
            return this;
        }

        /**
         * @param sourceDatabaseId Source database to create from
         * 
         * @return builder
         * 
         */
        public Builder sourceDatabaseId(String sourceDatabaseId) {
            return sourceDatabaseId(Output.of(sourceDatabaseId));
        }

        /**
         * @param sqlPoolName SQL pool name
         * 
         * @return builder
         * 
         */
        public Builder sqlPoolName(@Nullable Output sqlPoolName) {
            $.sqlPoolName = sqlPoolName;
            return this;
        }

        /**
         * @param sqlPoolName SQL pool name
         * 
         * @return builder
         * 
         */
        public Builder sqlPoolName(String sqlPoolName) {
            return sqlPoolName(Output.of(sqlPoolName));
        }

        /**
         * @param storageAccountType The storage account type used to store backups for this sql pool.
         * 
         * @return builder
         * 
         */
        public Builder storageAccountType(@Nullable Output> storageAccountType) {
            $.storageAccountType = storageAccountType;
            return this;
        }

        /**
         * @param storageAccountType The storage account type used to store backups for this sql pool.
         * 
         * @return builder
         * 
         */
        public Builder storageAccountType(Either storageAccountType) {
            return storageAccountType(Output.of(storageAccountType));
        }

        /**
         * @param storageAccountType The storage account type used to store backups for this sql pool.
         * 
         * @return builder
         * 
         */
        public Builder storageAccountType(String storageAccountType) {
            return storageAccountType(Either.ofLeft(storageAccountType));
        }

        /**
         * @param storageAccountType The storage account type used to store backups for this sql pool.
         * 
         * @return builder
         * 
         */
        public Builder storageAccountType(StorageAccountType storageAccountType) {
            return storageAccountType(Either.ofRight(storageAccountType));
        }

        /**
         * @param tags Resource tags.
         * 
         * @return builder
         * 
         */
        public Builder tags(@Nullable Output> tags) {
            $.tags = tags;
            return this;
        }

        /**
         * @param tags Resource tags.
         * 
         * @return builder
         * 
         */
        public Builder tags(Map tags) {
            return tags(Output.of(tags));
        }

        /**
         * @param workspaceName The name of the workspace.
         * 
         * @return builder
         * 
         */
        public Builder workspaceName(Output workspaceName) {
            $.workspaceName = workspaceName;
            return this;
        }

        /**
         * @param workspaceName The name of the workspace.
         * 
         * @return builder
         * 
         */
        public Builder workspaceName(String workspaceName) {
            return workspaceName(Output.of(workspaceName));
        }

        public SqlPoolArgs build() {
            $.collation = Codegen.stringProp("collation").output().arg($.collation).def("").getNullable();
            if ($.resourceGroupName == null) {
                throw new MissingRequiredPropertyException("SqlPoolArgs", "resourceGroupName");
            }
            $.storageAccountType = Codegen.stringProp("storageAccountType").left(StorageAccountType.class).output().arg($.storageAccountType).def("GRS").getNullable();
            if ($.workspaceName == null) {
                throw new MissingRequiredPropertyException("SqlPoolArgs", "workspaceName");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy