Skip to content

E2529: count SAM CloudWatchLogs events toward the log-group subscription limit #4609

Description

@kddejong

Follow-up to #4491. Tracked in #4607. CloudWatch Logs allows 2 subscription filters per log group.

Problem

E2529 only enumerates AWS::Logs::SubscriptionFilter. SAM CloudWatchLogs events on AWS::Serverless::Function used to expand into those filters; post-#4491 they do not, so >2 SAM events on one log group are not flagged. test_events_log_group_name::test_file_negative was set to expect 0.

Fix

In __get_log_group_name_list, also read AWS::Serverless::Function Events of Type: CloudWatchLogs and merge their LogGroupName into the same per-group buckets as explicit filters.

Acceptance

  • Flags >2 SAM events on one group
  • Flags mixed explicit+SAM >2 on one group
  • Match path at Resources/<Fn>/Properties/Events/<Id>/...
  • isinstance guards for non-dict/intrinsic Events
  • Flip bad/some_logs_stream_lambda.yaml back to 1 error

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions