haka-mqtt
The haka_mqtt package is reliable “weapons grade” MQTT client library. It contains a core mqtt reactor class built with provable reliability, and reproducibility as its fundamental goals. A side effect is that the library turns out to be speedy as well.
Status
The project’s core reactor is stable. It has been tested on systems with thousands of distributed nodes in difficult field conditions. The QoS=1 datapath is well field tested. The QoS=0 and QoS=2 are not as thoroughly field tested.
While the core reactor is very well tested the frontends are less tested. You should pay attention to notes on the different frontends regarding their status and use.
The haka library is mostly tested on Linux derivatives. It may work on other platforms but this has not been tested by the authors and no definite reports of success have been reported to the authors.
Installation
The haka-mqtt package can be installed from pypi.org with pip:
pip install haka-mqtt
Usage
A quick example of how the package can be used:
# Standard python Packages
import logging
# 3rd-Party Packages
from haka_mqtt.frontends.poll import (
MqttPollClientProperties,
BlockingMqttClient
)
from haka_mqtt.reactor import ACTIVE_STATES
from mqtt_codec.packet import MqttTopic
LOG_FMT='%(asctime)s %(name)s %(levelname)s %(message)s'
logging.basicConfig(format=LOG_FMT, level=logging.INFO)
properties = MqttPollClientProperties()
properties.host = 'test.mosquitto.org'
properties.port = 1883
properties.ssl = False
TOPIC = 'haka'
c = BlockingMqttClient(properties)
c.start()
sub_ticket = c.subscribe([MqttTopic(TOPIC, 1)])
c.on_suback = lambda c, suback: c.publish(TOPIC, 'payload', 1)
c.on_publish = lambda c, publish: c.stop()
while c.state in ACTIVE_STATES:
c.poll(5.)
Project Infrastructure
The project is coordinated through public infrastructure available at several places:
Metadata
Release files for haka-mqtt 0.3.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| haka-mqtt-0.3.5.tar.gz | 29.5 kB | Without provenance | Details for haka-mqtt-0.3.5.tar.gz |
Release files / haka-mqtt-0.3.5.tar.gz
| Download URL | haka-mqtt-0.3.5.tar.gz |
|---|---|
| Size | 29.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
10022a78b3eea83d21c078f463ccad13c29b9cfb7adc7302f3f9e76b5675d498
|
|
BLAKE2b-256 checksum How to use checksums |
f658f343dea6a9b85912b857af60164f78b940bb2b59a2de4c393f4a21e3700d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.6.2 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/2.7.15
|
Security for haka-mqtt 0.3.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.