appsignal 0.10.5 → 0.10.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: b534937f18014e6942e96590872f412395b628c7
4
- data.tar.gz: 59e4b4d4ad5bb0eec58a9814a26680cb055966e9
3
+ metadata.gz: 29ac953458214ed9268bd6d52afd40b5c45785cd
4
+ data.tar.gz: 858cfc04cd727f92934d36c6d1dbcda240404d85
5
5
  SHA512:
6
- metadata.gz: 5345239997a144a05a572da7744cb3eb3c405931c3b3b37b0a4c1fcc1e49db7778abc22d39733ad711dd28ed1e535197ec9f0aa0dd1e5c346cd0db326a03bb0a
7
- data.tar.gz: b144ad46eba9528a1d98c08dd6ba6fd701e443ae7425a8a34390bde2dfd20bf88204430d7d4c6a57ec98c6965e2dcc87cf04b847d82b65f686a877f5a9a3bbb9
6
+ metadata.gz: 8e70b79af43d968f5b18e5d526ffc79a4f31e1e7f147f828b47cd011dbcb4455b9ca3eeadfb9262628e1bc4be3a83cbd550a48c20f5ee245eea7dec264ab6132
7
+ data.tar.gz: 8e453b41199aef1fa956a701b3d8a929c36d6d9222e5f216106e929e15e76510b66d6be543943796c652ab6235b1aa27006216717ca32bccad548e493fffbc0c
@@ -1,3 +1,6 @@
1
+ # 0.10.6
2
+ * Add config option to skip session data
3
+
1
4
  # 0.10.5
2
5
  * Don't shutdown in `at_exit`
3
6
  * Debug log about missing name in config
@@ -7,12 +7,13 @@ module Appsignal
7
7
  include Appsignal::CarefulLogger
8
8
 
9
9
  DEFAULT_CONFIG = {
10
- :ignore_exceptions => [],
11
- :ignore_actions => [],
12
- :send_params => true,
13
- :endpoint => 'https://push.appsignal.com/1',
10
+ :ignore_exceptions => [],
11
+ :ignore_actions => [],
12
+ :send_params => true,
13
+ :endpoint => 'https://push.appsignal.com/1',
14
14
  :slow_request_threshold => 200,
15
- :instrument_net_http => true
15
+ :instrument_net_http => true,
16
+ :skip_session_data => false
16
17
  }.freeze
17
18
 
18
19
  attr_reader :root_path, :env, :initial_config, :config_hash
@@ -45,8 +46,8 @@ module Appsignal
45
46
  end
46
47
  if config_hash && !config_hash[:name]
47
48
  @logger.debug(
48
- "There's no name defined in the config, " \
49
- "unless you're using the Heroku add-on you probably want to do this."
49
+ "There's no application name set in your config file. " \
50
+ "You should set one unless your app runs on Heroku."
50
51
  )
51
52
  end
52
53
  end
@@ -206,7 +206,7 @@
206
206
  def sanitize_session_data!
207
207
  @sanitized_session_data = Appsignal::Transaction::ParamsSanitizer.sanitize(
208
208
  request.session.to_hash
209
- )
209
+ ) if Appsignal.config[:skip_session_data] == false
210
210
  @fullpath = request.fullpath
211
211
  end
212
212
  end
@@ -1,3 +1,3 @@
1
1
  module Appsignal
2
- VERSION = '0.10.5'
2
+ VERSION = '0.10.6'
3
3
  end
@@ -19,6 +19,7 @@ describe Appsignal::Config do
19
19
  :ignore_exceptions => [],
20
20
  :ignore_actions => [],
21
21
  :instrument_net_http => true,
22
+ :skip_session_data => false,
22
23
  :send_params => true,
23
24
  :endpoint => 'https://push.appsignal.com/1',
24
25
  :slow_request_threshold => 200,
@@ -122,7 +123,7 @@ describe Appsignal::Config do
122
123
 
123
124
  it "should merge with the default config, fill the config hash and log about the missing name" do
124
125
  Appsignal.logger.should_receive(:debug).with(
125
- "There's no name defined in the config, unless you're using the Heroku add-on you probably want to do this."
126
+ "There's no application name set in your config file. You should set one unless your app runs on Heroku."
126
127
  )
127
128
 
128
129
  subject.config_hash.should == {
@@ -131,6 +132,7 @@ describe Appsignal::Config do
131
132
  :ignore_actions => [],
132
133
  :send_params => true,
133
134
  :instrument_net_http => true,
135
+ :skip_session_data => false,
134
136
  :endpoint => 'https://push.appsignal.com/1',
135
137
  :slow_request_threshold => 200,
136
138
  :active => true
@@ -598,6 +598,18 @@ describe Appsignal::Transaction do
598
598
  end
599
599
  end
600
600
  end
601
+
602
+ context "when skipping session data" do
603
+ before do
604
+ Appsignal.config = {:skip_session_data => true}
605
+ end
606
+
607
+ it "does not pass the session data into the params sanitizer" do
608
+ Appsignal::ParamsSanitizer.should_not_receive(:sanitize)
609
+ subject
610
+ transaction.sanitized_session_data.should == {}
611
+ end
612
+ end
601
613
  end
602
614
  end
603
615
  end
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.10.5
4
+ version: 0.10.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Beekman
@@ -12,7 +12,7 @@ authors:
12
12
  autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
- date: 2014-09-08 00:00:00.000000000 Z
15
+ date: 2014-09-09 00:00:00.000000000 Z
16
16
  dependencies:
17
17
  - !ruby/object:Gem::Dependency
18
18
  name: rack