Bondy is an open source, always-on and scalable application networking platform connecting all elements of a distributed application—offering service and event mesh capabilities combined. Bondy implements the open Web Application Messaging Protocol (WAMP) and is written in Erlang.
Bondy is an open source, always-on and scalable application networking platform connecting all elements of a distributed application—offering service and event mesh capabilities combined.
From web and mobile apps to IoT devices and backend microservices, Bondy allows everything to talk using one simple and secured communication protocol in a decoupled and dynamic way.
Bondy implements the open Web Application Messaging Protocol (WAMP).
For our work-in-progress documentation for v1.0.0 go to https://developer.bondy.io.
In addition Bondy provides:
Bondy provides a unique combination of features which sets it apart from other application networking solutions and WAMP routers in terms of scalability, reliability, high-performance, development and operational simplicity.
The fastest way to get started is by using our official docker images.
cd
to that location and run the following command (If you already cloned the Bondy repository then just cd
to the location of the repo).docker run \
--rm \
-e [email protected] \
-e BONDY_ERL_DISTRIBUTED_COOKIE=bondy \
-u 0:1000 \
-p 18080:18080 \
-p 18081:18081 \
-p 18082:18082 \
-p 18083:18083 \
-p 18084:18084 \
-p 18085:18085 \
-v "$(PWD)/examples/custom_config/etc:/bondy/etc" \
-v "/tmp/data:/bondy/data" \
leapsight/bondy:master
Clone this repository and cd
to the location where you cloned it.
To generate a Bondy release to be used in production execute the following command which will generate a tarball containing the release at $(PWD)/_build/prod/rel/
.
make release
Untar and copy the resulting tarball to the location where you want to install Bondy e.g. ~/tmp/bondy
.
tar -zxvf _build/prod/rel/bondy-1.0.0-rc.17.tar.qz -C ~/tmp/bondy
To run Bondy, cd
to the location where you installed it e.g. ~/tmp/bondy
and run the following command which will print all the options.
bin/bondy
For example, to run Bondy with output to stdout do
bin/bondy foreground
And to run Bondy with an interactive Erlang shell do
bin/bondy console
We will start a node named [email protected]
which uses the following variables from the config file (config/test/node_1_vars.config
).
Transport | Description | Port |
---|---|---|
HTTP | REST API GATEWAY | 18080 |
HTTP | REST API GATEWAY | 18083 |
HTTP | REST Admin API | 18081 |
HTTPS | REST Admin API | 18084 |
Websockets | WAMP | 18080 |
TCP | WAMP Raw Socket | 18082 |
TLS | WAMP Raw Socket | 18085 |
make node1
WAMP is a session-based protocol. Each session belongs to a Realm.
curl -X "POST" "http://localhost:18081/realms/" \
-H 'Content-Type: application/json; charset=utf-8' \
-H 'Accept: application/json; charset=utf-8' \
-d $'{
"uri": "com.myrealm",
"description": "My First Realm"
}'
We will disable security to avoid setting up credentials at this moment.
curl -X "DELETE" "http://localhost:18081/realms/com.myrealm/security_enabled" \
-H 'Content-Type: application/json; charset=utf-8' \
-H 'Accept: application/json; charset=utf-8'
We start a second node named [email protected]
which uses the following variables from the config file (config/test/node_2_vars.config
).
Transport | Description | Port |
---|---|---|
HTTP | REST API GATEWAY | 18180 |
HTTP | REST API GATEWAY | 18183 |
HTTP | REST Admin API | 18181 |
HTTPS | REST Admin API | 18184 |
Websockets | WAMP | 18180 |
TCP | WAMP Raw Socket | 18182 |
TLS | WAMP Raw Socket | 18185 |
make node2
After a minute the two nodes will automatically connect.
From now on all new Bondy control plane state changes will be propagated in real-time through broadcasting.
One minute after joining the cluster, the Active Anti-entropy service will trigger an exchange after which the Realm we have created in [email protected]
will have been replicated to [email protected]
.
make node3
Copyright by Leapsight, material licensed under the CC-BY-SA 4.0, provided as-is without any warranties, Bondy documentation (https://developer.bondy.io).