Skip to content

MultiBuildingMessaging

Jereme Haack edited this page Sep 12, 2014 · 2 revisions

Multi-building messaging is implemented as a service-style agent. Its use is optional and can be enabled/disabled by simply enabling/disabling the multibuilding service agent. It is easily configured using the service launch file and provides several new topics for use in the local agent exchange bus.

Configuration

The agent launch file may contain the declarations below:

 building-publish-address::    A ØMQ address used to publish to the building's message bus. Defaults to 'tcp://0.0.0.0:9161'.

 building-subscribe-address::    A ØMQ address used to subscribe to the building's message bus. Defaults to 'tcp://0.0.0.0:9160'.

 cleanup-period::    Frequency, in seconds, to check for and close stale connections. Defaults to 600 seconds (10 minutes).

 hosts::    A mapping (dictionary) of building names to publish/subscribe addresses. Each entry is of the form:

     "CAMPUS/BUILDING": {"pub": "PUB_ADDRESS", "sub": "SUB_ADDRESS"}

   where PUB_ADDRESS and SUB_ADDRESS are ØMQ addresses.

 uuid::    A UUID to use in the Cookie header. If not given, one will be automatically generated.

Sending and Receiving Inter-building Messages

Three topics are provided for inter-building messaging:

building/recv/CAMPUS/BUILDING/TOPIC::   Agents can subscribe to to this topic to receive messages sent to TOPIC at the building specified by CAMPUS/BUILDING.

building/send/CAMPUS/BUILDING/TOPIC::   Agents can send messages to this topic to have them forwarded to TOPIC at the building specified by CAMPUS/BUILDING.

building/error/CAMPUS/BUILDING/TOPIC::   Errors encountered during sending/receiving to/from the above two topics will be sent over this topic.

Limitations and Future Work

Requires opening multiple listening ports::   It would be nice to multiplex all inter-building communications over a single port to decrease the attack footprint and ease firewall administration.

There is no authentication, authorization, or encryption::   Data is currently open to sniffing, modification, and all sorts of malicious activity.

Remote host lookup is kept in a static file::   Ideally, host lookup would be done through some central directory service, but that is not currently implemented.

Clone this wiki locally