Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unique rule names for multiple CloudWatch expressions #6

Conversation

edudobay
Copy link

@edudobay edudobay commented Sep 27, 2021

Description

A mixture of two cases that were handled individually uncovers an incorrect behavior: when a function has multiple event expressions AND the resulting rule name would be >= 64 characters long, all expressions get the same hash, so only the last expression is scheduled.

In this commit, the index of the expression is used to build the hash, but only if the index is not zero — this is possibly not needed, but ensures current hashes are preserved.

GitHub Issues

@edudobay edudobay force-pushed the unique-rule-names-for-multiple-cloudwatch-expressions branch from 51e6a46 to 65775ea Compare September 27, 2021 21:23
@edudobay edudobay marked this pull request as ready for review September 27, 2021 21:23
hellno and others added 7 commits September 28, 2021 18:47
* Create CONTRIBUTING.md
Co-authored-by: Will Boyce <[email protected]>
* wait for lambda to become active during deployment

* wait for lambda to become active during update

* split active/updated waiters into separate functions

* explicitly wait during update_lambda_function too
* run ci on pushes to master in addition to PRs

* restore coveralls test coverage tracking

* update README
A mixture of two cases that were handled individually uncovers an
incorrect behavior: when a function has multiple event expressions AND
the resulting rule name would be >= 64 characters long, all expressions
get the same hash, so only the last expression is scheduled.

In this commit, the index of the expression is used to build the hash,
but only if the index is not zero — this is possibly not needed, but
ensures current hashes are preserved.
@edudobay edudobay force-pushed the unique-rule-names-for-multiple-cloudwatch-expressions branch from 65775ea to e8bfa29 Compare October 17, 2021 13:50
@edudobay
Copy link
Author

Closing in favor of zappa#2

@edudobay edudobay closed this Oct 17, 2021
@edudobay edudobay deleted the unique-rule-names-for-multiple-cloudwatch-expressions branch November 25, 2021 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants