gem1.9.1 install em-http-request
Building native extensions. This could take a while...
Successfully installed em-http-request-0.2.10
1 gem installed
Installing ri documentation for em-http-request-0.2.10...
Updating class cache with 2603 classes...
Installing RDoc documentation for em-http-request-0.2.10...
alias mul="rcscript //job:multicast http://rorbuilder.info/r/websocket.rsf"
mul drobertson secret
require 'em-http'
EventMachine.run {
http = EventMachine::HttpRequest.new("ws://localhost:8080/").get :timeout => 0
http.errback { puts "oops" }
http.callback {
puts "WebSocket connected!"
http.send("Hello client")
}
http.stream { |msg|
puts "Received: #{msg}"
#http.send "Pong: #{msg}"
}
}
WebSocket connected!
Recieved: 2 connected!
Recieved: <2>: Hello client
Recieved: jubs_pie: @ViniSaporta HMMMMMMMMMM ME JOGA NA CAMA E ME CHAMA DE RUBY MEU BEM n
Recieved: retrodin: Newbie Questions - Ruby, Pearl, Mits, Please have some patience with me as I am a newbie and don't understand much of the technical jargon
Recieved: agebackwards: Model ex at centre of Ruby break-up - http://www.newzfor.me/?4crd
alias mcl="rcscript //job:multicast_client http://rorbuilder.info/r/websocket.rsf"
Read more: http://feeds.dzone.com/~r/dzone/snippets/~3/aQkpvg9BVLc/11867