diff options
author | Eric Wong <normalperson@yhbt.net> | 2009-11-25 15:08:25 -0800 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2009-11-25 15:12:13 -0800 |
commit | 7f11b212f78a5070bea17bc20af43395b6cc621d (patch) | |
tree | dcef21ffe3a2bac7950293656fb8128a8e13c84c /t/sleep.ru | |
parent | 06de4af18d1ba3b28e49e9d8f700df4eca36e635 (diff) | |
download | rainbows-7f11b212f78a5070bea17bc20af43395b6cc621d.tar.gz |
It works exactly like Actor.sleep and similar to Kernel.sleep (no way to sleep indefinitely), but is compatible with the IO.select-based Fiber scheduler we run. This method only works within the context of a Rainbows! application dispatch.
Diffstat (limited to 't/sleep.ru')
-rw-r--r-- | t/sleep.ru | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -8,6 +8,8 @@ run lambda { |env| env["PATH_INFO"] =~ %r{/([\d\.]+)\z} and nr = $1.to_f (case env['rainbows.model'] + when :FiberPool, :FiberSpawn + Rainbows::Fiber when :Revactor Actor else |