carnivore 0.1.1 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/CHANGELOG.md CHANGED
@@ -1,3 +1,6 @@
1
+ # v0.1.2
2
+ * Allow ARN based queue endpoints for SQS
3
+
1
4
  # v0.1.1
2
5
  * Update block implementation within callback
3
6
  * Allow multiple queues on single SQS source
@@ -31,7 +31,7 @@ module Carnivore
31
31
 
32
32
  def call(message)
33
33
  if(valid?(message))
34
- @block ? execute(message, &@block) : execute(message)
34
+ execute(message)
35
35
  else
36
36
  debug 'Received message not valid for this callback'
37
37
  end
@@ -13,6 +13,9 @@ module Carnivore
13
13
  @fog = nil
14
14
  @connection_args = args[:fog]
15
15
  @queues = Array(args[:queues]).compact.flatten
16
+ @queues.map! do |q|
17
+ q.include?('.com') ? q : "/#{q.split(':')[-2,2].join('/')}"
18
+ end
16
19
  @pause_time = args[:pause] || 5
17
20
  @receive_timeout = after(args[:receive_timeout] || 30){ terminate }
18
21
  debug "Creating SQS source instance <#{name}>"
@@ -1,5 +1,5 @@
1
1
  module Carnivore
2
2
  class Version < Gem::Version
3
3
  end
4
- VERSION = Version.new('0.1.1')
4
+ VERSION = Version.new('0.1.2')
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: carnivore
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: