0xcodezero / activemessaging

Automatically exported from code.google.com/p/activemessaging
0 stars 0 forks source link

regex error on extracting Amazon SQS queue names #26

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Have an Amazon SQS queue with a name that contains a dash ('-').
2. Run the 'poller' script

What is the expected output? What do you see instead?

plugins/activemessaging/lib/activemessaging/adapters/asqs.rb:325:in `from_url': 
Bad Queue 
URL: http://queue.amazonaws.com/<identifier>/<queue-name-with-dash> 
(RuntimeError)

Fix includes match for dash. '\w' matches a digit, letter, or underscore (not a 
dash).

asqs.rb:324:
/^http:\/\/(.+)\/(.+)\/(\w+)$/
to
/^http:\/\/(.+)\/(.+)\/([\w-]+)$/

Original issue reported on code.google.com by globalgo...@gmail.com on 8 Feb 2008 at 1:49

GoogleCodeExporter commented 9 years ago
Related:
http://code.google.com/p/activemessaging/issues/detail?id=20

Original comment by globalgo...@gmail.com on 8 Feb 2008 at 1:57

GoogleCodeExporter commented 9 years ago
whoops - my bad - committed

Original comment by kooks...@gmail.com on 22 Feb 2008 at 7:56