Build Status Code Climate


zchannel is a library that can be used for sending and receiving objects between Ruby processes who share a parent-child relationship. The interface is simple and easy to use.



Marshal is the module we'll use for serialization.

ch = ZChannel.unix Marshal
Process.wait fork { ch.send "Hello, world!" }
ch.recv # => "Hello, world!"


In the 2nd example we choose JSON for serialization. Any serializer that implements the dump and load methods will do.

ch = ZChannel.unix JSON
Process.wait fork { ch.send [1,2,3] }
ch.recv # => [1,2,3]


Using Bundler

  gem "zchannel", github: "r-obert/zchannel.rb", tag: "v0.4.0"

Using Git & Rubygems

git clone
cd zchannel.rb
gem build zchannel.gemspec
gem install zchannel*.gem

Useful Links