thingsboard / thingsboard-gateway

Open-source IoT Gateway - integrates devices connected to legacy and third-party systems with ThingsBoard IoT Platform using Modbus, CAN bus, BACnet, BLE, OPC-UA, MQTT, ODBC and REST protocols

Home Page:https://thingsboard.io/docs/iot-gateway/what-is-iot-gateway/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[BUG] Abnormal rate limit with mqtt

yfPanne opened this issue · comments

Describe the bug
The gateway has abnormal rate limit when connect to thingsboard by mqtt.
It is an logic caused bug, and in fact, it is a problem with the python-client-sdk repository.

Error traceback (If available):
The sleep function indicated by the arrow in the diagram below will always be cross-triggered.
That means the mqtt-sending rate will always be limited to 10 per second since the function _publish_data always wait_for_publish.
image
image

Versions (please complete the following information):

  • OS: [e.g. Ubuntu 18.04]
  • Thingsboard IoT Gateway version [e.g. latest]
  • Python version[e.g. 3.11]

Hi @yfPanne,

This issue was solved in Python client SDK and it is available in the master branch of the SDK, you can try to use it or it will be also available in the nearest release of SDK.