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

SQS error queues are not created when specifying a queue by name #38

Closed
tomhaigh opened this issue Feb 8, 2017 · 1 comment
Closed
Labels

Comments

@tomhaigh
Copy link
Contributor

tomhaigh commented Feb 8, 2017

This is because the regular expression match is skipped for these.

Possible solution is to separately expand those into {Name} and {Name}-{ErrorSuffix} (where queues exist)

tomhaigh pushed a commit that referenced this issue Feb 15, 2017
* Monitoring a named queue should also monitor the matching error queue
#38
Start with a failing test

* Refactoring - hoisted the call to queueSource.GetResourceNamesAsync
so do it once per alerting group

* Extract methods

* This passes the test
but is unnecessary when the queue names come from pattern matches anwyay

* Failing test on similar queue name pattern

* tests are passing
code is complex .. also might be ugly?

* pattern mismatch test
and fix

* Minor refactor

* Test extra queue name
It's different to pattern
as it's not removed by pattern expansion

* Rename these methods to show that they mutate state

* Move logic into Queue class, easier to use elsewhere

* Tom's Simpler way to do it
- expand name to a regexp that matches {name} and {name}{errorSuffix}
Same tests, still pass

* Names and suffixes are to be taken literally in regexp
@AnthonySteele
Copy link
Contributor

Fixed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants