rack-insight 0.5.11 → 0.5.12
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +1 -0
- data/CHANGELOG +20 -0
- data/Gemfile.lock +1 -1
- data/README.md +5 -4
- data/lib/rack/insight/public/__insight__/bookmarklet.js +1 -0
- data/lib/rack/insight/public/__insight__/insight.js +3 -1
- data/lib/rack/insight/toolbar.rb +5 -1
- data/lib/rack/insight/version.rb +1 -1
- data/lib/rack/insight/views/toolbar.html.erb +4 -0
- metadata +2 -2
data/.gitignore
CHANGED
data/CHANGELOG
CHANGED
@@ -1,3 +1,23 @@
|
|
1
|
+
== HEAD
|
2
|
+
|
3
|
+
|
4
|
+
== 0.5.12 / 2012-09-10
|
5
|
+
|
6
|
+
* Other
|
7
|
+
|
8
|
+
* Improving documentation by Peter Boling
|
9
|
+
|
10
|
+
|
11
|
+
* New Features
|
12
|
+
|
13
|
+
* persistent toolbar position by Alif Rachmawadi
|
14
|
+
|
15
|
+
== 0.5.11 / 2012-09-05
|
16
|
+
|
17
|
+
* Bug Fixes
|
18
|
+
|
19
|
+
* Fixed Encoding::CompatibilityError by Michael Grosser
|
20
|
+
|
1
21
|
== 0.5.10 / 2012-09-04 (Peter Boling)
|
2
22
|
|
3
23
|
* Bug Fixes
|
data/Gemfile.lock
CHANGED
data/README.md
CHANGED
@@ -77,7 +77,7 @@ If you wish to use the logger panel define the LOGGER constant that is a ruby
|
|
77
77
|
Logger or ActiveSupport::BufferedLogger
|
78
78
|
|
79
79
|
Configure Rack::Insight
|
80
|
-
|
80
|
+
---------------------
|
81
81
|
|
82
82
|
Pattern:
|
83
83
|
|
@@ -105,8 +105,8 @@ Options:
|
|
105
105
|
:panel_load_paths => [File::join('rack', 'insight', 'panels')] (default)
|
106
106
|
See *Configuring custom panels* section for example usage
|
107
107
|
|
108
|
-
|
109
|
-
|
108
|
+
Configure Middleware
|
109
|
+
--------------------
|
110
110
|
|
111
111
|
Specify the set of panels you want, in the order you want them to appear:
|
112
112
|
|
@@ -151,7 +151,7 @@ When you create custom panels use the render_template method and pass it the pat
|
|
151
151
|
render_template 'thunder_panel/views/thor'
|
152
152
|
|
153
153
|
Running Rack::Insight in staging or production
|
154
|
-
|
154
|
+
----------------------------------------------
|
155
155
|
|
156
156
|
We have have found that Rack::Insight is fast enough to run in production for specific troubleshooting efforts.
|
157
157
|
|
@@ -174,6 +174,7 @@ Restrict access using a password:
|
|
174
174
|
|
175
175
|
ActionController::Dispatcher.middleware.use "Rack::Insight::App",
|
176
176
|
:secret_key => "someverylongandveryhardtoguesspreferablyrandomstring",
|
177
|
+
:ip_masks => false # Default is 127.0.0.1
|
177
178
|
:password => "yourpassword"
|
178
179
|
|
179
180
|
#### custom file path for the logging database ####
|
@@ -211,6 +211,7 @@ document.insightEnable = function() {
|
|
211
211
|
document.insightDisable = function() {
|
212
212
|
document.eraseCookie('rack-insight_password');
|
213
213
|
document.eraseCookie('rack-insight_enabled');
|
214
|
+
document.eraseCookie('rack-insight_position');
|
214
215
|
window.location.reload();
|
215
216
|
}
|
216
217
|
|
@@ -106,7 +106,9 @@ jQuery(function($) {
|
|
106
106
|
$.insight.changeRequest($(this).val())
|
107
107
|
});
|
108
108
|
$('#rack-insight_debug_button').live('click',function(){
|
109
|
-
$('#rack-insight').
|
109
|
+
new_position = ($('#rack-insight').attr('class')== 'rack-insight_top') ? 'bottom' : 'top';
|
110
|
+
document.createCookie('rack-insight_position', new_position);
|
111
|
+
$('#rack-insight').removeClass('rack-insight_top rack-insight_bottom').addClass('rack-insight_' + new_position);
|
110
112
|
return false;
|
111
113
|
});
|
112
114
|
$('#rack-insight_disable_button').live('click',function(){
|
data/lib/rack/insight/toolbar.rb
CHANGED
@@ -54,7 +54,11 @@ module Rack::Insight
|
|
54
54
|
{ :id => row[0], :method => row[1], :path => row[2] }
|
55
55
|
end
|
56
56
|
|
57
|
-
|
57
|
+
unless verbose(:silent)
|
58
|
+
logger.info do
|
59
|
+
"Injecting toolbar: active panels: #{@insight.panels.map{|pnl| pnl.class.name}.inspect}"
|
60
|
+
end
|
61
|
+
end
|
58
62
|
|
59
63
|
headers_fragment = render_template("headers_fragment",
|
60
64
|
:panels => @insight.panels,
|
data/lib/rack/insight/version.rb
CHANGED
@@ -13,6 +13,10 @@
|
|
13
13
|
<script>
|
14
14
|
$(function($) {
|
15
15
|
$.insight.request_id = <%= request_id %>
|
16
|
+
if(document.readCookie('rack-insight_position')) {
|
17
|
+
$('#rack-insight').removeClass('rack-insight_top rack-insight_bottom')
|
18
|
+
.addClass('rack-insight_' + document.readCookie('rack-insight_position'));
|
19
|
+
}
|
16
20
|
})
|
17
21
|
</script>
|
18
22
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rack-insight
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.12
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -12,7 +12,7 @@ authors:
|
|
12
12
|
autorequire:
|
13
13
|
bindir: bin
|
14
14
|
cert_chain: []
|
15
|
-
date: 2012-09-
|
15
|
+
date: 2012-09-10 00:00:00.000000000 Z
|
16
16
|
dependencies:
|
17
17
|
- !ruby/object:Gem::Dependency
|
18
18
|
name: rack
|