Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(forwarder): filter eventbridge triggers by source bucket
We previously triggered the forwarder lambda on all S3 object created events, and relied on the lambda to ignore spurious triggers. This turns out to be too lax. We can filter events by source bucket using the `wildcard` pattern. Like bucket names, the wildcard pattern supports globs. Without globs, it behaves as an exact match. This means that for source bucket names `foo*` and `bar`, the event bridge pattern compiled would be: ``` { "source": ["aws.s3"], "detail-type": ["Object Created"], "detail.bucket.name": [{ "wildcard": "foo*" }, { "wildcard": "bar" } ] } ```
- Loading branch information