1.4.2 • Published 3 years ago

lap-protocol v1.4.2

Weekly downloads
-
License
MIT
Repository
-
Last release
3 years ago

Low bandwidth Application Protocol

Build status Coverage Status Current version

The Low bandwidth application protocol is designed to allow two applications to communicate via application level calls over potentially unreliable networks with as the smallest number and size of messages possible.

Usage

Client
1. Call createClient
2. Pass message to server
6. Forward message from the server to the instance of Protocol obtained in step 1

Server
3. Receive message from client
4. Call createServer
5. Pass message to client

Both client and server will now generate efficient opaque messages that need to be delivered to the other side.

Documentation

Reference documentation is available at https://dolencd.github.io/protocol/.

Usage notes

  • If the underlying protocol does not guarantee delivery, implement retransmission logic for the first message (step 2).

Architecture

When using the library, a developer should only ever interact with the main Protocol class, but under the hood the functionality is split into 2 standalone sub-classes, each with its own role.

Top

The top later protocol handles application payloads directly. It provides functions and abstractions that, when used, store the data in a local state. When triggered, the top layer will encode this data into an array of bytes (an opaque message) that underlying communication layers need to deliver to the other instance of the library.

It requires that all messages are delivered correctly and in order.

Bottom

The (optional) bottom layer is used when the underlying communications protocol does not meet the requirements of the top protocol. It provides guarantees in message delivery and ordering, handling processes like acknowledgements and message retransmission.

By default all protocol messages are bundled with application payloads, bringing maximum efficiency. There are options that speed up failure detection and message retransmission at the expense increased message size and number.

1.4.2

3 years ago

1.4.1

3 years ago

1.4.0

3 years ago

1.3.4

3 years ago

1.3.3

3 years ago

1.3.2

3 years ago

1.3.1

3 years ago

1.3.0

3 years ago

1.2.4

3 years ago

1.2.3

3 years ago

1.2.2

3 years ago

1.2.0

3 years ago

1.1.0

3 years ago

1.2.1

3 years ago

1.0.0

3 years ago

0.1.4

3 years ago

0.1.3

3 years ago

0.1.2

3 years ago

0.1.1

3 years ago

0.1.0

3 years ago