MCPcopy Index your code
hub / github.com/bytebeamio/rumqtt

github.com/bytebeamio/rumqtt @rumqttc-0.25.1

Chat with this repo
repository ↗ · DeepWiki ↗ · release rumqttc-0.25.1 ↗ · + Follow
1,477 symbols 4,441 edges 160 files 331 documented · 22%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

rumqtt Logo

build status Coverage Status Discord chat

What is rumqtt?

rumqtt is an opensource set of libraries written in rust-lang to implement the MQTT standard while striving to be simple, robust and performant.

Crate Description version
rumqttc A high level, easy to use mqtt client crates.io page
rumqttd A high performance, embeddable MQTT broker crates.io page

Contents

Installation and Usage

rumqttd

Run using docker

rumqttd can be used with docker by pulling the image from docker hub as follows:

docker pull bytebeamio/rumqttd

To run rumqttd docker image you can simply run:

docker run -p 1883:1883 -p 1884:1884 -it bytebeamio/rumqttd

Or you can run rumqttd with the custom config file by mounting the file and passing it as argument:

docker run -p 1883:1883 -p 1884:1884 -v /absolute/path/to/rumqttd.toml:/rumqttd.toml -it rumqttd -c /rumqttd.toml

Prebuilt binaries

For prebuilt binaries checkout our releases, download suitable binary for your system and move it to any directory in your PATH.

Install using cargo

cargo install --git https://github.com/bytebeamio/rumqtt rumqttd

download the demo config file

curl --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/bytebeamio/rumqtt/main/rumqttd/rumqttd.toml > rumqttd.toml

and run the broker using

rumqttd --config rumqttd.toml

Note: Make sure to you correct rumqttd.toml file for a specific version of rumqttd

Install using AUR

paru -S rumqttd-bin

replace paru with whatever AUR helper you are using.

Note: Configuration is found in /etc/rumqtt/config.toml and systemd service name rumqtt.service

Compile from source

Clone the repo using git clone.

git clone --depth=1 https://github.com/bytebeamio/rumqtt/

Change directory to that folder and run

cd rumqtt
cargo run --release --bin rumqttd -- -c rumqttd/rumqttd.toml -vvv

for more information look at rumqttd's README

rumqttc

Add rumqttc to your project using

cargo add rumqttc

for more information look at rumqttc's README

Features

rumqttd

  • [x] MQTT 3.1.1
  • [x] QoS 0 and 1
  • [x] Connection via TLS
  • [x] Retransmission after reconnect
  • [x] Last will
  • [x] Retained messages
  • [x] QoS 2
  • [ ] MQTT 5

rumqttc

  • [x] MQTT 3.1.1
  • [x] MQTT 5

Community

Contributing

Please follow the code of conduct while opening issues to report bugs or before you contribute fixes, also do read our contributor guide to get a better idea of what we'd appreciate and what we won't.

License

This project is released under The Apache License, Version 2.0 (LICENSE or http://www.apache.org/licenses/LICENSE-2.0)

Extension points exported contracts — how you extend this code

Storage (Interface)
(no doc) [4 implementers]
rumqttd/src/segments/mod.rs
AsyncReadWrite (Interface)
(no doc) [1 implementers]
rumqttc/src/framed.rs
N (Interface)
(no doc) [1 implementers]
rumqttc/tests/broker.rs
Protocol (Interface)
(no doc) [2 implementers]
rumqttd/src/protocol/mod.rs
N (Interface)
(no doc) [1 implementers]
rumqttd/src/link/network.rs

Core symbols most depended-on inside this repo

new
called by 570
rumqttd/src/protocol/v5/connect.rs
len
called by 168
rumqttd/src/protocol/mod.rs
iter
called by 118
rumqttc/src/client.rs
push
called by 94
rumqttd/src/segments/segment.rs
iter
called by 73
rumqttc/src/v5/client.rs
read
called by 67
rumqttd/src/protocol/v5/suback.rs
is_empty
called by 63
rumqttd/src/protocol/mod.rs
read_mqtt_string
called by 54
rumqttc/src/v5/mqttbytes/v5/mod.rs

Shape

Method 665
Function 485
Class 204
Enum 115
Interface 5
Struct 3

Languages

Rust99%
Go1%
TypeScript1%

Modules by API surface

rumqttc/src/v5/mod.rs63 symbols
rumqttc/src/lib.rs62 symbols
rumqttd/src/protocol/mod.rs55 symbols
rumqttc/src/v5/client.rs53 symbols
rumqttc/src/v5/state.rs48 symbols
rumqttc/src/state.rs45 symbols
benchmarks/simplerouter/src/protocol/v5.rs42 symbols
rumqttc/src/client.rs35 symbols
rumqttd/src/link/local.rs32 symbols
rumqttd/src/router/logs.rs31 symbols
rumqttd/src/router/mod.rs30 symbols
benchmarks/simplerouter/src/protocol/v4.rs30 symbols

For agents

$ claude mcp add rumqtt \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact