
com.pulumi.googlenative.logging.v2.kotlin.OrganizationExclusion.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of pulumi-google-native-kotlin Show documentation
Show all versions of pulumi-google-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.
The newest version!
@file:Suppress("NAME_SHADOWING", "DEPRECATION")
package com.pulumi.googlenative.logging.v2.kotlin
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
/**
* Builder for [OrganizationExclusion].
*/
@PulumiTagMarker
public class OrganizationExclusionResourceBuilder internal constructor() {
public var name: String? = null
public var args: OrganizationExclusionArgs = OrganizationExclusionArgs()
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 OrganizationExclusionArgsBuilder.() -> Unit) {
val builder = OrganizationExclusionArgsBuilder()
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(): OrganizationExclusion {
val builtJavaResource =
com.pulumi.googlenative.logging.v2.OrganizationExclusion(
this.name,
this.args.toJava(),
this.opts.toJava(),
)
return OrganizationExclusion(builtJavaResource)
}
}
/**
* Creates a new exclusion in the _Default sink in a specified parent resource. Only log entries belonging to that resource can be excluded. You can have up to 10 exclusions in a resource.
*/
public class OrganizationExclusion internal constructor(
override val javaResource: com.pulumi.googlenative.logging.v2.OrganizationExclusion,
) : KotlinCustomResource(javaResource, OrganizationExclusionMapper) {
/**
* The creation timestamp of the exclusion.This field may not be present for older exclusions.
*/
public val createTime: Output
get() = javaResource.createTime().applyValue({ args0 -> args0 })
/**
* Optional. A description of this exclusion.
*/
public val description: Output
get() = javaResource.description().applyValue({ args0 -> args0 })
/**
* Optional. If set to True, then this exclusion is disabled and it does not exclude any log entries. You can update an exclusion to change the value of this field.
*/
public val disabled: Output
get() = javaResource.disabled().applyValue({ args0 -> args0 })
/**
* An advanced logs filter (https://cloud.google.com/logging/docs/view/advanced-queries) that matches the log entries to be excluded. By using the sample function (https://cloud.google.com/logging/docs/view/advanced-queries#sample), you can exclude less than 100% of the matching log entries.For example, the following query matches 99% of low-severity log entries from Google Cloud Storage buckets:resource.type=gcs_bucket severity
get() = javaResource.filter().applyValue({ args0 -> args0 })
/**
* A client-assigned identifier, such as "load-balancer-exclusion". Identifiers are limited to 100 characters and can include only letters, digits, underscores, hyphens, and periods. First character has to be alphanumeric.
*/
public val name: Output
get() = javaResource.name().applyValue({ args0 -> args0 })
public val organizationId: Output
get() = javaResource.organizationId().applyValue({ args0 -> args0 })
/**
* The last update timestamp of the exclusion.This field may not be present for older exclusions.
*/
public val updateTime: Output
get() = javaResource.updateTime().applyValue({ args0 -> args0 })
}
public object OrganizationExclusionMapper : ResourceMapper {
override fun supportsMappingOfType(javaResource: Resource): Boolean =
com.pulumi.googlenative.logging.v2.OrganizationExclusion::class == javaResource::class
override fun map(javaResource: Resource): OrganizationExclusion =
OrganizationExclusion(
javaResource as
com.pulumi.googlenative.logging.v2.OrganizationExclusion,
)
}
/**
* @see [OrganizationExclusion].
* @param name The _unique_ name of the resulting resource.
* @param block Builder for [OrganizationExclusion].
*/
public suspend fun organizationExclusion(
name: String,
block: suspend OrganizationExclusionResourceBuilder.() -> Unit,
): OrganizationExclusion {
val builder = OrganizationExclusionResourceBuilder()
builder.name(name)
block(builder)
return builder.build()
}
/**
* @see [OrganizationExclusion].
* @param name The _unique_ name of the resulting resource.
*/
public fun organizationExclusion(name: String): OrganizationExclusion {
val builder = OrganizationExclusionResourceBuilder()
builder.name(name)
return builder.build()
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy