rack-failtale 0.1.0 → 0.1.1
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.
- data/README.md +7 -1
- data/lib/rack/failtale.rb +6 -1
- metadata +4 -4
data/README.md
CHANGED
@@ -3,6 +3,11 @@ Rack::Failtale
|
|
3
3
|
|
4
4
|
A very simple Rack Middleware for reporting errors to the Failtale Service.
|
5
5
|
|
6
|
+
Install:
|
7
|
+
--------
|
8
|
+
|
9
|
+
gem install rack-failtale
|
10
|
+
|
6
11
|
Usage:
|
7
12
|
------
|
8
13
|
|
@@ -12,4 +17,5 @@ Usage:
|
|
12
17
|
TODO:
|
13
18
|
-----
|
14
19
|
|
15
|
-
Allow for reporting to a Failtale service on other domains than
|
20
|
+
* Allow for reporting to a Failtale service on other domains than failtale.be. (see FailtaleReporter::base_uri)
|
21
|
+
* Allow for filtering of the exceptions and environment variables (so we won't show passwords and such in plain text)
|
data/lib/rack/failtale.rb
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
require "pp"
|
1
2
|
require "failtale-reporter"
|
2
3
|
|
3
4
|
module Rack
|
@@ -7,13 +8,17 @@ module Rack
|
|
7
8
|
def initialize(app, api_key = nil)
|
8
9
|
@app = app
|
9
10
|
FailtaleReporter.configure do |config|
|
11
|
+
config.default_reporter "rack"
|
10
12
|
config.api_token api_key
|
11
13
|
config.application_root ::File.dirname(::File.dirname(__FILE__))
|
14
|
+
config.information_collector do |error,env|
|
15
|
+
error.environment.merge!(env)
|
16
|
+
end
|
12
17
|
end
|
13
18
|
end
|
14
19
|
|
15
20
|
def call(env)
|
16
|
-
FailtaleReporter.report do
|
21
|
+
FailtaleReporter.report(nil,env) do
|
17
22
|
@app.call(env)
|
18
23
|
end
|
19
24
|
end
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rack-failtale
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 25
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 1
|
9
|
-
-
|
10
|
-
version: 0.1.
|
9
|
+
- 1
|
10
|
+
version: 0.1.1
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- "Robert Sk\xC3\xB6ld"
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2010-
|
18
|
+
date: 2010-07-02 00:00:00 +02:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|