SqlTrigger

class SqlTrigger : KotlinCustomResource

Manages an SQL Trigger.

Example Usage

resources:
exampleSqlDatabase:
type: azure:cosmosdb:SqlDatabase
name: example
properties:
name: tfex-cosmos-db
resourceGroupName: ${example.resourceGroupName}
accountName: ${example.name}
throughput: 400
exampleSqlContainer:
type: azure:cosmosdb:SqlContainer
name: example
properties:
name: example-container
resourceGroupName: ${example.resourceGroupName}
accountName: ${example.name}
databaseName: ${exampleSqlDatabase.name}
partitionKeyPath: /id
exampleSqlTrigger:
type: azure:cosmosdb:SqlTrigger
name: example
properties:
name: test-trigger
containerId: ${exampleSqlContainer.id}
body: function trigger(){}
operation: Delete
type: Post
variables:
example:
fn::invoke:
function: azure:cosmosdb:getAccount
arguments:
name: tfex-cosmosdb-account
resourceGroupName: tfex-cosmosdb-account-rg

Import

SQL Triggers can be imported using the resource id, e.g.

$ pulumi import azure:cosmosdb/sqlTrigger:SqlTrigger example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.DocumentDB/databaseAccounts/account1/sqlDatabases/database1/containers/container1/triggers/trigger1

Properties

Link copied to clipboard
val body: Output<String>

Body of the Trigger.

Link copied to clipboard
val containerId: Output<String>

The id of the Cosmos DB SQL Container to create the SQL Trigger within. Changing this forces a new SQL Trigger to be created.

Link copied to clipboard
val id: Output<String>
Link copied to clipboard
val name: Output<String>

The name which should be used for this SQL Trigger. Changing this forces a new SQL Trigger to be created.

Link copied to clipboard
val operation: Output<String>

The operation the trigger is associated with. Possible values are All, Create, Update, Delete and Replace.

Link copied to clipboard
val pulumiChildResources: Set<KotlinResource>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
val type: Output<String>

Type of the Trigger. Possible values are Pre and Post.

Link copied to clipboard
val urn: Output<String>