Build Status Code Climate

zchannel

zchannel is a library that assists with InterProcess Communication, or IPC for short. It provides a high level and easy to use API for sending Ruby objects between processes that are running on the same machine and who have a parent-child relationship. A channel is implemented on top of an unbound UNIXSocket. Objects are serialized on write and deserialized on read using a serializer of your choice. The examples use the "Marshal" serializer, which is available without any extra dependencies.

Examples

1.

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

Requirements

Ruby 2.2 or later.

Install

  • Rubygems
$ gem install zchannel
  • Bundler
gem "zchannel", "~> 0.4"

License

MIT.