Crates.io | cord-broker |
lib.rs | cord-broker |
version | 0.3.1 |
source | src |
created_at | 2020-04-01 23:13:32.876183 |
updated_at | 2022-10-18 01:12:30.771064 |
description | The server-side routing platform for the Cord Platform that exchanges messages between publishers and subscribers. |
homepage | https://cord-proj.org |
repository | https://github.com/cord-proj/cord-broker |
max_upload_size | |
id | 225350 |
size | 52,569 |
Cord is a data streaming platform for composing, aggregating and distributing arbitrary streams. The Broker crate provides stream aggregation and distribution functionality for the platform. It is the central component that all clients communicate with to exchange messages.
First, start a new Cord Broker:
Docker
$ docker run -d -p 7101:7101 --rm cordproj/cord-broker:0
Cargo
$ cargo install cord-broker
$ cord-broker &
Next, use the Cord Client to interact with the Broker. The easiest way to get started is by using the Client CLI.
Subscribe to a namespace:
Docker
$ docker run --rm cordproj/cord-client:0 -a <broker_addr> sub /names
Cargo
$ cargo install cord-client
$ cord-client sub /namespaces
Publish to this namespace:
Docker
$ docker run -it --rm cordproj/cord-client:0 -a <broker_addr> pub /names
Start typing to create an event, then press enter to send it to the broker.
Use the format: NAMESPACE=VALUE
/names/first=Daz
Cargo
$ cord-client pub /names
Start typing to create an event, then press enter to send it to the broker.
Use the format: NAMESPACE=VALUE
/names/first=Daz