Class: Rack::PerftoolsProfiler::StopProfiling

Inherits:
Action
  • Object
show all
Defined in:
lib/rack/perftools_profiler/stop_profiling.rb

Instance Method Summary collapse

Methods inherited from Action

for_env, #initialize

Constructor Details

This class inherits a constructor from Rack::PerftoolsProfiler::Action

Instance Method Details

#actObject



5
6
7
# File 'lib/rack/perftools_profiler/stop_profiling.rb', line 5

def act
  @profiler.stop
end

#responseObject



9
10
11
12
13
14
15
16
# File 'lib/rack/perftools_profiler/stop_profiling.rb', line 9

def response
  [200, {'Content-Type' => 'text/plain'}, 
   [<<-EOS
Profiling is now disabled.
Visit /__data__ to view the results.
EOS
   ]]
end