pliny-sidekiq 0.1.0 → 0.1.1

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
  SHA1:
3
- metadata.gz: cb79fb9d67b16721259bf2dd96c67be3641488c9
4
- data.tar.gz: 60ff08f17f5ea9ac681ac44dd4e503f0edb56c9c
3
+ metadata.gz: 7110a84955ce8a99dc9792d44dc55246b212474c
4
+ data.tar.gz: 5e7d757710eaf1736eeb9e8ce47c7008b32a13e8
5
5
  SHA512:
6
- metadata.gz: f657e177637640a732825faa13407bfcb5d5f6b18377f5b39bb833965be95cf399225838c882731616188670ccd090158093ff7c3f423f15290ca80805d01652
7
- data.tar.gz: ab2ba97d3bc0c734b1f3b609b07149b4d2ab6156901347d69f312eaa3018118dbad5590999f12ce538718ea11552811f5952e1f21e3e1541c3b466e7ed7df76a
6
+ metadata.gz: 14029ca487a567a0618e7d3996b001909176faf9f77fab32baccc9c341142bc950587290a82212c8d77330684de95fab8d42832d5cfc7454b9a39ac7d1424104
7
+ data.tar.gz: 9c5682ae8da19905395bb56f01f20543a703e9900dee9c4ecfff4bec7a870c4411d5147e76c2a10061ae2aaefdd7fcda4e2d748f3b20a79c922adbe662455c41
data/.gitignore CHANGED
@@ -7,3 +7,4 @@
7
7
  /pkg/
8
8
  /spec/reports/
9
9
  /tmp/
10
+ /*.gem
@@ -3,12 +3,14 @@ module Pliny::Sidekiq::Middleware
3
3
  class Log
4
4
  def call(worker_class, msg, queue, redis_pool)
5
5
  yield.tap do
6
- Pliny.log(
7
- job: msg['class'],
8
- job_id: msg['jid'],
9
- enqueued: true,
10
- enqueued_at: Time.at(msg['enqueued_at'])
11
- )
6
+ data = {
7
+ job: msg['class'],
8
+ job_id: msg['jid'],
9
+ enqueued: true
10
+ }
11
+ data[:enqueued_at] = Time.at(msg['enqueued_at']) if msg.has_key?('enqueued_at')
12
+
13
+ Pliny.log(data)
12
14
  end
13
15
  end
14
16
  end
@@ -1,5 +1,5 @@
1
1
  module Pliny
2
2
  module Sidekiq
3
- VERSION = "0.1.0"
3
+ VERSION = "0.1.1"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pliny-sidekiq
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Guðmundur Bjarni Ólafsson