This repository is private.
All pages are served over SSL and all pushing and pulling is done over SSH.
No one may fork, clone, or view it unless they are added as a member.
Every repository with this icon (
) is private.
Every repository with this icon (
This repository is public.
Anyone may fork, clone, or view it.
Every repository with this icon (
) is public.
Every repository with this icon (
juggler /
| name | age | message | |
|---|---|---|---|
| |
.gitignore | Tue Oct 20 04:48:13 -0700 2009 | |
| |
LICENSE | Sun Oct 18 16:36:18 -0700 2009 | |
| |
README.md | Sun Oct 18 15:33:33 -0700 2009 | |
| |
Rakefile | Tue Oct 20 04:48:13 -0700 2009 | |
| |
VERSION | Wed Oct 21 12:38:11 -0700 2009 | |
| |
examples/ | Sun Oct 18 16:19:37 -0700 2009 | |
| |
lib/ | Wed Oct 21 12:36:58 -0700 2009 | |
| |
spec/ | Sun Oct 18 15:33:33 -0700 2009 |
README.md
Add jobs for asynchronous processing
Juggler.throw(:method, params)
Add handlers, with optional concurrency, inside and EM loop
EM.run {
Juggler.juggle(:method, 10) do |params|
# This code must return an eventmachine deferrable object
end
}
For example
Juggler.juggle(:download, 10) do |params|
http = EM::Protocols::HttpClient.request({
:host => params[:host],
:port => 80,
:request => params[:path]
})
http.callback do |response|
puts "Got response status #{response[:status]} for #{a}"
end
http
end







