rollbar 0.11.6 → 0.11.7

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: bbb658a771dc1cbad8de7954d57946917e118850
4
- data.tar.gz: 105c6f0298070083eabd46665a6311331c40918f
3
+ metadata.gz: b7023de85d236f0fbba32430474796aeac7d795e
4
+ data.tar.gz: 9ab46c0f7262e45fc5280cbaf4be584293b3d8c9
5
5
  SHA512:
6
- metadata.gz: 792ff9b09527b95a6bd284da0df1fea31671fe2cd2140d2aac334edf3e5009af703ef57d4ff03d37c1137b7967d406bc307269b987b4cca81c0d3fe9ae3d545f
7
- data.tar.gz: e9b9cc45ed82b74a4bc02189c86dd2a27f5644108615f2d33bc72b7a5d4c291bdbf54328be4a4cb2ea2515c541d41c3b226a7e5dc57634bc96f6007b320907ff
6
+ metadata.gz: df0955081c95d86bc61e141734b3125ef660b5fa23e646a1011387cb21f2c759adf7d732ae0c563a323836093118e20ac43e84e62c00a17fdca03a1a8fadc685
7
+ data.tar.gz: d1ab33bad3b7825cebeb9eebb9adbc5e13390f1b6b345e10e502de30afa402e37f02f569a02c718844651ef3cdf1b4883023a2e5a10ef57c54ccada40dcef487
data/CHANGELOG.md CHANGED
@@ -1,5 +1,8 @@
1
1
  # Change Log
2
2
 
3
+ **0.11.7**
4
+ - Remove ActiveRecord railtie requirement introduced in 0.11.6
5
+
3
6
  **0.11.6**
4
7
  - Adding new middleware that grabs possible database-hitting person data before the rake connection pool cleanup middleware
5
8
 
data/README.md CHANGED
@@ -147,6 +147,12 @@ config.person_username_method = "user_name" # default is "username"
147
147
  config.person_email_method = "email_address" # default is "email"
148
148
  ```
149
149
 
150
+ ### If using Rails and not ActiveRecord
151
+
152
+ By default, the `Rollbar::Middleware::Rails::RollbarRequestStore` middleware is inserted just before the `ActiveRecord::ConnectionAdapters::ConnectionManagement` middleware if `ActiveRecord` is defined. This middleware ensures that any database calls needed to grab person data are executed before connections are cleaned up in the `ConnectionManagement` middleware.
153
+
154
+ If you are not using `ActiveRecord`, make sure you include the `RollbarRequestStore` middleware before any middlewares that do similar connection clean up.
155
+
150
156
  ## Including additional runtime data
151
157
 
152
158
  You can provide a lambda that will be called for each exception or message report. ```custom_data_method``` should be a lambda that takes no arguments and returns a hash.
@@ -314,11 +320,14 @@ Some users have reported problems with Zeus when ```rake``` was not explicitly i
314
320
 
315
321
  If you run into any issues, please email us at [support@rollbar.com](mailto:support@rollbar.com)
316
322
 
323
+ You can also find us in IRC: [#rollbar on chat.freenode.net](irc://chat.freenode.net/rollbar)
324
+
325
+ For bug reports, please [open an issue on GitHub](https://github.com/rollbar/rollbar-gem/issues/new).
317
326
 
318
327
  ## Contributing
319
328
 
320
329
  1. Fork it
321
- 2. Create your feature branch (```git checkout -b my-new-feature```)
330
+ 2. Create your feature branch (```git checkout -b my-new-feature```).
322
331
  3. Commit your changes (```git commit -am 'Added some feature'```)
323
332
  4. Push to the branch (```git push origin my-new-feature```)
324
333
  5. Create new Pull Request
@@ -7,10 +7,12 @@ module Rollbar
7
7
  require 'rollbar/rake_tasks'
8
8
  end
9
9
 
10
- initializer 'rollbar.middleware.rails' do |app|
11
- require 'rollbar/middleware/rails/rollbar_request_store'
12
- app.config.middleware.insert_after ActiveRecord::ConnectionAdapters::ConnectionManagement,
13
- Rollbar::Middleware::Rails::RollbarRequestStore
10
+ if defined? ActiveRecord
11
+ initializer 'rollbar.middleware.rails' do |app|
12
+ require 'rollbar/middleware/rails/rollbar_request_store'
13
+ app.config.middleware.insert_after ActiveRecord::ConnectionAdapters::ConnectionManagement,
14
+ Rollbar::Middleware::Rails::RollbarRequestStore
15
+ end
14
16
  end
15
17
 
16
18
  config.after_initialize do
@@ -6,7 +6,14 @@ module Rollbar
6
6
  ].freeze
7
7
 
8
8
  def extract_person_data_from_controller(env)
9
- person_data = env['rollbar.person_data'] || {}
9
+ if env.has_key? 'rollbar.person_data'
10
+ person_data = env['rollbar.person_data'] || {}
11
+ else
12
+ controller = env['action_controller.instance']
13
+ person_data = controller ? controller.try(:rollbar_person_data) : {}
14
+ end
15
+
16
+ person_data
10
17
  end
11
18
 
12
19
  def extract_request_data_from_rack(env)
@@ -1,3 +1,3 @@
1
1
  module Rollbar
2
- VERSION = "0.11.6"
2
+ VERSION = "0.11.7"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rollbar
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.6
4
+ version: 0.11.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian Rue
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-10-23 00:00:00.000000000 Z
11
+ date: 2013-10-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: multi_json