Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.redshift.kotlin
import com.pulumi.awsnative.kotlin.outputs.Tag
import com.pulumi.awsnative.redshift.kotlin.outputs.ClusterEndpoint
import com.pulumi.awsnative.redshift.kotlin.outputs.ClusterLoggingProperties
import com.pulumi.core.Output
import com.pulumi.kotlin.KotlinCustomResource
import com.pulumi.kotlin.PulumiTagMarker
import com.pulumi.kotlin.ResourceMapper
import com.pulumi.kotlin.options.CustomResourceOptions
import com.pulumi.kotlin.options.CustomResourceOptionsBuilder
import com.pulumi.resources.Resource
import kotlin.Any
import kotlin.Boolean
import kotlin.Int
import kotlin.String
import kotlin.Suppress
import kotlin.Unit
import kotlin.collections.List
import com.pulumi.awsnative.kotlin.outputs.Tag.Companion.toKotlin as tagToKotlin
import com.pulumi.awsnative.redshift.kotlin.outputs.ClusterEndpoint.Companion.toKotlin as clusterEndpointToKotlin
import com.pulumi.awsnative.redshift.kotlin.outputs.ClusterLoggingProperties.Companion.toKotlin as clusterLoggingPropertiesToKotlin
/**
* Builder for [Cluster].
*/
@PulumiTagMarker
public class ClusterResourceBuilder internal constructor() {
public var name: String? = null
public var args: ClusterArgs = ClusterArgs()
public var opts: CustomResourceOptions = CustomResourceOptions()
/**
* @param name The _unique_ name of the resulting resource.
*/
public fun name(`value`: String) {
this.name = value
}
/**
* @param block The arguments to use to populate this resource's properties.
*/
public suspend fun args(block: suspend ClusterArgsBuilder.() -> Unit) {
val builder = ClusterArgsBuilder()
block(builder)
this.args = builder.build()
}
/**
* @param block A bag of options that control this resource's behavior.
*/
public suspend fun opts(block: suspend CustomResourceOptionsBuilder.() -> Unit) {
this.opts = com.pulumi.kotlin.options.CustomResourceOptions.opts(block)
}
internal fun build(): Cluster {
val builtJavaResource = com.pulumi.awsnative.redshift.Cluster(
this.name,
this.args.toJava(),
this.opts.toJava(),
)
return Cluster(builtJavaResource)
}
}
/**
* An example resource schema demonstrating some basic constructs and validation rules.
*/
public class Cluster internal constructor(
override val javaResource: com.pulumi.awsnative.redshift.Cluster,
) : KotlinCustomResource(javaResource, ClusterMapper) {
/**
* Major version upgrades can be applied during the maintenance window to the Amazon Redshift engine that is running on the cluster. Default value is True
*/
public val allowVersionUpgrade: Output?
get() = javaResource.allowVersionUpgrade().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The value represents how the cluster is configured to use AQUA (Advanced Query Accelerator) after the cluster is restored. Possible values include the following.
* enabled - Use AQUA if it is available for the current Region and Amazon Redshift node type.
* disabled - Don't use AQUA.
* auto - Amazon Redshift determines whether to use AQUA.
*/
public val aquaConfigurationStatus: Output?
get() = javaResource.aquaConfigurationStatus().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The number of days that automated snapshots are retained. If the value is 0, automated snapshots are disabled. Default value is 1
*/
public val automatedSnapshotRetentionPeriod: Output?
get() = javaResource.automatedSnapshotRetentionPeriod().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The EC2 Availability Zone (AZ) in which you want Amazon Redshift to provision the cluster. Default: A random, system-chosen Availability Zone in the region that is specified by the endpoint
*/
public val availabilityZone: Output?
get() = javaResource.availabilityZone().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The option to enable relocation for an Amazon Redshift cluster between Availability Zones after the cluster modification is complete.
*/
public val availabilityZoneRelocation: Output?
get() = javaResource.availabilityZoneRelocation().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The availability zone relocation status of the cluster
*/
public val availabilityZoneRelocationStatus: Output?
get() = javaResource.availabilityZoneRelocationStatus().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* A boolean value indicating whether the resize operation is using the classic resize process. If you don't provide this parameter or set the value to false , the resize type is elastic.
*/
public val classic: Output?
get() = javaResource.classic().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* A unique identifier for the cluster. You use this identifier to refer to the cluster for any subsequent cluster operations such as deleting or modifying. All alphabetical characters must be lower case, no hypens at the end, no two consecutive hyphens. Cluster name should be unique for all clusters within an AWS account
*/
public val clusterIdentifier: Output?
get() = javaResource.clusterIdentifier().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The Amazon Resource Name (ARN) of the cluster namespace.
*/
public val clusterNamespaceArn: Output
get() = javaResource.clusterNamespaceArn().applyValue({ args0 -> args0 })
/**
* The name of the parameter group to be associated with this cluster.
*/
public val clusterParameterGroupName: Output?
get() = javaResource.clusterParameterGroupName().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* A list of security groups to be associated with this cluster.
*/
public val clusterSecurityGroups: Output>?
get() = javaResource.clusterSecurityGroups().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 -> args0 })
}).orElse(null)
})
/**
* The name of a cluster subnet group to be associated with this cluster.
*/
public val clusterSubnetGroupName: Output?
get() = javaResource.clusterSubnetGroupName().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The type of the cluster. When cluster type is specified as single-node, the NumberOfNodes parameter is not required and if multi-node, the NumberOfNodes parameter is required
*/
public val clusterType: Output
get() = javaResource.clusterType().applyValue({ args0 -> args0 })
/**
* The version of the Amazon Redshift engine software that you want to deploy on the cluster.The version selected runs on all the nodes in the cluster.
*/
public val clusterVersion: Output?
get() = javaResource.clusterVersion().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The name of the first database to be created when the cluster is created. To create additional databases after the cluster is created, connect to the cluster with a SQL client and use SQL commands to create a database.
*/
public val dbName: Output
get() = javaResource.dbName().applyValue({ args0 -> args0 })
/**
* A boolean indicating whether to enable the deferred maintenance window.
*/
public val deferMaintenance: Output?
get() = javaResource.deferMaintenance().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* An integer indicating the duration of the maintenance window in days. If you specify a duration, you can't specify an end time. The duration must be 45 days or less.
*/
public val deferMaintenanceDuration: Output?
get() = javaResource.deferMaintenanceDuration().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* A timestamp indicating end time for the deferred maintenance window. If you specify an end time, you can't specify a duration.
*/
public val deferMaintenanceEndTime: Output?
get() = javaResource.deferMaintenanceEndTime().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* A unique identifier for the deferred maintenance window.
*/
public val deferMaintenanceIdentifier: Output
get() = javaResource.deferMaintenanceIdentifier().applyValue({ args0 -> args0 })
/**
* A timestamp indicating the start time for the deferred maintenance window.
*/
public val deferMaintenanceStartTime: Output?
get() = javaResource.deferMaintenanceStartTime().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The destination AWS Region that you want to copy snapshots to. Constraints: Must be the name of a valid AWS Region. For more information, see Regions and Endpoints in the Amazon Web Services [https://docs.aws.amazon.com/general/latest/gr/rande.html#redshift_region] General Reference
*/
public val destinationRegion: Output?
get() = javaResource.destinationRegion().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The Elastic IP (EIP) address for the cluster.
*/
public val elasticIp: Output?
get() = javaResource.elasticIp().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* If true, the data in the cluster is encrypted at rest.
*/
public val encrypted: Output?
get() = javaResource.encrypted().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* The connection endpoint.
*/
public val endpoint: Output?
get() = javaResource.endpoint().applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 ->
clusterEndpointToKotlin(args0)
})
}).orElse(null)
})
/**
* An option that specifies whether to create the cluster with enhanced VPC routing enabled. To create a cluster that uses enhanced VPC routing, the cluster must be in a VPC. For more information, see Enhanced VPC Routing in the Amazon Redshift Cluster Management Guide.
* If this option is true , enhanced VPC routing is enabled.
* Default: false
*/
public val enhancedVpcRouting: Output?
get() = javaResource.enhancedVpcRouting().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* Specifies the name of the HSM client certificate the Amazon Redshift cluster uses to retrieve the data encryption keys stored in an HSM
*/
public val hsmClientCertificateIdentifier: Output?
get() = javaResource.hsmClientCertificateIdentifier().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* Specifies the name of the HSM configuration that contains the information the Amazon Redshift cluster can use to retrieve and store keys in an HSM.
*/
public val hsmConfigurationIdentifier: Output?
get() = javaResource.hsmConfigurationIdentifier().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* A list of AWS Identity and Access Management (IAM) roles that can be used by the cluster to access other AWS services. You must supply the IAM roles in their Amazon Resource Name (ARN) format. You can supply up to 50 IAM roles in a single request
*/
public val iamRoles: Output>?
get() = javaResource.iamRoles().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 ->
args0
})
}).orElse(null)
})
/**
* The AWS Key Management Service (KMS) key ID of the encryption key that you want to use to encrypt data in the cluster.
*/
public val kmsKeyId: Output?
get() = javaResource.kmsKeyId().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* Specifies logging information, such as queries and connection attempts, for the specified Amazon Redshift cluster.
*/
public val loggingProperties: Output?
get() = javaResource.loggingProperties().applyValue({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> clusterLoggingPropertiesToKotlin(args0) })
}).orElse(null)
})
/**
* The name for the maintenance track that you want to assign for the cluster. This name change is asynchronous. The new track name stays in the PendingModifiedValues for the cluster until the next maintenance window. When the maintenance track changes, the cluster is switched to the latest cluster release available for the maintenance track. At this point, the maintenance track name is applied.
*/
public val maintenanceTrackName: Output?
get() = javaResource.maintenanceTrackName().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* A boolean indicating if the redshift cluster's admin user credentials is managed by Redshift or not. You can't use MasterUserPassword if ManageMasterPassword is true. If ManageMasterPassword is false or not set, Amazon Redshift uses MasterUserPassword for the admin user account's password.
*/
public val manageMasterPassword: Output?
get() = javaResource.manageMasterPassword().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The number of days to retain newly copied snapshots in the destination AWS Region after they are copied from the source AWS Region. If the value is -1, the manual snapshot is retained indefinitely.
* The value must be either -1 or an integer between 1 and 3,653.
*/
public val manualSnapshotRetentionPeriod: Output?
get() = javaResource.manualSnapshotRetentionPeriod().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The Amazon Resource Name (ARN) for the cluster's admin user credentials secret.
*/
public val masterPasswordSecretArn: Output
get() = javaResource.masterPasswordSecretArn().applyValue({ args0 -> args0 })
/**
* The ID of the Key Management Service (KMS) key used to encrypt and store the cluster's admin user credentials secret.
*/
public val masterPasswordSecretKmsKeyId: Output?
get() = javaResource.masterPasswordSecretKmsKeyId().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The password associated with the master user account for the cluster that is being created. You can't use MasterUserPassword if ManageMasterPassword is true. Password must be between 8 and 64 characters in length, should have at least one uppercase letter.Must contain at least one lowercase letter.Must contain one number.Can be any printable ASCII character.
*/
public val masterUserPassword: Output?
get() = javaResource.masterUserPassword().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The user name associated with the master user account for the cluster that is being created. The user name can't be PUBLIC and first character must be a letter.
*/
public val masterUsername: Output
get() = javaResource.masterUsername().applyValue({ args0 -> args0 })
/**
* A boolean indicating if the redshift cluster is multi-az or not. If you don't provide this parameter or set the value to false, the redshift cluster will be single-az.
*/
public val multiAz: Output?
get() = javaResource.multiAz().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* The namespace resource policy document that will be attached to a Redshift cluster.
* Search the [CloudFormation User Guide](https://docs.aws.amazon.com/cloudformation/) for `AWS::Redshift::Cluster` for more information about the expected schema for this property.
*/
public val namespaceResourcePolicy: Output?
get() = javaResource.namespaceResourcePolicy().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The node type to be provisioned for the cluster.Valid Values: ds2.xlarge | ds2.8xlarge | dc1.large | dc1.8xlarge | dc2.large | dc2.8xlarge | ra3.4xlarge | ra3.16xlarge
*/
public val nodeType: Output
get() = javaResource.nodeType().applyValue({ args0 -> args0 })
/**
* The number of compute nodes in the cluster. This parameter is required when the ClusterType parameter is specified as multi-node.
*/
public val numberOfNodes: Output?
get() = javaResource.numberOfNodes().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The AWS account used to create or copy the snapshot. Required if you are restoring a snapshot you do not own, optional if you own the snapshot.
*/
public val ownerAccount: Output?
get() = javaResource.ownerAccount().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The port number on which the cluster accepts incoming connections. The cluster is accessible only via the JDBC and ODBC connection strings
*/
public val port: Output?
get() = javaResource.port().applyValue({ args0 -> args0.map({ args0 -> args0 }).orElse(null) })
/**
* The weekly time range (in UTC) during which automated cluster maintenance can occur.
*/
public val preferredMaintenanceWindow: Output?
get() = javaResource.preferredMaintenanceWindow().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* If true, the cluster can be accessed from a public network.
*/
public val publiclyAccessible: Output?
get() = javaResource.publiclyAccessible().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The Redshift operation to be performed. Resource Action supports pause-cluster, resume-cluster, failover-primary-compute APIs
*/
public val resourceAction: Output?
get() = javaResource.resourceAction().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The identifier of the database revision. You can retrieve this value from the response to the DescribeClusterDbRevisions request.
*/
public val revisionTarget: Output?
get() = javaResource.revisionTarget().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* A boolean indicating if we want to rotate Encryption Keys.
*/
public val rotateEncryptionKey: Output?
get() = javaResource.rotateEncryptionKey().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The name of the cluster the source snapshot was created from. This parameter is required if your IAM user has a policy containing a snapshot resource element that specifies anything other than * for the cluster name.
*/
public val snapshotClusterIdentifier: Output?
get() = javaResource.snapshotClusterIdentifier().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The name of the snapshot copy grant to use when snapshots of an AWS KMS-encrypted cluster are copied to the destination region.
*/
public val snapshotCopyGrantName: Output?
get() = javaResource.snapshotCopyGrantName().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* Indicates whether to apply the snapshot retention period to newly copied manual snapshots instead of automated snapshots.
*/
public val snapshotCopyManual: Output?
get() = javaResource.snapshotCopyManual().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The number of days to retain automated snapshots in the destination region after they are copied from the source region.
* Default is 7.
* Constraints: Must be at least 1 and no more than 35.
*/
public val snapshotCopyRetentionPeriod: Output?
get() = javaResource.snapshotCopyRetentionPeriod().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The name of the snapshot from which to create the new cluster. This parameter isn't case sensitive.
*/
public val snapshotIdentifier: Output?
get() = javaResource.snapshotIdentifier().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The list of tags for the cluster parameter group.
*/
public val tags: Output>?
get() = javaResource.tags().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> tagToKotlin(args0) })
})
}).orElse(null)
})
/**
* A list of Virtual Private Cloud (VPC) security groups to be associated with the cluster.
*/
public val vpcSecurityGroupIds: Output>?
get() = javaResource.vpcSecurityGroupIds().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 -> args0 })
}).orElse(null)
})
}
public object ClusterMapper : ResourceMapper {
override fun supportsMappingOfType(javaResource: Resource): Boolean =
com.pulumi.awsnative.redshift.Cluster::class == javaResource::class
override fun map(javaResource: Resource): Cluster = Cluster(
javaResource as
com.pulumi.awsnative.redshift.Cluster,
)
}
/**
* @see [Cluster].
* @param name The _unique_ name of the resulting resource.
* @param block Builder for [Cluster].
*/
public suspend fun cluster(name: String, block: suspend ClusterResourceBuilder.() -> Unit): Cluster {
val builder = ClusterResourceBuilder()
builder.name(name)
block(builder)
return builder.build()
}
/**
* @see [Cluster].
* @param name The _unique_ name of the resulting resource.
*/
public fun cluster(name: String): Cluster {
val builder = ClusterResourceBuilder()
builder.name(name)
return builder.build()
}