sidecloq 0.4.7 → 0.4.8

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: 369b9ecaad14a3f613c3c2a4afef4d3b439ceed861525ca99286668293fa61c8
4
- data.tar.gz: 75f2d86e8ccaea4b089407eef5cf834f9ee7c0f31251b6a1acb72c5b43a15e78
3
+ metadata.gz: 1a6c13b2ea0bb666923cce6ad6e6113a6c4c51daebbaf1ecff8fce54c78deb6a
4
+ data.tar.gz: ef6a198c02e995dd5b68abf21e9fe31f5f2e3782b2bda635a1ec44e3b640d855
5
5
  SHA512:
6
- metadata.gz: 3b60ac764c22dbff7d9519a0f9ce8b8484da0b775e3b875506332d71d17bf377ab6655c92f966a3140a258fb684a440638d8941e0eba0a72e3b58d4dbbd75c2f
7
- data.tar.gz: f5877e191dd1cbca6650e3f293c3a601aee96029a8034ecc6490bfd9badc3492d340b75aa2d508b6270decf8da75f46a3dce28d739ca75fe759d14a01e74bbc0
6
+ metadata.gz: 3cfd40a72a8f9d8a471eb985063e1294dba1643cf449c6ec5f3df1ef75e157f104be57ea9e86552fb9c62aad19022ada1b1d705948d763db8ac78a79ec263200
7
+ data.tar.gz: b95e48e480c0d9db46216c0cef0290a9d6210803a85c5de6769524a10cded46f9b26c8d5ceb42e53113a689d2c5f121d17c35571d0a567ffc3a081e4fb889c0c
data/.gitignore CHANGED
@@ -9,3 +9,5 @@
9
9
  /tmp/
10
10
  /.ruby-version
11
11
  /.ruby-gemset
