Hivemq tdengine extension user’s Guide

Time:2021-7-12

Let’s briefly introduce the deployment and usage of hivemq extension for tdengine.

Tdengine and hivemq deployment methods

TDengine

Just install the latest tdengine server. See official document:  https://www.taosdata.com/cn/getting-started/

HiveMQ

Install enterprise version (need to apply for trial license) or community version (hivemq Community Edition),https://github.com/hivemq/hivemq-community-edition)All right. See official document:  https://www.hivemq.com/docs/hivemq/4.4/user-guide/install-hivemq.html

Compilation and deployment of hivemq tdengine plug-in

  1. git clone https://github.com/taosdata/TDengine
  2. cd TDengine && git submodule update --init --recursive
  3. cd src/connector/hivemq-tdengine-extension && mvn clean && mvn package
  4. Unzip the packaged package, such as hivemq tdengine extension – {version} – distribution. Zip, to the extensions folder of hivemq directory. If hivemq is already running, you need to stop the hivemq background service first, otherwise hivemq will prohibit the plug-in from running, and you need to manually delete the disabled file to make the plug-in work.
  5. Modify the tdengine.xml configuration file in the plug-in package to the actual database information.
  6. There is no need to create the database and table manually. When the plug-in starts, it will create the database and table automatically

demonstration

Running hivmq

<HiveMQ>/bin/run.sh

send out Mqtt message

Use the popular mqtt software mosquito to send mqtt messages for test demonstration

mosquitto_pub -t test -m “hello world”

verificationLog in to tdengine through Taos client to check whether the verification record is written

Hivemq tdengine extension user's Guide