0.3.0 • Published 5 years ago

@tum-far/ubii-msg-transport v0.3.0

Weekly downloads
-
License
-
Repository
gitlab
Last release
5 years ago

ubii-msg-transport

This is the repository for Ubii message transport. It contains everything about how ubii nodes and devices communicate with each other. If you are interested in what they say to each other, visit the ubii-msg-format repository.

Table of Contents

  1. Communication Endpoints
  2. Command Line Interfaces (CLIs)
  3. Testing

Communication Endpoints

We distinguish between one-way communcation patterns (only the client can open a message exchange) and two-way communication patterns (both sides, the clients and the server can send messages to the other side).

Communication patterns have multiple communication endpoints. There are client and server communication endpoints. Implementations must provide methods for binding and message sending. In addition, two-way communciation implementations must implement ping-pong functionality to provide checks of the connection status across different implementations.

Currently, the dealer-router pattern is relevant for two-way communication and the request-reply pattern is relevant for one-way communication.

ZeroMQ (ZMQ)

We provide communication endpoint implementations using the ZeroMQ library.

Endpoints can send Buffer objects or strings (strings are transformed into buffers).

Dealer-Router Pattern

The dealer router pattern is implemented as ZMQ connection endpoint. It consists of any number of 'zmqDealer' endpoint objects and a 'zmqRouter' endpoint object. It is a two-way communication pattern, so communication is possible in both directions.

With this pattern, received messages always have an envelope that contains the ID of the sender in addition to the plain payload. This should be taken into account in further implementations or processing of received messages.

Dealers communicate with the router by specifying the host and port. After a dealer has communicated with the router, routers can communicate with dealers by specifing the id of the dealer.

Request-Reply Pattern

The request-reply pattern is implemented.

CLIs

Tests

  • Run npm test to process all standard tests (no round trip time tests).
  • Run npm run-script test-rtt to process all round trip time tests.
  • See the Testing section for more details on tests.

Testing

This module uses the AVA test runner. You can add new tests to the test folder. Entry point for the test runner is test.js within the test folder. See the AVA Documentation for more details on how to create new test cases for AVA.

0.3.0

5 years ago

0.2.0

5 years ago

0.1.0

5 years ago

0.0.31

6 years ago

0.0.30

6 years ago

0.0.29

6 years ago

0.0.28

6 years ago

0.0.27

6 years ago

0.0.26

6 years ago

0.0.25

6 years ago

0.0.24

6 years ago

0.0.23

6 years ago

0.0.22

6 years ago

0.0.21

6 years ago

0.0.20

6 years ago

0.0.19

6 years ago

0.0.18

6 years ago

0.0.17

6 years ago

0.0.16

6 years ago

0.0.15

6 years ago

0.0.14

6 years ago

0.0.13

6 years ago

0.0.12

6 years ago

0.0.11

6 years ago

0.0.1

6 years ago