examples/mq/hashtable.rb in amqp-0.6.0 vs examples/mq/hashtable.rb in amqp-0.6.4
- old
+ new
@@ -1,9 +1,9 @@
$:.unshift File.dirname(__FILE__) + '/../../lib'
require 'mq'
-EM.run{
+AMQP.start(:host => 'localhost') do
def log *args
p args
end
@@ -35,13 +35,13 @@
end
client.set(:one, 1)
client.keys do |res|
log 'client', :keys => res
- EM.stop_event_loop
+ AMQP.stop{ EM.stop }
end
-}
+end
__END__
["HashTable", :set, {:now=>Thu Jul 17 21:04:53 -0700 2008}]
["HashTable", :get, :now]
\ No newline at end of file