Skip to content

Instantly share code, notes, and snippets.

😄
loged on

Dan Nolan dannolan

😄
loged on
Block or report user

Report or block dannolan

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@mloughran
mloughran / pubsub_example.rb
Created Sep 14, 2011
em-hiredis pubsub example
View pubsub_example.rb
require 'em-hiredis'
EM.run {
require 'em-hiredis'
redis = EM::Hiredis.connect
# If you pass a block to subscribe it will be called whenever a message
# is received on this channel
redis.pubsub.subscribe('foo') { |msg|
p [:received_foo, msg]
You can’t perform that action at this time.