import * as pulumi from "@pulumi/pulumi"; /** * Associates a Spring Cloud Application with a CosmosDB Account. * * !> **Note:** Azure Spring Apps is now deprecated and will be retired on 2028-05-31 - as such the `azure.appplatform.SpringCloudAppCosmosDBAssociation` resource is deprecated and will be removed in a future major version of the AzureRM Provider. See https://aka.ms/asaretirement for more information. * * ## Example Usage * * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as azure from "@pulumi/azure"; * * const example = new azure.core.ResourceGroup("example", { * name: "example-resources", * location: "West Europe", * }); * const exampleSpringCloudService = new azure.appplatform.SpringCloudService("example", { * name: "example-springcloud", * resourceGroupName: example.name, * location: example.location, * }); * const exampleSpringCloudApp = new azure.appplatform.SpringCloudApp("example", { * name: "example-springcloudapp", * resourceGroupName: example.name, * serviceName: exampleSpringCloudService.name, * }); * const exampleAccount = new azure.cosmosdb.Account("example", { * name: "example-cosmosdb-account", * location: example.location, * resourceGroupName: example.name, * offerType: "Standard", * kind: "GlobalDocumentDB", * consistencyPolicy: { * consistencyLevel: "Strong", * }, * geoLocations: [{ * location: example.location, * failoverPriority: 0, * }], * }); * const exampleSpringCloudAppCosmosDBAssociation = new azure.appplatform.SpringCloudAppCosmosDBAssociation("example", { * name: "example-bind", * springCloudAppId: exampleSpringCloudApp.id, * cosmosdbAccountId: exampleAccount.id, * apiType: "table", * cosmosdbAccessKey: exampleAccount.primaryKey, * }); * ``` * * ## Import * * Spring Cloud Application CosmosDB Association can be imported using the `resource id`, e.g. * * ```sh * $ pulumi import azure:appplatform/springCloudAppCosmosDBAssociation:SpringCloudAppCosmosDBAssociation example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/resourcegroup1/providers/Microsoft.AppPlatform/spring/service1/apps/app1/bindings/bind1 * ``` */ export declare class SpringCloudAppCosmosDBAssociation extends pulumi.CustomResource { /** * Get an existing SpringCloudAppCosmosDBAssociation resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state Any extra arguments used during the lookup. * @param opts Optional settings to control the behavior of the CustomResource. */ static get(name: string, id: pulumi.Input, state?: SpringCloudAppCosmosDBAssociationState, opts?: pulumi.CustomResourceOptions): SpringCloudAppCosmosDBAssociation; /** * Returns true if the given object is an instance of SpringCloudAppCosmosDBAssociation. This is designed to work even * when multiple copies of the Pulumi SDK have been loaded into the same process. */ static isInstance(obj: any): obj is SpringCloudAppCosmosDBAssociation; /** * Specifies the API type which should be used when connecting to the CosmosDB Account. Possible values are `cassandra`, `gremlin`, `mongo`, `sql` or `table`. Changing this forces a new resource to be created. */ readonly apiType: pulumi.Output; /** * Specifies the CosmosDB Account access key. */ readonly cosmosdbAccessKey: pulumi.Output; /** * Specifies the ID of the CosmosDB Account. Changing this forces a new resource to be created. */ readonly cosmosdbAccountId: pulumi.Output; /** * Specifies the name of the Cassandra Keyspace which the Spring Cloud App should be associated with. Should only be set when `apiType` is `cassandra`. */ readonly cosmosdbCassandraKeyspaceName: pulumi.Output; /** * Specifies the name of the Gremlin Database which the Spring Cloud App should be associated with. Should only be set when `apiType` is `gremlin`. */ readonly cosmosdbGremlinDatabaseName: pulumi.Output; /** * Specifies the name of the Gremlin Graph which the Spring Cloud App should be associated with. Should only be set when `apiType` is `gremlin`. */ readonly cosmosdbGremlinGraphName: pulumi.Output; /** * Specifies the name of the Mongo Database which the Spring Cloud App should be associated with. Should only be set when `apiType` is `mongo`. */ readonly cosmosdbMongoDatabaseName: pulumi.Output; /** * Specifies the name of the SQL Database which the Spring Cloud App should be associated with. Should only be set when `apiType` is `sql`. */ readonly cosmosdbSqlDatabaseName: pulumi.Output; /** * Specifies the name of the Spring Cloud Application Association. Changing this forces a new resource to be created. */ readonly name: pulumi.Output; /** * Specifies the ID of the Spring Cloud Application where this Association is created. Changing this forces a new resource to be created. */ readonly springCloudAppId: pulumi.Output; /** * Create a SpringCloudAppCosmosDBAssociation resource with the given unique name, arguments, and options. * * @param name The _unique_ name of the resource. * @param args The arguments to use to populate this resource's properties. * @param opts A bag of options that control this resource's behavior. */ constructor(name: string, args: SpringCloudAppCosmosDBAssociationArgs, opts?: pulumi.CustomResourceOptions); } /** * Input properties used for looking up and filtering SpringCloudAppCosmosDBAssociation resources. */ export interface SpringCloudAppCosmosDBAssociationState { /** * Specifies the API type which should be used when connecting to the CosmosDB Account. Possible values are `cassandra`, `gremlin`, `mongo`, `sql` or `table`. Changing this forces a new resource to be created. */ apiType?: pulumi.Input; /** * Specifies the CosmosDB Account access key. */ cosmosdbAccessKey?: pulumi.Input; /** * Specifies the ID of the CosmosDB Account. Changing this forces a new resource to be created. */ cosmosdbAccountId?: pulumi.Input; /** * Specifies the name of the Cassandra Keyspace which the Spring Cloud App should be associated with. Should only be set when `apiType` is `cassandra`. */ cosmosdbCassandraKeyspaceName?: pulumi.Input; /** * Specifies the name of the Gremlin Database which the Spring Cloud App should be associated with. Should only be set when `apiType` is `gremlin`. */ cosmosdbGremlinDatabaseName?: pulumi.Input; /** * Specifies the name of the Gremlin Graph which the Spring Cloud App should be associated with. Should only be set when `apiType` is `gremlin`. */ cosmosdbGremlinGraphName?: pulumi.Input; /** * Specifies the name of the Mongo Database which the Spring Cloud App should be associated with. Should only be set when `apiType` is `mongo`. */ cosmosdbMongoDatabaseName?: pulumi.Input; /** * Specifies the name of the SQL Database which the Spring Cloud App should be associated with. Should only be set when `apiType` is `sql`. */ cosmosdbSqlDatabaseName?: pulumi.Input; /** * Specifies the name of the Spring Cloud Application Association. Changing this forces a new resource to be created. */ name?: pulumi.Input; /** * Specifies the ID of the Spring Cloud Application where this Association is created. Changing this forces a new resource to be created. */ springCloudAppId?: pulumi.Input; } /** * The set of arguments for constructing a SpringCloudAppCosmosDBAssociation resource. */ export interface SpringCloudAppCosmosDBAssociationArgs { /** * Specifies the API type which should be used when connecting to the CosmosDB Account. Possible values are `cassandra`, `gremlin`, `mongo`, `sql` or `table`. Changing this forces a new resource to be created. */ apiType: pulumi.Input; /** * Specifies the CosmosDB Account access key. */ cosmosdbAccessKey: pulumi.Input; /** * Specifies the ID of the CosmosDB Account. Changing this forces a new resource to be created. */ cosmosdbAccountId: pulumi.Input; /** * Specifies the name of the Cassandra Keyspace which the Spring Cloud App should be associated with. Should only be set when `apiType` is `cassandra`. */ cosmosdbCassandraKeyspaceName?: pulumi.Input; /** * Specifies the name of the Gremlin Database which the Spring Cloud App should be associated with. Should only be set when `apiType` is `gremlin`. */ cosmosdbGremlinDatabaseName?: pulumi.Input; /** * Specifies the name of the Gremlin Graph which the Spring Cloud App should be associated with. Should only be set when `apiType` is `gremlin`. */ cosmosdbGremlinGraphName?: pulumi.Input; /** * Specifies the name of the Mongo Database which the Spring Cloud App should be associated with. Should only be set when `apiType` is `mongo`. */ cosmosdbMongoDatabaseName?: pulumi.Input; /** * Specifies the name of the SQL Database which the Spring Cloud App should be associated with. Should only be set when `apiType` is `sql`. */ cosmosdbSqlDatabaseName?: pulumi.Input; /** * Specifies the name of the Spring Cloud Application Association. Changing this forces a new resource to be created. */ name?: pulumi.Input; /** * Specifies the ID of the Spring Cloud Application where this Association is created. Changing this forces a new resource to be created. */ springCloudAppId: pulumi.Input; }