RuleTargetConfig

class aws_cdk.aws_events.RuleTargetConfig(*, arn, id, ecs_parameters=None, input=None, kinesis_parameters=None, role=None, run_command_parameters=None, sqs_parameters=None, target_resource=None)

Bases: object

__init__(*, arn, id, ecs_parameters=None, input=None, kinesis_parameters=None, role=None, run_command_parameters=None, sqs_parameters=None, target_resource=None)

Properties for an event rule target.

Parameters
  • arn (str) – The Amazon Resource Name (ARN) of the target.

  • id (str) – A unique, user-defined identifier for the target. Acceptable values include alphanumeric characters, periods (.), hyphens (-), and underscores (_).

  • ecs_parameters (Optional[EcsParametersProperty]) – The Amazon ECS task definition and task count to use, if the event target is an Amazon ECS task.

  • input (Optional[RuleTargetInput]) – What input to send to the event target. Default: the entire event

  • kinesis_parameters (Optional[KinesisParametersProperty]) – Settings that control shard assignment, when the target is a Kinesis stream. If you don’t include this parameter, eventId is used as the partition key.

  • role (Optional[IRole]) – Role to use to invoke this event target.

  • run_command_parameters (Optional[RunCommandParametersProperty]) – Parameters used when the rule invokes Amazon EC2 Systems Manager Run Command.

  • sqs_parameters (Optional[SqsParametersProperty]) – Parameters used when the FIFO sqs queue is used an event target by the rule.

  • target_resource (Optional[IConstruct]) – The resource that is backing this target. This is the resource that will actually have some action performed on it when used as a target (for example, start a build for a CodeBuild project). We need it to determine whether the rule belongs to a different account than the target - if so, we generate a more complex setup, including an additional stack containing the EventBusPolicy. Default: the target is not backed by any resource

Attributes

arn

The Amazon Resource Name (ARN) of the target.

Return type

str

ecs_parameters

The Amazon ECS task definition and task count to use, if the event target is an Amazon ECS task.

Return type

Optional[EcsParametersProperty]

id

A unique, user-defined identifier for the target.

Acceptable values include alphanumeric characters, periods (.), hyphens (-), and underscores (_).

deprecated :deprecated: prefer auto-generated id by specifying an empty string

stability :stability: deprecated

Return type

str

input

What input to send to the event target.

default :default: the entire event

Return type

Optional[RuleTargetInput]

kinesis_parameters

Settings that control shard assignment, when the target is a Kinesis stream.

If you don’t include this parameter, eventId is used as the partition key.

Return type

Optional[KinesisParametersProperty]

role

Role to use to invoke this event target.

Return type

Optional[IRole]

run_command_parameters

Parameters used when the rule invokes Amazon EC2 Systems Manager Run Command.

Return type

Optional[RunCommandParametersProperty]

sqs_parameters

Parameters used when the FIFO sqs queue is used an event target by the rule.

Return type

Optional[SqsParametersProperty]

target_resource

The resource that is backing this target. This is the resource that will actually have some action performed on it when used as a target (for example, start a build for a CodeBuild project). We need it to determine whether the rule belongs to a different account than the target - if so, we generate a more complex setup, including an additional stack containing the EventBusPolicy.

default :default: the target is not backed by any resource

see :see: https://docs.aws.amazon.com/AmazonCloudWatch/latest/events/CloudWatchEvents-CrossAccountEventDelivery.html

Return type

Optional[IConstruct]