import * as core from "@terrascript/core"; export interface EventBatchingConditionArgs extends core.SchemaArgs { batchSize: number | core.NumberOut; batchWindow?: number | core.NumberOut; } export class EventBatchingCondition extends core.Schema { @core.attr(Number) public batchSize!: number | core.NumberOut; @core.attr(Number) public batchWindow?: number | core.NumberOut; } export interface ConditionsArgs extends core.SchemaArgs { crawlState?: string | core.StringOut; crawlerName?: string | core.StringOut; jobName?: string | core.StringOut; logicalOperator?: string | core.StringOut; state?: string | core.StringOut; } export class Conditions extends core.Schema { @core.attr(String) public crawlState?: string | core.StringOut; @core.attr(String) public crawlerName?: string | core.StringOut; @core.attr(String) public jobName?: string | core.StringOut; @core.attr(String) public logicalOperator?: string | core.StringOut; @core.attr(String) public state?: string | core.StringOut; } export interface PredicateArgs extends core.SchemaArgs { conditions: core.Array | core.ArrayOut; logical?: string | core.StringOut; } export class Predicate extends core.Schema { @core.attr(Conditions, { kind: "array" }) public conditions!: core.Array | core.ArrayOut; @core.attr(String) public logical?: string | core.StringOut; } export interface NotificationPropertyArgs extends core.SchemaArgs { notifyDelayAfter?: number | core.NumberOut; } export class NotificationProperty extends core.Schema { @core.attr(Number) public notifyDelayAfter?: number | core.NumberOut; } export interface ActionsArgs extends core.SchemaArgs { arguments?: core.Map | core.MapOut; crawlerName?: string | core.StringOut; jobName?: string | core.StringOut; notificationProperty?: NotificationProperty; securityConfiguration?: string | core.StringOut; timeout?: number | core.NumberOut; } export class Actions extends core.Schema { @core.attr(String, { kind: "map" }) public arguments?: core.Map | core.MapOut; @core.attr(String) public crawlerName?: string | core.StringOut; @core.attr(String) public jobName?: string | core.StringOut; @core.attr(NotificationProperty) public notificationProperty?: NotificationProperty; @core.attr(String) public securityConfiguration?: string | core.StringOut; @core.attr(Number) public timeout?: number | core.NumberOut; } export interface TriggerArgs extends core.ResourceArgs { actions: core.Array | core.ArrayOut; description?: string | core.StringOut; enabled?: boolean | core.BooleanOut; /** * (Optional) Batch condition that must be met (specified number of events received or batch time windo * w expired) before EventBridge event trigger fires. See [Event Batching Condition](#event-batching-co * ndition). */ eventBatchingCondition?: | core.Array | core.ArrayOut; name: string | core.StringOut; predicate?: Predicate; schedule?: string | core.StringOut; startOnCreation?: boolean | core.BooleanOut; /** * (Optional) Key-value map of resource tags. If configured with a provider [`default_tags` configurati * on block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-configurati * on-block) present, tags with matching keys will overwrite those defined at the provider-level. */ tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ tagsAll?: core.Map | core.MapOut; type: string | core.StringOut; /** * (Optional) A workflow to which the trigger should be associated to. Every workflow graph (DAG) needs * a starting trigger (`ON_DEMAND` or `SCHEDULED` type) and can contain multiple additional `CONDITION * AL` triggers. */ workflowName?: string | core.StringOut; } export class Trigger extends core.Resource { @core.attr(Actions, { kind: "array" }) public actions!: core.Array | core.ArrayOut; /** * Amazon Resource Name (ARN) of Glue Trigger */ @core.attr(String, { computed: true }) public arn!: string | core.StringOut; @core.attr(String) public description?: string | core.StringOut; @core.attr(Boolean) public enabled?: boolean | core.BooleanOut; /** * (Optional) Batch condition that must be met (specified number of events received or batch time windo * w expired) before EventBridge event trigger fires. See [Event Batching Condition](#event-batching-co * ndition). */ @core.attr(EventBatchingCondition, { kind: "array" }) public eventBatchingCondition?: | core.Array | core.ArrayOut; /** * Trigger name */ @core.attr(String, { computed: true }) public id!: string | core.StringOut; @core.attr(String) public name!: string | core.StringOut; @core.attr(Predicate) public predicate?: Predicate; @core.attr(String) public schedule?: string | core.StringOut; @core.attr(Boolean) public startOnCreation?: boolean | core.BooleanOut; /** * (Optional) The condition job state. Currently, the values supported are `SUCCEEDED`, `STOPPED`, `TIM * EOUT` and `FAILED`. If this is specified, `job_name` must also be specified. Conflicts with `crawler * _state`. */ @core.attr(String, { computed: true }) public state!: string | core.StringOut; /** * (Optional) Key-value map of resource tags. If configured with a provider [`default_tags` configurati * on block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-configurati * on-block) present, tags with matching keys will overwrite those defined at the provider-level. */ @core.attr(String, { kind: "map" }) public tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ @core.attr(String, { computed: true, kind: "map" }) public tagsAll?: core.Map | core.MapOut; @core.attr(String) public type!: string | core.StringOut; /** * (Optional) A workflow to which the trigger should be associated to. Every workflow graph (DAG) needs * a starting trigger (`ON_DEMAND` or `SCHEDULED` type) and can contain multiple additional `CONDITION * AL` triggers. */ @core.attr(String) public workflowName?: string | core.StringOut; constructor(name: string, args?: TriggerArgs) { super(name, "aws_glue_trigger", args); } public override getNamespace(): string { return "aws_glue"; } }