sidekiq-batch 0.1.4 → 0.1.5

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: 39cabb4788c4c4941b2688f2fe575358287fd1c7
4
- data.tar.gz: 1112290cc612ded396f27f0803bf33f48766734f
3
+ metadata.gz: 2d61afa130ecc7d339ec1ff9c2b38ce8870ef0e5
4
+ data.tar.gz: a28ac95c3bb93ebd274f99b253e8f7db7d01ffeb
5
5
  SHA512:
6
- metadata.gz: 45d60f50f7dc34e416d07ccca67c6d96821404514df5ee1aa1b8267d349cb4543655a73e069634f404409964a96805eaefc797fe205bff71297d76908f86ec89
7
- data.tar.gz: b7f049fb8894c42e401fcfa655d6f98e79d1965bebbbd07720bc1240443caa23833bf62acd0a8abe2949ddced61d886cccb6746d4c8b83493bb3f8737fa7e854
6
+ metadata.gz: 3ad9d8f6485798ebe314bd561f040b44742bf892d89d044793c77b3eadb9b548c81dfa5884ca35b89eab044159354d5a46fc9ff99864e0df1b9660c69b16d6dc
7
+ data.tar.gz: dc66cae976602555b91ce985d6bdc7bf1c5fc3fb9491cc5f14a2debded4799951b1c7eafe7af9940b9986e25d76192969b7140ba58dd647b28a46482627e32f4
@@ -10,7 +10,7 @@ module Sidekiq
10
10
  class Batch
11
11
  class NoBlockGivenError < StandardError; end
12
12
 
13
- BID_EXPIRE_TTL = 108_000
13
+ BID_EXPIRE_TTL = 2_592_000
14
14
 
15
15
  attr_reader :bid, :description, :callback_queue, :created_at
16
16
 
@@ -9,7 +9,11 @@ module Sidekiq
9
9
  clazz, method = clazz.split("#") if (clazz.class == String && clazz.include?("#"))
10
10
  method = "on_#{event}" if method.nil?
11
11
  status = Sidekiq::Batch::Status.new(bid)
12
- clazz.constantize.new.send(method, status, opts)
12
+
13
+ if object = Object.const_get(clazz)
14
+ instance = object.new
15
+ instance.send(method, status, opts) if instance.respond_to?(method)
16
+ end
13
17
 
14
18
  send(event.to_sym, bid, status, parent_bid)
15
19
  end
@@ -1,5 +1,5 @@
1
1
  module Sidekiq
2
2
  class Batch
3
- VERSION = '0.1.4'.freeze
3
+ VERSION = '0.1.5'.freeze
4
4
  end
5
5
  end
@@ -24,5 +24,5 @@ Gem::Specification.new do |spec|
24
24
  spec.add_development_dependency "bundler", "~> 1.12"
25
25
  spec.add_development_dependency "rake", "~> 10.0"
26
26
  spec.add_development_dependency "rspec", "~> 3.0"
27
- spec.add_development_dependency "fakeredis", "~> 0.5.0"
27
+ spec.add_development_dependency "fakeredis", "~> 0.7.0"
28
28
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidekiq-batch
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.1.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Marcin Naglik
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-09-14 00:00:00.000000000 Z
11
+ date: 2018-10-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sidekiq
@@ -72,14 +72,14 @@ dependencies:
72
72
  requirements:
73
73
  - - "~>"
74
74
  - !ruby/object:Gem::Version
75
- version: 0.5.0
75
+ version: 0.7.0
76
76
  type: :development
77
77
  prerelease: false
78
78
  version_requirements: !ruby/object:Gem::Requirement
79
79
  requirements:
80
80
  - - "~>"
81
81
  - !ruby/object:Gem::Version
82
- version: 0.5.0
82
+ version: 0.7.0
83
83
  description: Sidekiq Batch Jobs Implementation
84
84
  email:
85
85
  - marcin.naglik@gmail.com
@@ -122,7 +122,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
122
122
  version: '0'
123
123
  requirements: []
124
124
  rubyforge_project:
125
- rubygems_version: 2.6.11
125
+ rubygems_version: 2.5.2.3
126
126
  signing_key:
127
127
  specification_version: 4
128
128
  summary: Sidekiq Batch Jobs