appsignal 0.8.3 → 0.8.4.beta.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- N2UwODdmZmQyMDg4NDRlYzRkOWUyNWFkYzIxZTE4NTNmZWEyNzRiMQ==
4
+ MWUyMmRhZDY0NjU1MTNkNWUwZTg3NmZiOTA4YTE0NGY5NWRhMmU5Yw==
5
5
  data.tar.gz: !binary |-
6
- MWUwM2ZhOTY0NGVjYmVkZWJjOThmYWYxMGJiZDc0N2QwMmU5NzBhMQ==
6
+ YjljNDc0MDVhYzNjNjYzZjk1ZjRhOTM5MGI0N2Y5YzEyYTBjNGIyZQ==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- MjAzZWI1YTI5ZjYzYjFkZDQ2NmY3OTM5MzZhZWVlMzdmYzNhMWE0MmQxNzk4
10
- OWY3NjVlZTUyNjliNjBlYzA0MDc3NTFiMDk3MmFkNDRmYzQ0NDE4YzZjM2Ri
11
- MTFhYmI0NzdmMDZiNzZhNDE1ODM5YTBmYTM3NzMwY2Y4NmJkYjg=
9
+ MTBkM2E1OWJkYmNhZjRmYTdmNTViMjAxNzFjZWI1ZmRkZGE5ZjNiNGFmYjdm
10
+ ZjA3NGViMzRjZDU5YThmZmU1NjZjOWZhZTUxNzA0ZDBlYjRjOWI2MDc1NGM2
11
+ NDEwMzM4ZDNhNDhiNmMwMzIxMDFiMDFiNzhmNDA3OWJjMmVlOTA=
12
12
  data.tar.gz: !binary |-
13
- MGY1OTM5YjA3YjlmOWNkYTQxYTE0ODE5ZTYzODAzMzUxYzViYWZhMGY3OWI0
14
- NTRjZjk5MjNkNDIwZTI0NDMyNjZkNzNkNGNiODI2ZGEwMDFjYTM3NzBkYzgz
15
- ZmFjZTNiNmZhMjAzYWUwMDE1YWExZmY2ZjY3Yzc5ZTY0Yjc5MTI=
13
+ N2U1MDE3NGI2MWNkNzc3YzUyOGEwY2Y0NjAyZjE3ODQyODk1MDExMTExOTQ5
14
+ NjAwOGI5OTE2YzYxZGJlN2Q5NGEwOTRkOGIyNDA0NzUwZGY1NDkzNThiMGMz
15
+ Mjg0YzA5MmMxYjk1YzZmYjM0Zjc0N2MzNTYxZWRmNzMzMGE4N2E=
@@ -1,3 +1,6 @@
1
+ # 0.8.4
2
+ * Skip session sanitize if not a http request
3
+
1
4
  # 0.8.3
2
5
  * Restart thread when we've been forked
3
6
  * Only notify of deploy when active in capistrano
@@ -146,7 +146,7 @@ module Appsignal
146
146
 
147
147
  def add_sanitized_context!
148
148
  sanitize_environment!
149
- sanitize_session_data!
149
+ sanitize_session_data! if kind == 'http_request'
150
150
  sanitize_tags!
151
151
  @env = nil
152
152
  end
@@ -169,8 +169,9 @@ module Appsignal
169
169
  end
170
170
 
171
171
  def sanitize_session_data!
172
- @sanitized_session_data =
173
- Appsignal::Transaction::ParamsSanitizer.sanitize(request.session.to_hash)
172
+ @sanitized_session_data = Appsignal::Transaction::ParamsSanitizer.sanitize(
173
+ request.session.to_hash
174
+ )
174
175
  @fullpath = request.fullpath
175
176
  end
176
177
  end
@@ -1,3 +1,3 @@
1
1
  module Appsignal
2
- VERSION = '0.8.3'
2
+ VERSION = '0.8.4.beta.0'
3
3
  end
@@ -401,11 +401,26 @@ describe Appsignal::Transaction do
401
401
  describe '#add_sanitized_context!' do
402
402
  subject { transaction.send(:add_sanitized_context!) }
403
403
 
404
- it "delegates to sanitize_environment! and sanitize_session_data!" do
405
- transaction.should_receive(:sanitize_environment!)
406
- transaction.should_receive(:sanitize_session_data!)
407
- transaction.should_receive(:sanitize_tags!)
408
- subject
404
+ context "for a http request" do
405
+ before { transaction.stub(:kind => 'http_request') }
406
+
407
+ it "should call sanitize_environment!, sanitize_session_data! and sanitize_tags!" do
408
+ transaction.should_receive(:sanitize_environment!)
409
+ transaction.should_receive(:sanitize_session_data!)
410
+ transaction.should_receive(:sanitize_tags!)
411
+ subject
412
+ end
413
+ end
414
+
415
+ context "for a non-web request" do
416
+ before { transaction.stub(:kind => 'background_job') }
417
+
418
+ it "should not call sanitize_session_data!" do
419
+ transaction.should_receive(:sanitize_environment!)
420
+ transaction.should_not_receive(:sanitize_session_data!)
421
+ transaction.should_receive(:sanitize_tags!)
422
+ subject
423
+ end
409
424
  end
410
425
 
411
426
  specify { expect { subject }.to change(transaction, :env).to(nil) }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: appsignal
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.8.3
4
+ version: 0.8.4.beta.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Beekman
@@ -237,9 +237,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
237
237
  version: 1.9.3
238
238
  required_rubygems_version: !ruby/object:Gem::Requirement
239
239
  requirements:
240
- - - ! '>='
240
+ - - ! '>'
241
241
  - !ruby/object:Gem::Version
242
- version: '0'
242
+ version: 1.3.1
243
243
  requirements: []
244
244
  rubyforge_project:
245
245
  rubygems_version: 2.0.3