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

com.pulumi.gcp.vertex.kotlin.AiMetadataStore.kt Maven / Gradle / Ivy

Go to download

Build cloud applications and infrastructure by combining the safety and reliability of infrastructure as code with the power of the Kotlin programming language.

There is a newer version: 8.12.0.0
Show newest version
@file:Suppress("NAME_SHADOWING", "DEPRECATION")

package com.pulumi.gcp.vertex.kotlin

import com.pulumi.core.Output
import com.pulumi.gcp.vertex.kotlin.outputs.AiMetadataStoreEncryptionSpec
import com.pulumi.gcp.vertex.kotlin.outputs.AiMetadataStoreState
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.gcp.vertex.kotlin.outputs.AiMetadataStoreEncryptionSpec.Companion.toKotlin as aiMetadataStoreEncryptionSpecToKotlin
import com.pulumi.gcp.vertex.kotlin.outputs.AiMetadataStoreState.Companion.toKotlin as aiMetadataStoreStateToKotlin

/**
 * Builder for [AiMetadataStore].
 */
@PulumiTagMarker
public class AiMetadataStoreResourceBuilder internal constructor() {
    public var name: String? = null

    public var args: AiMetadataStoreArgs = AiMetadataStoreArgs()

    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 AiMetadataStoreArgsBuilder.() -> Unit) {
        val builder = AiMetadataStoreArgsBuilder()
        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(): AiMetadataStore {
        val builtJavaResource = com.pulumi.gcp.vertex.AiMetadataStore(
            this.name,
            this.args.toJava(),
            this.opts.toJava(),
        )
        return AiMetadataStore(builtJavaResource)
    }
}

/**
 * ## Example Usage
 * ### Vertex Ai Metadata Store
 * 
 * ```typescript
 * import * as pulumi from "@pulumi/pulumi";
 * import * as gcp from "@pulumi/gcp";
 * const store = new gcp.vertex.AiMetadataStore("store", {
 *     name: "test-store",
 *     description: "Store to test the terraform module",
 *     region: "us-central1",
 * });
 * ```
 * ```python
 * import pulumi
 * import pulumi_gcp as gcp
 * store = gcp.vertex.AiMetadataStore("store",
 *     name="test-store",
 *     description="Store to test the terraform module",
 *     region="us-central1")
 * ```
 * ```csharp
 * using System.Collections.Generic;
 * using System.Linq;
 * using Pulumi;
 * using Gcp = Pulumi.Gcp;
 * return await Deployment.RunAsync(() =>
 * {
 *     var store = new Gcp.Vertex.AiMetadataStore("store", new()
 *     {
 *         Name = "test-store",
 *         Description = "Store to test the terraform module",
 *         Region = "us-central1",
 *     });
 * });
 * ```
 * ```go
 * package main
 * import (
 * 	"github.com/pulumi/pulumi-gcp/sdk/v7/go/gcp/vertex"
 * 	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
 * )
 * func main() {
 * 	pulumi.Run(func(ctx *pulumi.Context) error {
 * 		_, err := vertex.NewAiMetadataStore(ctx, "store", &vertex.AiMetadataStoreArgs{
 * 			Name:        pulumi.String("test-store"),
 * 			Description: pulumi.String("Store to test the terraform module"),
 * 			Region:      pulumi.String("us-central1"),
 * 		})
 * 		if err != nil {
 * 			return err
 * 		}
 * 		return nil
 * 	})
 * }
 * ```
 * ```java
 * package generated_program;
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.gcp.vertex.AiMetadataStore;
 * import com.pulumi.gcp.vertex.AiMetadataStoreArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 *     public static void stack(Context ctx) {
 *         var store = new AiMetadataStore("store", AiMetadataStoreArgs.builder()
 *             .name("test-store")
 *             .description("Store to test the terraform module")
 *             .region("us-central1")
 *             .build());
 *     }
 * }
 * ```
 * ```yaml
 * resources:
 *   store:
 *     type: gcp:vertex:AiMetadataStore
 *     properties:
 *       name: test-store
 *       description: Store to test the terraform module
 *       region: us-central1
 * ```
 * 
 * ## Import
 * MetadataStore can be imported using any of these accepted formats:
 * * `projects/{{project}}/locations/{{region}}/metadataStores/{{name}}`
 * * `{{project}}/{{region}}/{{name}}`
 * * `{{region}}/{{name}}`
 * * `{{name}}`
 * When using the `pulumi import` command, MetadataStore can be imported using one of the formats above. For example:
 * ```sh
 * $ pulumi import gcp:vertex/aiMetadataStore:AiMetadataStore default projects/{{project}}/locations/{{region}}/metadataStores/{{name}}
 * ```
 * ```sh
 * $ pulumi import gcp:vertex/aiMetadataStore:AiMetadataStore default {{project}}/{{region}}/{{name}}
 * ```
 * ```sh
 * $ pulumi import gcp:vertex/aiMetadataStore:AiMetadataStore default {{region}}/{{name}}
 * ```
 * ```sh
 * $ pulumi import gcp:vertex/aiMetadataStore:AiMetadataStore default {{name}}
 * ```
 */
