Skip to content

Instantly share code, notes, and snippets.

@mperham
Created February 22, 2010 20:24
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mperham/311458 to your computer and use it in GitHub Desktop.
Save mperham/311458 to your computer and use it in GitHub Desktop.
EM.run do
Fiber.new do
# Do everything with Bunny in here
# it will use Fibers + EM
b = Bunny.new(...)
b...
end.resume
end
# Out here, it will use standard Socket-based, synchronous Bunny
b = Bunny.new(...)
b...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment