Open pplu opened 2 years ago
AWS::Events::Rule
No response
https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-events-rule.html#aws-resource-events-rule-return-values
In https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-events-rule.html#aws-resource-events-rule-return-values, the return value for the !Ref of a Rule is
Ref returns event rule ID, such as mystack-ScheduledRule-ABCDEFGHIJK
mystack-ScheduledRule-ABCDEFGHIJK
I have seen that Rules return "busname|rulename" as the value of !Ref. I am actually using the return value of !Ref on an Event this to monitor the rule like this:
BusInvocationErrors: Type: AWS::CloudWatch::Alarm Properties: ActionsEnabled: true AlarmDescription: !Sub 'FailedInvocations in ${AWS::StackName}' ComparisonOperator: GreaterThanThreshold Dimensions: - Name: EventBusName Value: !Select [ 0, !Split [ '|', !Ref Rule ] ] - Name: RuleName Value: !Select [ 1, !Split [ '|', !Ref Rule ] ] Period: 60 EvaluationPeriods: 1 MetricName: FailedInvocations Namespace: AWS/Events Statistic: Sum
I would suggest that the return value be correctly documented.
8 months into having reported this, and it bit me again (didn't even remember reporting it). Is this going to get corrected?
Name of the resource
AWS::Events::Rule
Resource name
No response
Reference Link
https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-events-rule.html#aws-resource-events-rule-return-values
Details
In https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-events-rule.html#aws-resource-events-rule-return-values, the return value for the !Ref of a Rule is
I have seen that Rules return "busname|rulename" as the value of !Ref. I am actually using the return value of !Ref on an Event this to monitor the rule like this:
I would suggest that the return value be correctly documented.