resque-rollbar 0.3.0 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +12 -2
- data/CHANGELOG.md +3 -0
- data/LICENSE.txt +1 -1
- data/gemfiles/{rollbar-1.2.x.gemfile → rollbar-1.x.gemfile} +1 -1
- data/gemfiles/rollbar-2.x.gemfile +14 -0
- data/lib/resque/failure/rollbar.rb +1 -13
- data/lib/resque/rollbar.rb +1 -4
- data/lib/resque/rollbar/version.rb +1 -1
- data/resque-rollbar.gemspec +1 -1
- data/spec/resque/failure/rollbar_spec.rb +8 -13
- data/spec/rollbar_spec.rb +2 -2
- metadata +8 -6
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ea1c5d272a6a3d0d12488fa231d843e213695f3d
|
4
|
+
data.tar.gz: 6aaf7a6291af7de4e42afdb92e8b81ee01409403
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 69fc791dad9870c35314304070922652eb80f7510e00040b103eba88a9a13f5fe37bd78304a5177e669d1ce3aae740f87b9ccdcd8453ab1bf18d1766eb1ceb2d
|
7
|
+
data.tar.gz: d189aa0578572150b3ebe1c725f1bd8f272b34038faaf0b45630a7f5cfb1e00953716f0cf6fc1dd7b91290e2562a933a11b5090678dfd307b70d33342cf99215
|
data/.travis.yml
CHANGED
@@ -1,15 +1,25 @@
|
|
1
1
|
language: ruby
|
2
|
+
cache: bundler
|
2
3
|
rvm:
|
3
4
|
- 1.8.7
|
4
5
|
- 1.9.3
|
5
6
|
- 2.0.0
|
6
|
-
- 2.1.
|
7
|
+
- 2.1.8
|
8
|
+
- 2.2.4
|
9
|
+
- 2.3.0
|
7
10
|
- jruby-18mode
|
8
11
|
- jruby-19mode
|
12
|
+
- jruby-head
|
9
13
|
- rbx
|
14
|
+
- rbx-2
|
10
15
|
gemfile:
|
11
|
-
- gemfiles/rollbar-1.
|
16
|
+
- gemfiles/rollbar-1.x.gemfile
|
17
|
+
- gemfiles/rollbar-2.x.gemfile
|
12
18
|
matrix:
|
13
19
|
allow_failures:
|
14
20
|
- rvm: rbx
|
21
|
+
- rvm: rbx-2
|
15
22
|
fast_finish: true
|
23
|
+
before_install:
|
24
|
+
- gem install bundler
|
25
|
+
sudo: false
|
data/CHANGELOG.md
ADDED
data/LICENSE.txt
CHANGED
@@ -9,19 +9,7 @@ module Resque
|
|
9
9
|
end
|
10
10
|
|
11
11
|
def rollbar_payload
|
12
|
-
|
13
|
-
payload.merge(:use_exception_level_filters => true)
|
14
|
-
else
|
15
|
-
payload
|
16
|
-
end
|
17
|
-
end
|
18
|
-
|
19
|
-
def use_exception_level_filters?
|
20
|
-
rollbar_version.split('.')[1].to_i > 3
|
21
|
-
end
|
22
|
-
|
23
|
-
def rollbar_version
|
24
|
-
::Rollbar::VERSION
|
12
|
+
payload.merge(:use_exception_level_filters => true)
|
25
13
|
end
|
26
14
|
end
|
27
15
|
end
|
data/lib/resque/rollbar.rb
CHANGED
@@ -1,9 +1,6 @@
|
|
1
1
|
require 'resque/failure/rollbar'
|
2
2
|
|
3
3
|
Resque.before_first_fork do
|
4
|
-
# Force synchronous reporting
|
5
|
-
::Rollbar.configure do |config|
|
6
|
-
config.use_async = false
|
7
|
-
end
|
4
|
+
::Rollbar.configure { |c| c.use_async = false } # Force synchronous reporting
|
8
5
|
::Rollbar.reset_notifier!
|
9
6
|
end
|
data/resque-rollbar.gemspec
CHANGED
@@ -17,7 +17,7 @@ Gem::Specification.new do |gem|
|
|
17
17
|
gem.require_paths = ['lib']
|
18
18
|
|
19
19
|
gem.add_dependency 'resque'
|
20
|
-
gem.add_dependency 'rollbar', '>= 1.
|
20
|
+
gem.add_dependency 'rollbar', '>= 1.4'
|
21
21
|
|
22
22
|
gem.add_development_dependency 'rake'
|
23
23
|
gem.add_development_dependency 'json'
|
@@ -9,21 +9,16 @@ describe Resque::Failure::Rollbar do
|
|
9
9
|
Resque::Failure::Rollbar.new(exception, worker, queue, payload)
|
10
10
|
end
|
11
11
|
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
context 'with Rollbar version > 1.3' do
|
18
|
-
let(:rollbar_payload) { payload.merge(:use_exception_level_filters => true) }
|
19
|
-
|
20
|
-
before do
|
21
|
-
allow(backend).to receive(:rollbar_version).and_return('1.4.0')
|
12
|
+
describe '#save' do
|
13
|
+
it 'notifies Rollbar about the error' do
|
14
|
+
expect(Rollbar.notifier).to receive(:error).with(exception, backend.rollbar_payload)
|
15
|
+
backend.save
|
22
16
|
end
|
17
|
+
end
|
23
18
|
|
24
|
-
|
25
|
-
|
26
|
-
backend.
|
19
|
+
describe '#rollbar_payload' do
|
20
|
+
it 'returns the payload with use_exception_level_filters set to true' do
|
21
|
+
expect(backend.rollbar_payload).to eq payload.merge(:use_exception_level_filters => true)
|
27
22
|
end
|
28
23
|
end
|
29
24
|
end
|
data/spec/rollbar_spec.rb
CHANGED
@@ -13,8 +13,8 @@ describe 'resque-rollbar' do
|
|
13
13
|
end
|
14
14
|
end
|
15
15
|
|
16
|
-
it 'disables
|
17
|
-
expect(Rollbar.configuration.use_async).to
|
16
|
+
it 'disables async reporting from the resque process' do
|
17
|
+
expect(Rollbar.configuration.use_async).to be false
|
18
18
|
end
|
19
19
|
end
|
20
20
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: resque-rollbar
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dimko
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-03-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: resque
|
@@ -30,14 +30,14 @@ dependencies:
|
|
30
30
|
requirements:
|
31
31
|
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '1.
|
33
|
+
version: '1.4'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '1.
|
40
|
+
version: '1.4'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rake
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -104,11 +104,13 @@ files:
|
|
104
104
|
- ".gitignore"
|
105
105
|
- ".rspec"
|
106
106
|
- ".travis.yml"
|
107
|
+
- CHANGELOG.md
|
107
108
|
- Gemfile
|
108
109
|
- LICENSE.txt
|
109
110
|
- README.md
|
110
111
|
- Rakefile
|
111
|
-
- gemfiles/rollbar-1.
|
112
|
+
- gemfiles/rollbar-1.x.gemfile
|
113
|
+
- gemfiles/rollbar-2.x.gemfile
|
112
114
|
- lib/resque/failure/rollbar.rb
|
113
115
|
- lib/resque/rollbar.rb
|
114
116
|
- lib/resque/rollbar/version.rb
|
@@ -135,7 +137,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
135
137
|
version: '0'
|
136
138
|
requirements: []
|
137
139
|
rubyforge_project:
|
138
|
-
rubygems_version: 2.
|
140
|
+
rubygems_version: 2.4.8
|
139
141
|
signing_key:
|
140
142
|
specification_version: 4
|
141
143
|
summary: Resque failure backend for Rollbar
|