12
+ gemfiles/*.lock
13
+ .bundle/
@@ -5,38 +5,32 @@ cache: bundler
5
5
  services:
6
6
  - redis-server
7
7
  rvm:
8
- - 2.0.0
9
- - 2.1.10
10
- - 2.2.10
11
- - 2.3.8
12
8
  - 2.4.5
13
9
  - 2.5.3
14
- - 2.6.1
10
+ - 2.6.5
15
11
  - jruby-9.1.17.0
16
- - jruby-9.2.5.0
12
+ - jruby-9.2.8.0
17
13
  env:
18
14
  - "sidekiq=3.5.4"
19
15
  - "sidekiq=4.2.10"
20
16
  - "sidekiq=5.1.3"
21
- - "sidekiq=5.2.5"
17
+ - "sidekiq=5.2.7"
18
+ - "sidekiq=6.0.1"
22
19
  - "sidekiq=master"
23
20
  matrix:
24
21
  allow_failures:
25
22
  - env: "sidekiq=master"
26
23
  exclude:
27
- # sidekiq 5 does not support < ruby 2.2.2
28
- - rvm: 2.0.0
24
+ # sidekiq 6 does not support < ruby 2.5
25
+ - rvm: 2.4.5
26
+ env: sidekiq=6.0.1
27
+ - rvm: 2.4.5
29
28
  env: sidekiq=master
30
- - rvm: 2.0.0
31
- env: sidekiq=5.1.3
32
- - rvm: 2.0.0
33
- env: sidekiq=5.2.5
34
- - rvm: 2.1.10
29
+ - rvm: jruby-9.1.17.0
30
+ env: sidekiq=6.0.1
31
+ - rvm: jruby-9.1.17.0
35
32
  env: sidekiq=master
36
- - rvm: 2.1.10
37
- env: sidekiq=5.1.3
38
- - rvm: 2.1.10
39
- env: sidekiq=5.2.5
33
+
40
34
  fast_finish: true
41
35
  after_success:
42
36
  - bundle exec codeclimate-test-reporter
@@ -0,0 +1,19 @@
1
+ appraise "sidekiq-3.5" do
2
+ gem "sidekiq", "3.5.4"
3
+ end
4
+
5
+ appraise "sidekiq-4.2" do
6
+ gem "sidekiq", "4.2.10"
7
+ end
8
+
9
+ appraise "sidekiq-5.1" do
10
+ gem "sidekiq", "5.1.3"
11
+ end
12
+
13
+ appraise "sidekiq-5.2" do
14
+ gem "sidekiq", "5.2.7"
15
+ end
16
+
17
+ appraise "sidekiq-6.0" do
18
+ gem "sidekiq", "6.0.1"
19
+ end
data/Rakefile CHANGED
@@ -36,6 +36,7 @@ task :web do
36
36
  end
37
37
 
38
38
  class DoWork
39
+ include Sidekiq::Worker
39
40
  end
40
41
 
41
42
  require 'sidekiq/web'
@@ -0,0 +1,17 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "sidekiq", "3.5.4"
6
+
7
+ group :test do
8
+ gem "simplecov"
9
+ gem "codeclimate-test-reporter", "~> 1.0.0"
10
+ end
11
+
12
+ platforms :mri, :rbx do
13
+ gem "pry"
14
+ gem "minitest-utils"
15
+ end
16
+
17
+ gemspec path: "../"
@@ -0,0 +1,17 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "sidekiq", "4.2.10"
6
+
7
+ group :test do
8
+ gem "simplecov"
9
+ gem "codeclimate-test-reporter", "~> 1.0.0"
10
+ end
11
+
12
+ platforms :mri, :rbx do
13
+ gem "pry"
14
+ gem "minitest-utils"
15
+ end
16
+
17
+ gemspec path: "../"
@@ -0,0 +1,17 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "sidekiq", "5.1.3"
6
+
7
+ group :test do
8
+ gem "simplecov"
9
+ gem "codeclimate-test-reporter", "~> 1.0.0"
10
+ end
11
+
12
+ platforms :mri, :rbx do
13
+ gem "pry"
14
+ gem "minitest-utils"
15
+ end
16
+
17
+ gemspec path: "../"
@@ -0,0 +1,17 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "sidekiq", "5.2.7"
6
+
7
+ group :test do
8
+ gem "simplecov"
9
+ gem "codeclimate-test-reporter", "~> 1.0.0"
10
+ end
11
+
12
+ platforms :mri, :rbx do
13
+ gem "pry"
14
+ gem "minitest-utils"
15
+ end
16
+
17
+ gemspec path: "../"
@@ -0,0 +1,17 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "sidekiq", "6.0.1"
6
+
7
+ group :test do
8
+ gem "simplecov"
9
+ gem "codeclimate-test-reporter", "~> 1.0.0"
10
+ end
11
+
12
+ platforms :mri, :rbx do
13
+ gem "pry"
14
+ gem "minitest-utils"
15
+ end
16
+
17
+ gemspec path: "../"
@@ -8,15 +8,34 @@ module Sidecloq
8
8
  @context = ctx
9
9
  end
10
10
 
11
+ def sidekiq_logging_context_method
12
+ @sidekiq_logging_context_method ||=
13
+ begin
14
+ if defined? Sidekiq::Logging
15
+ # sidekiq < 6
16
+ Sidekiq::Logging.method(:with_context)
17
+ elsif defined?(Sidekiq::Context)
18
+ # sidekiq 6, <= 6.0.1
19
+ Sidekiq::Context.method(:with)
20
+ else
21
+ # sidekiq 6, master
22
+ Sidekiq.logger.method(:with_context)
23
+ end
24
+ end
25
+ end
26
+
11
27
  def method_missing(meth, *args)
12
- Sidekiq::Logging.with_context(@context) do
28
+ sidekiq_logging_context_method.call(@context) do
13
29
  Sidekiq.logger.send(meth, *args)
14
30
  end
15
31
  end
16
32
  end
17
33
 
34
+
18
35
  def logger
19
- @logger ||= ContextLogger.new('Sidecloq')
36
+ @logger ||= ContextLogger.new(
37
+ defined?(Sidekiq::Logging) ? 'Sidecloq' : {sidecloq: true}
38
+ )
20
39
  end
21
40
 
22
41
  def redis(&block)
@@ -1,3 +1,3 @@
1
1
  module Sidecloq
2
- VERSION = '0.4.7'
2
+ VERSION = '0.4.8'
3
3
  end
@@ -19,7 +19,7 @@ Gem::Specification.new do |spec|
19
19
  spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
20
20
  spec.require_paths = ['lib']
21
21
 
22
- spec.add_dependency 'sidekiq', '>= 3.5.4', '< 6'
22
+ spec.add_dependency 'sidekiq', '>= 3.5.4', '< 7'
23
23
  spec.add_dependency 'redlock', '>= 0.2.0', '< 2'
24
24
  # mimics some dev dependencies of sidekiq:
25
25
  spec.add_dependency 'concurrent-ruby'
@@ -27,6 +27,7 @@ Gem::Specification.new do |spec|
27
27
 
28
28
  spec.add_development_dependency 'rake', '>= 10.0'
29
29
  spec.add_development_dependency 'minitest'
30
+ spec.add_development_dependency "appraisal"
30
31
  spec.add_development_dependency 'redis-namespace', '~> 1.5', '>= 1.5.3'
31
32
  spec.add_development_dependency 'activejob'
32
33
  end
@@ -26,7 +26,7 @@
26
26
  <td>
27
27
  <form action="<%= root_path %>recurring/<%= CGI.escape(name).gsub('+', '%20') %>/enqueue" method="post">
28
28
  <%= csrf_tag if respond_to?(:csrf_tag) %>
29
- <input class='btn btn-xs pull-left' type="submit" name="enque" value="<%= t('Enqueue Now') %>"/>
29
+ <input class='btn btn-primary btn-xs' type="submit" name="enque" value="<%= t('Enqueue Now') %>"/>
30
30
  </form>
31
31
  </td>
32
32
  </tr>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidecloq
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.7
4
+ version: 0.4.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Robinson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-04-01 00:00:00.000000000 Z
11
+ date: 2019-10-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sidekiq
@@ -19,7 +19,7 @@ dependencies:
19
19
  version: 3.5.4
20
20
  - - "<"
21
21
  - !ruby/object:Gem::Version
22
- version: '6'
22
+ version: '7'
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,7 +29,7 @@ dependencies:
29
29
  version: 3.5.4
30
30
  - - "<"
31
31
  - !ruby/object:Gem::Version
32
- version: '6'
32
+ version: '7'
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: redlock
35
35
  requirement: !ruby/object:Gem::Requirement
@@ -112,6 +112,20 @@ dependencies:
112
112
  - - ">="
113
113
  - !ruby/object:Gem::Version
114
114
  version: '0'
115
+ - !ruby/object:Gem::Dependency
116
+ name: appraisal
117
+ requirement: !ruby/object:Gem::Requirement
118
+ requirements:
119
+ - - ">="
120
+ - !ruby/object:Gem::Version
121
+ version: '0'
122
+ type: :development
123
+ prerelease: false
124
+ version_requirements: !ruby/object:Gem::Requirement
125
+ requirements:
126
+ - - ">="
127
+ - !ruby/object:Gem::Version
128
+ version: '0'
115
129
  - !ruby/object:Gem::Dependency
116
130
  name: redis-namespace
117
131
  requirement: !ruby/object:Gem::Requirement
@@ -155,10 +169,16 @@ extra_rdoc_files: []
155
169
  files:
156
170
  - ".gitignore"
157
171
  - ".travis.yml"
172
+ - Appraisals
158
173
  - Gemfile
159
174
  - LICENSE.txt
160
175
  - README.md
161
176
  - Rakefile
177
+ - gemfiles/sidekiq_3.5.gemfile
178
+ - gemfiles/sidekiq_4.2.gemfile
179
+ - gemfiles/sidekiq_5.1.gemfile
180
+ - gemfiles/sidekiq_5.2.gemfile
181
+ - gemfiles/sidekiq_6.0.gemfile
162
182
  - lib/sidecloq.rb
163
183
  - lib/sidecloq/job_enqueuer.rb
164
184
  - lib/sidecloq/locker.rb
@@ -189,7 +209,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
189
209
  - !ruby/object:Gem::Version
190
210
  version: '0'
191
211
  requirements: []
192
- rubygems_version: 3.0.1
212
+ rubygems_version: 3.0.6
193
213
  signing_key:
194
214
  specification_version: 4
195
215
  summary: Recurring / Periodic / Scheduled / Cron job extension for Sidekiq