eventq_aws 0.3.3 → 0.3.4

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 06ba708d528f4bf6496965c98e4d49ff3e260ebf
4
- data.tar.gz: 7f992c94cabc94c874777aa5a7af21a8b7506c23
3
+ metadata.gz: 6471bdd6b18f30d44b11f4279793dc502d532464
4
+ data.tar.gz: 5e68d6b2e6ab5d26de06a8b49aa4a087764febbd
5
5
  SHA512:
6
- metadata.gz: 15d7a172d5d7edbbad28f04a699a7ba96ad4039d912780d40422defb485e35c50630d844db39515d00af69e11656b9617f81f3143fb4a575b59942db9e40ac0b
7
- data.tar.gz: 420b6d764bac9f6b936583993cfdeb0c5f354c15ab9645f926966ed17d8859f66ace70c52208129bd0297747a573a79691e01f78ad35e3122653a758f4c22bd1
6
+ metadata.gz: d8a11b3e593d6e6a034a77c1ea5cba7db35bef86ee642f78150dea6a0e5cef29c942bf1c5b0e943d303187268070d9356bfdf1781284cf2c853a66509226bba8
7
+ data.tar.gz: 57fb26b969ba2371d58342a5e0baaf3d260a87b63bc651cd2927174289f8bf4f93fac390d984326123eefea0c80734aaed5cc191db9102a3fe7c489921c0eb50
@@ -57,14 +57,14 @@ module EventQ
57
57
  queue_url: q,
58
58
  max_number_of_messages: 1,
59
59
  wait_time_seconds: 1,
60
- message_attribute_names: ['ApproximateReceiveCount']
60
+ attribute_names: ['ApproximateReceiveCount']
61
61
  })
62
62
 
63
63
  #check that a message was received
64
64
  if response.messages.length > 0
65
65
 
66
66
  msg = response.messages[0]
67
- retry_attempts = msg.message_attributes['ApproximateReceiveCount'].to_i
67
+ retry_attempts = msg.attributes['ApproximateReceiveCount'].to_i - 1
68
68
 
69
69
  #deserialize the message payload
70
70
  message = Oj.load(msg.body)
@@ -147,7 +147,6 @@ module EventQ
147
147
 
148
148
  def reject_message(queue, client, msg, q, retry_attempts)
149
149
  if !queue.allow_retry || retry_attempts >= queue.max_retry_attempts
150
-
151
150
  #remove the message from the queue so that it does not get retried again
152
151
  client.sqs.delete_message({ queue_url: q, receipt_handle: msg.receipt_handle })
153
152
  end
@@ -1,5 +1,5 @@
1
1
  module EventQ
2
2
  module Amazon
3
- VERSION = "0.3.3"
3
+ VERSION = "0.3.4"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: eventq_aws
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.3
4
+ version: 0.3.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - vaughanbrittonsage
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-07-06 00:00:00.000000000 Z
11
+ date: 2016-07-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler