Skip to content
Provides JRuby Bindings to a Pure Java implementation of libzmq (ZeroMQ).
Ruby
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.idea
bin
guide
ivy
jars/compile
lib
spec
zguide
.gitignore
.travis.yml
Gemfile
Gemfile.lock
LICENSE
README.md
Rakefile
build.xml
ivy.xml
ivysettings.xml
jrzmq.gemspec
jrzmq.iml

README.md

jrzmq Build Status Code Climate Dependency Status

Provides JRuby Bindings to a Pure Java implementation of libzmq (ZeroMQ).

Installation

    jruby -S gem install jrzmq
    gem "jrzmq", "~> 1.0.3.2"

example

    require 'jrzmq'

    context = ZMQ::Context.new(1)

    puts "Opening connection for READ DOWNSTREAM"
    inbound = context.socket(ZMQ::UPSTREAM)
    inbound.bind("ipc://localconnection")
    inbound.set_receive_time_out 10

    puts "Opening connection for WRITE UPSTREAM"
    outbound = context.socket(ZMQ::DOWNSTREAM)
    outbound.connect("ipc://localconnection")
    outbound.set_send_time_out 10

    messages = %w{Hello  World! QUIT}
    
    messages.each do |msg|
      outbound.send(msg)
    end
      
    loop do
      received_msg = inbound.recv_str
      puts "Received #{received_msg}"
      break if received_msg == "QUIT"
    end

license

JRZMQ's code is MIT, but it relies upon JeroMQ which has the following:

COPYING

COPYING.LESSER

You can’t perform that action at this time.