repo.or.cz
/
rainbows.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
event_machine: protect IO#close from EBADF
[rainbows.git]
/
t
/
heartbeat-timeout.ru
blob
d9904e8e22cf7d4f38b89e6824b90f69f72f3b8d
1
use Rack::ContentLength
2
headers = { 'Content-Type' => 'text/plain' }
3
run lambda { |env|
4
case env['PATH_INFO']
5
when "/block-forever"
6
Process.kill(:STOP, $$)
7
sleep # in case STOP signal is not received in time
8
[ 500, headers, [ "Should never get here\n" ] ]
9
else
10
[ 200, headers, [ "#$$\n" ] ]
11
end
12
}