
com.pulumi.awsnative.qldb.kotlin.Stream.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-aws-native-kotlin Show documentation
Show all versions of pulumi-aws-native-kotlin Show documentation
Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.awsnative.qldb.kotlin
import com.pulumi.awsnative.kotlin.outputs.Tag
import com.pulumi.awsnative.qldb.kotlin.outputs.StreamKinesisConfiguration
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.Boolean
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.qldb.kotlin.outputs.StreamKinesisConfiguration.Companion.toKotlin as streamKinesisConfigurationToKotlin
/**
* Builder for [Stream].
*/
@PulumiTagMarker
public class StreamResourceBuilder internal constructor() {
public var name: String? = null
public var args: StreamArgs = StreamArgs()
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 StreamArgsBuilder.() -> Unit) {
val builder = StreamArgsBuilder()
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(): Stream {
val builtJavaResource = com.pulumi.awsnative.qldb.Stream(
this.name,
this.args.toJava(),
this.opts.toJava(),
)
return Stream(builtJavaResource)
}
}
/**
* Resource schema for AWS::QLDB::Stream.
* ## Example Usage
* ### Example
* No Java example available.
* ### Example
* No Java example available.
*/
public class Stream internal constructor(
override val javaResource: com.pulumi.awsnative.qldb.Stream,
) : KotlinCustomResource(javaResource, StreamMapper) {
/**
* The Amazon Resource Name (ARN) of the QLDB journal stream. For example: `arn:aws:qldb:us-east-1:123456789012:stream/exampleLedger/IiPT4brpZCqCq3f4MTHbYy` .
*/
public val arn: Output
get() = javaResource.arn().applyValue({ args0 -> args0 })
/**
* The unique ID that QLDB assigns to each QLDB journal stream. For example: `IiPT4brpZCqCq3f4MTHbYy` .
*/
public val awsId: Output
get() = javaResource.awsId().applyValue({ args0 -> args0 })
/**
* The exclusive date and time that specifies when the stream ends. If you don't define this parameter, the stream runs indefinitely until you cancel it.
* The `ExclusiveEndTime` must be in `ISO 8601` date and time format and in Universal Coordinated Time (UTC). For example: `2019-06-13T21:36:34Z` .
*/
public val exclusiveEndTime: Output?
get() = javaResource.exclusiveEndTime().applyValue({ args0 ->
args0.map({ args0 ->
args0
}).orElse(null)
})
/**
* The inclusive start date and time from which to start streaming journal data. This parameter must be in `ISO 8601` date and time format and in Universal Coordinated Time (UTC). For example: `2019-06-13T21:36:34Z` .
* The `InclusiveStartTime` cannot be in the future and must be before `ExclusiveEndTime` .
* If you provide an `InclusiveStartTime` that is before the ledger's `CreationDateTime` , QLDB effectively defaults it to the ledger's `CreationDateTime` .
*/
public val inclusiveStartTime: Output
get() = javaResource.inclusiveStartTime().applyValue({ args0 -> args0 })
/**
* The configuration settings of the Kinesis Data Streams destination for your stream request.
*/
public val kinesisConfiguration: Output
get() = javaResource.kinesisConfiguration().applyValue({ args0 ->
args0.let({ args0 ->
streamKinesisConfigurationToKotlin(args0)
})
})
/**
* The name of the ledger.
*/
public val ledgerName: Output
get() = javaResource.ledgerName().applyValue({ args0 -> args0 })
/**
* The Amazon Resource Name (ARN) of the IAM role that grants QLDB permissions for a journal stream to write data records to a Kinesis Data Streams resource.
* To pass a role to QLDB when requesting a journal stream, you must have permissions to perform the `iam:PassRole` action on the IAM role resource. This is required for all journal stream requests.
*/
public val roleArn: Output
get() = javaResource.roleArn().applyValue({ args0 -> args0 })
/**
* The name that you want to assign to the QLDB journal stream. User-defined names can help identify and indicate the purpose of a stream.
* Your stream name must be unique among other *active* streams for a given ledger. Stream names have the same naming constraints as ledger names, as defined in [Quotas in Amazon QLDB](https://docs.aws.amazon.com/qldb/latest/developerguide/limits.html#limits.naming) in the *Amazon QLDB Developer Guide* .
*/
public val streamName: Output
get() = javaResource.streamName().applyValue({ args0 -> args0 })
/**
* An array of key-value pairs to apply to this resource.
*/
public val tags: Output>?
get() = javaResource.tags().applyValue({ args0 ->
args0.map({ args0 ->
args0.map({ args0 ->
args0.let({ args0 -> tagToKotlin(args0) })
})
}).orElse(null)
})
}
public object StreamMapper : ResourceMapper {
override fun supportsMappingOfType(javaResource: Resource): Boolean =
com.pulumi.awsnative.qldb.Stream::class == javaResource::class
override fun map(javaResource: Resource): Stream = Stream(
javaResource as
com.pulumi.awsnative.qldb.Stream,
)
}
/**
* @see [Stream].
* @param name The _unique_ name of the resulting resource.
* @param block Builder for [Stream].
*/
public suspend fun stream(name: String, block: suspend StreamResourceBuilder.() -> Unit): Stream {
val builder = StreamResourceBuilder()
builder.name(name)
block(builder)
return builder.build()
}
/**
* @see [Stream].
* @param name The _unique_ name of the resulting resource.
*/
public fun stream(name: String): Stream {
val builder = StreamResourceBuilder()
builder.name(name)
return builder.build()
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy