RabbitMQ

RemnodeRabbitMQ configures a transport on the open source broker RabbitMQ.
Exchange, SendQueue and ReceiveQueue are configured in the remnode object. If the queues doesn't
exist they will be created on the server. If Exchange is left empty, the default exchange is used.

Username and password are specified to gain access to the RabbitMQ broker. The user has to
be define on the broker and given appropriate permissions. This can be done with rabbitmqctl on
the server node, eg

> rabbitmqctl add_user myuser mypasswd
> rabbitmqctl set_permissions -p / myuser .* .* .*

In the RemTrans object, Address[0] and Address[1] is used to address a sent message to the corresponding
RemTrans in the target node. Address[3] states the message delivery mode where 2 is persistent and other
values not persistent. Address[2] is an option bitmask where bit 1 is KeepAll and bit 2 MsgOrder.

KeepAll means that messages are requeued if the remtrans is occupied. By default they are discarded.
If there are several remtrans objects on the same queue, the order for requeued messages might be changed
unless the MsgOrder bit is set. MsgOrder will set the prefetch count to 1.

If a message should be recovered after a server failure, Durable should be set in the RemoteRabbitMQ
object, and delivery mode in RemTrans.Address[3] should be set to 2 (persistent).

If messages should be able to survive network failures, a suitable method is to send messages to a
local broker and receive messages from a broker on the sending node. In this case you need separate
RemnodeRabbitMQ objects for sending and receiving, and you also need to start the broker in both nodes.