Skip to content

Instantly share code, notes, and snippets.

@jamesrwhite
Created February 7, 2014 14:28
Show Gist options
  • Save jamesrwhite/8863547 to your computer and use it in GitHub Desktop.
Save jamesrwhite/8863547 to your computer and use it in GitHub Desktop.
Faye client issues
require 'faye'
require 'eventmachine'
EM.run do
client = Faye::Client.new('http://localhost:9292/faye', { timeout: 10 })
pub = client.publish('/test', 'yo')
pub.callback do
puts "message recieved"
end
pub.errback do |error|
puts error.message
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment