barbeque 2.7.5 → 2.8.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cc93ea9aa2da95d53cb020fddedded8cb3c7b142acd7486dfbd3c02df6359629
4
- data.tar.gz: 97bebc3bf997c25394383cb9809d6d272e4232dbe6175a7dd4f3f33912e471c8
3
+ metadata.gz: febc8fb62981217cb94e9614ebe9c303045555802bb010890ff796ae94024996
4
+ data.tar.gz: 10953be24a7344776dfee42281a7de2004b6abbfefb10b8b994f26fc4a6b8ec6
5
5
  SHA512:
6
- metadata.gz: 616b2ebb11c1e98207fa3ff808db098eb85d0939463b244f3b06ea67980a1adc3c6673382033bdfc727280c34ed752981b8b8d6746735ec46ec5b4d1e9c07c4c
7
- data.tar.gz: 583d2f978de033d27223548032c7f39ad89a858fb418d17102474e1404a1895437d508c7c1762dbe6b56a4bdba1ea30afca74145d1c865ba68888034d5b0ff23
6
+ metadata.gz: 30d5b1f6ca098e0c932cf27266b30e2f24c50a08de8475c53fa8cc3d480b06e58ccb30a6aa26df7bc3e5672196f2f91f6f2ead8815ce27f1fca23402ea04d259
7
+ data.tar.gz: bdd41760b5cc5e1f04e24bd2ca3626d7b71839a381c308ccc3477579e35a12e175177e4772ab3f992187bb2e7ec73e270a4a09f1daeedf1c5080801b86c41857
data/README.md CHANGED
@@ -1,4 +1,4 @@
1
- # Barbeque [![Build Status](https://travis-ci.org/cookpad/barbeque.svg?branch=master)](https://travis-ci.org/cookpad/barbeque)
1
+ # Barbeque [![Build Status](https://github.com/cookpad/barbeque/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/cookpad/barbeque/actions/workflows/ci.yml)
2
2
 
3
3
  Job queue system to run job with Docker
4
4
 
@@ -5,6 +5,7 @@ module Barbeque
5
5
  attr_reader :id # [String] Barbeque::JobExecution is associated via `message_id`
6
6
  attr_reader :receipt_handle # [String] Used to ack a message
7
7
  attr_reader :type # [String] "JobExecution", "JobRetry", etc
8
+ attr_reader :sent_timestamp # [String] The time the message was sent to the queue (epoch time in milliseconds)
8
9
 
9
10
  # @param [Aws::SQS::Types::Message] raw_message
10
11
  # @param message_body [Hash] parse result of `raw_message.body`
@@ -12,6 +13,7 @@ module Barbeque
12
13
  assign_body(message_body)
13
14
  @id = raw_message.message_id
14
15
  @receipt_handle = raw_message.receipt_handle
16
+ @sent_timestamp = raw_message.attributes['SentTimestamp']
15
17
  end
16
18
 
17
19
  # To distinguish with `Barbeque::Message::InvalidMessage`
@@ -34,6 +34,7 @@ module Barbeque
34
34
  'BARBEQUE_MESSAGE_ID' => @message.id,
35
35
  'BARBEQUE_QUEUE_NAME' => @message_queue.job_queue.name,
36
36
  'BARBEQUE_RETRY_COUNT' => '0',
37
+ 'BARBEQUE_SENT_TIMESTAMP' => @message.sent_timestamp,
37
38
  }
38
39
  end
39
40
 
@@ -45,6 +45,7 @@ module Barbeque
45
45
  'BARBEQUE_MESSAGE_ID' => @message.retry_message_id,
46
46
  'BARBEQUE_QUEUE_NAME' => @message_queue.job_queue.name,
47
47
  'BARBEQUE_RETRY_COUNT' => job_execution.job_retries.count.to_s,
48
+ 'BARBEQUE_SENT_TIMESTAMP' => @message.sent_timestamp,
48
49
  }
49
50
  end
50
51
 
@@ -48,6 +48,7 @@ module Barbeque
48
48
  queue_url: @job_queue.queue_url,
49
49
  wait_time_seconds: Barbeque.config.sqs_receive_message_wait_time,
50
50
  max_number_of_messages: 1,
51
+ attribute_names: ['SentTimestamp'],
51
52
  )
52
53
  if result.messages[0]
53
54
  Barbeque::Message.parse(result.messages[0])
@@ -1,3 +1,3 @@
1
1
  module Barbeque
2
- VERSION = '2.7.5'
2
+ VERSION = '2.8.0'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: barbeque
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.7.5
4
+ version: 2.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Takashi Kokubun
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-05-29 00:00:00.000000000 Z
11
+ date: 2021-12-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: adminlte2-rails
@@ -461,7 +461,7 @@ homepage: https://github.com/cookpad/barbeque
461
461
  licenses:
462
462
  - MIT
463
463
  metadata: {}
464
- post_install_message:
464
+ post_install_message:
465
465
  rdoc_options: []
466
466
  require_paths:
467
467
  - lib
@@ -476,8 +476,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
476
476
  - !ruby/object:Gem::Version
477
477
  version: '0'
478
478
  requirements: []
479
- rubygems_version: 3.0.3
480
- signing_key:
479
+ rubygems_version: 3.1.6
480
+ signing_key:
481
481
  specification_version: 4
482
482
  summary: Job queue system to run job with Docker
483
483
  test_files: []