public class AiMetadataStore internal constructor(
    override val javaResource: com.pulumi.gcp.vertex.AiMetadataStore,
) : KotlinCustomResource(javaResource, AiMetadataStoreMapper) {
    /**
     * The timestamp of when the MetadataStore was created in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits.
     */
    public val createTime: Output
        get() = javaResource.createTime().applyValue({ args0 -> args0 })

    /**
     * Description of the MetadataStore.
     */
    public val description: Output?
        get() = javaResource.description().applyValue({ args0 ->
            args0.map({ args0 ->
                args0
            }).orElse(null)
        })

    /**
     * Customer-managed encryption key spec for a MetadataStore. If set, this MetadataStore and all sub-resources of this MetadataStore will be secured by this key.
     * Structure is documented below.
     */
    public val encryptionSpec: Output?
        get() = javaResource.encryptionSpec().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 -> aiMetadataStoreEncryptionSpecToKotlin(args0) })
            }).orElse(null)
        })

    /**
     * The name of the MetadataStore. This value may be up to 60 characters, and valid characters are [a-z0-9_]. The first character cannot be a number.
     */
    public val name: Output
        get() = javaResource.name().applyValue({ args0 -> args0 })

    /**
     * The ID of the project in which the resource belongs.
     * If it is not provided, the provider project is used.
     */
    public val project: Output
        get() = javaResource.project().applyValue({ args0 -> args0 })

    /**
     * The region of the Metadata Store. eg us-central1
     */
    public val region: Output
        get() = javaResource.region().applyValue({ args0 -> args0 })

    /**
     * State information of the MetadataStore.
     * Structure is documented below.
     */
    public val states: Output>
        get() = javaResource.states().applyValue({ args0 ->
            args0.map({ args0 ->
                args0.let({ args0 ->
                    aiMetadataStoreStateToKotlin(args0)
                })
            })
        })

    /**
     * The timestamp of when the MetadataStore was last updated in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits.
     */
    public val updateTime: Output
        get() = javaResource.updateTime().applyValue({ args0 -> args0 })
}

public object AiMetadataStoreMapper : ResourceMapper {
    override fun supportsMappingOfType(javaResource: Resource): Boolean =
        com.pulumi.gcp.vertex.AiMetadataStore::class == javaResource::class

    override fun map(javaResource: Resource): AiMetadataStore = AiMetadataStore(
        javaResource as
            com.pulumi.gcp.vertex.AiMetadataStore,
    )
}

/**
 * @see [AiMetadataStore].
 * @param name The _unique_ name of the resulting resource.
 * @param block Builder for [AiMetadataStore].
 */
public suspend fun aiMetadataStore(
    name: String,
    block: suspend AiMetadataStoreResourceBuilder.() -> Unit,
): AiMetadataStore {
    val builder = AiMetadataStoreResourceBuilder()
    builder.name(name)
    block(builder)
    return builder.build()
}

/**
 * @see [AiMetadataStore].
 * @param name The _unique_ name of the resulting resource.
 */
public fun aiMetadataStore(name: String): AiMetadataStore {
    val builder = AiMetadataStoreResourceBuilder()
    builder.name(name)
    return builder.build()
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy