Skip to content

Commit

Permalink
merged
Browse files Browse the repository at this point in the history
  • Loading branch information
IdahoEv committed Feb 26, 2012
2 parents 79ea46b + 7ed14b3 commit 169d6b4
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 7 deletions.
8 changes: 8 additions & 0 deletions .gitignore
@@ -1,2 +1,10 @@
*.sw? *.sw?
*.gem *.gem
.bundle/
.conductor/
corundum/
doc/
insight-test.log
insight.sqlite
notions-and-tests/
pkg/
4 changes: 4 additions & 0 deletions .simplecov
@@ -0,0 +1,4 @@
SimpleCov.start do
coverage_dir "doc/coverage"
add_filter "./spec"
end
13 changes: 7 additions & 6 deletions README.md
Expand Up @@ -50,10 +50,10 @@ Add this to your Gemfile


In config/environments/development.rb, add: In config/environments/development.rb, add:


config.middleware.use "Insight", config.middleware.use "Insight::App",
:secret_key => "someverylongandveryhardtoguesspreferablyrandomstring" :secret_key => "someverylongandveryhardtoguesspreferablyrandomstring"


Any environment with Insight loaded will have a link to "Insight" in the upper left. Clicking that link will load the toolbar. Any environment with Insight loaded will have a link to "Insight" added to as the last child of BODY to normal responses. Clicking that link will load the toolbar. It's set with an id of "logical-insight-enabler", so it can be styled to go somewhere more noticeable. E.g. "position: absolute; top: 0; left: 0"


Using with non-Rails Rack apps Using with non-Rails Rack apps
------------------------------ ------------------------------
Expand All @@ -69,7 +69,7 @@ Specify the set of panels you want, in the order you want them to appear:


require "rack/bug" require "rack/bug"


ActionController::Dispatcher.middleware.use Insight, ActionController::Dispatcher.middleware.use "Insight::App",
:secret_key => "someverylongandveryhardtoguesspreferablyrandomstring", :secret_key => "someverylongandveryhardtoguesspreferablyrandomstring",
:panel_files => %w[ :panel_files => %w[
timer_panel timer_panel
Expand Down Expand Up @@ -97,13 +97,13 @@ Restrict access to particular IP addresses:


require "ipaddr" require "ipaddr"


ActionController::Dispatcher.middleware.use "Insight" ActionController::Dispatcher.middleware.use "Insight::App"
:secret_key => "someverylongandveryhardtoguesspreferablyrandomstring", :secret_key => "someverylongandveryhardtoguesspreferablyrandomstring",
:ip_masks => [IPAddr.new("2.2.2.2/0")] :ip_masks => [IPAddr.new("2.2.2.2/0")]


Restrict access using a password: Restrict access using a password:


ActionController::Dispatcher.middleware.use "Insight", ActionController::Dispatcher.middleware.use "Insight::App",
:secret_key => "someverylongandveryhardtoguesspreferablyrandomstring", :secret_key => "someverylongandveryhardtoguesspreferablyrandomstring",
:password => "yourpassword" :password => "yourpassword"


Expand All @@ -113,10 +113,11 @@ Authors


- Maintained by [Judson Lester](mailto:judson@lrdesign.com) - Maintained by [Judson Lester](mailto:judson@lrdesign.com)
- Contributions from Luke Melia, Joey Aghion, Tim Connor, and more - Contributions from Luke Melia, Joey Aghion, Tim Connor, and more
- Based on Rack::Bug by Bryan Helmkamp


Thanks Thanks
------ ------
Insight owes a lot to Rack::Bug, as the basis project. There's a lot of smart in there. Insight owes a lot to Rack::Bug, as the basis project. There's a lot of smart in there. Many thanks to Bryan for building it.


Inspiration for Rack::Bug is primarily from the Django debug toolbar. Additional ideas from Rails footnotes, Rack's ShowException middleware, Oink, and Rack::Cache Inspiration for Rack::Bug is primarily from the Django debug toolbar. Additional ideas from Rails footnotes, Rack's ShowException middleware, Oink, and Rack::Cache


Expand Down
3 changes: 2 additions & 1 deletion lib/insight/panels/speedtracer_panel/tracer.rb
Expand Up @@ -19,7 +19,8 @@ def request_finish(env, status, headers, body, timing)
def before_detect(method_call, arguments) def before_detect(method_call, arguments)
@event_id += 1 @event_id += 1


arguments_string = make_string_of(arguments) #arguments_string = make_string_of(arguments)
arguments_string = ""
#XXX ServerEvent use method call... #XXX ServerEvent use method call...
event = ServerEvent.new(method_call, arguments_string) event = ServerEvent.new(method_call, arguments_string)
@pstack.push event @pstack.push event
Expand Down

0 comments on commit 169d6b4

Please sign in to comment.