celluloid/celluloid-zmq — pull request #18 by grantr (2013-01-10 22:32:05+00:00)
Title: Socket monitoring

This branch adds a SocketMonitor actor that monitors socket events using the zmq_socket_monitor feature in zeromq 3.2.

It only works with ffi-rzmq > 0.9.7, which is why the Gemfile depends on git master. When a new version of ffi-rzmq is released (0.9.8?) that can be removed.

```` ruby
require 'celluloid/zmq'
socket = Celluloid::ZMQ::PubSocket.new
Celluloid::ZMQ::SocketMonitor.new(socket, "socket.monitor")
socket.bind("tcp://127.0.0.1:58000")
# got listening socket event: event [8], addr [tcp://127.0.0.1:58004], fd [17], field2 [17]
````