Module mqtt.loop.copas

Copas specific client handling module.

Typically this module is not used directly, but through mqtt.loop when auto-detecting the environment.

Functions

add (cl) Add MQTT client to the Copas scheduler.


Functions

add (cl)
Add MQTT client to the Copas scheduler. Each received packet will be handled by a new thread, such that the thread listening on the socket can return immediately. The client will automatically be removed after it exits. It will set up a thread to call Client:check_keep_alive.

Parameters:

  • cl mqtt-client to add to the Copas scheduler

Returns:

    true on success or false and error message on failure
generated by LDoc 1.5.0 Last updated 2024-10-13 22:14:17