Class Cabin::Outputs::ZeroMQ
In: lib/cabin/outputs/zeromq.rb
lib/cabin/outputs/zeromq.rb
Parent: Object

Output to a zeromq socket.

Methods

<<   <<   hwm   hwm   linger   linger   new   new   teardown   teardown  

Constants

DEFAULTS = { :topology => "pushpull", :hwm => 0, # zeromq default: no limit :linger => -1, # zeromq default: wait until all messages are sent. :topic => ""
CONTEXT = ZMQ::Context.new
DEFAULTS = { :topology => "pushpull", :hwm => 0, # zeromq default: no limit :linger => -1, # zeromq default: wait until all messages are sent. :topic => ""
CONTEXT = ZMQ::Context.new

Attributes

socket  [R] 
socket  [R] 
topic  [R] 
topic  [R] 
topology  [R] 
topology  [R] 

Public Class methods

Create a new ZeroMQ output.

arguments: addresses A list of addresses to connect to. These are round-robined by zeromq.

:topology Either ‘pushpull’ or ‘pubsub’. Specifies which zeromq socket type to use. Default pushpull. :hwm Specifies the High Water Mark for the socket. Default 0, which means there is none. :linger Specifies the linger time in milliseconds for the socket. Default -1, meaning wait forever for the socket to close. :topic Specifies the topic for a pubsub topology. This can be a string or a proc with the event as the only argument.

Create a new ZeroMQ output.

arguments: addresses A list of addresses to connect to. These are round-robined by zeromq.

:topology Either ‘pushpull’ or ‘pubsub’. Specifies which zeromq socket type to use. Default pushpull. :hwm Specifies the High Water Mark for the socket. Default 0, which means there is none. :linger Specifies the linger time in milliseconds for the socket. Default -1, meaning wait forever for the socket to close. :topic Specifies the topic for a pubsub topology. This can be a string or a proc with the event as the only argument.

Public Instance methods

[Validate]