applicaster-logger 0.8.3 → 0.8.4

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: 3326370f85ac88843766e7cf4c4ab0bbd8005ea7
4
- data.tar.gz: 2f8a596bd18327c6327df4e08d01a193dec9705f
3
+ metadata.gz: 9aeb4e7b00bbb9aa2ee2efb1aadf545afc7629bf
4
+ data.tar.gz: 853bf94c7926e6505b03ddf52ed519895c690c99
5
5
  SHA512:
6
- metadata.gz: 2e93737e0f19cab96f365e55ca533cc5c802689380477b609265c69a70df1b7ee2043f2038e7f477fb1136f2ebf396189eaf0339b5ff858cf53ac883ee43242b
7
- data.tar.gz: 56f04a59a07949651d241c563bd90df25f43c0a3955f587d636e8b859ee1478aaa5fc227d387eccb788b45450e9194c90533214e974832d002f86484ac5aaecb
6
+ metadata.gz: 147c482cb97c2ded9506d527e5cc536fc67e27e3e973c3cc5e10a43f073f7126d7c4928d564704034a6a46fc8a22bf4e8a3ca31c2f32a06f877b636a43d64b1b
7
+ data.tar.gz: f74960bda06ab5cd32c7a2d6b75f5b6ca30df8e27cc9193b7f97b287f655bf4cfb24f30cb1896509ce3faf822a87124da60cb2273fb8c2d5a030834a1c1a67f6
@@ -1,23 +1,25 @@
1
1
  require_relative "./common_events"
2
2
 
3
3
  module Applicaster
4
- module Sidekiq
5
- class JobLogger
6
- include Applicaster::Logger::Sidekiq
7
- include Applicaster::Logger::Sidekiq::CommonEvents
4
+ module Logger
5
+ module Sidekiq
6
+ class JobLogger
7
+ include Applicaster::Logger::Sidekiq
8
+ include Applicaster::Logger::Sidekiq::CommonEvents
8
9
 
9
- def call(item, queue)
10
- start = Time.now
11
- logger.info(job_context(item, queue).deep_merge(start_event(item)))
12
- yield
13
- runtime = elapsed(start)
14
- logger.info(job_context(item, queue).deep_merge(done_event(item, runtime: runtime)))
15
- end
10
+ def call(item, queue)
11
+ start = Time.now
12
+ logger.info(job_context(item, queue).deep_merge(start_event(item)))
13
+ yield
14
+ runtime = elapsed(start)
15
+ logger.info(job_context(item, queue).deep_merge(done_event(item, runtime: runtime)))
16
+ end
16
17
 
17
- private
18
+ private
18
19
 
19
- def elapsed(start)
20
- (Time.now - start).round(3)
20
+ def elapsed(start)
21
+ (Time.now - start).round(3)
22
+ end
21
23
  end
22
24
  end
23
25
  end
@@ -1,5 +1,5 @@
1
1
  module Applicaster
2
2
  module Logger
3
- VERSION = "0.8.3"
3
+ VERSION = "0.8.4"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: applicaster-logger
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.3
4
+ version: 0.8.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vitaly Gorodetsky
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-09-19 00:00:00.000000000 Z
11
+ date: 2018-09-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: logstash-logger