MQTT mosquitto broker connectivity

Hi

I am running Mosquitto MQTT and Losant Edge Agent in a Docker. I cannot connect with the Mosquitto broker and receive data in the Losant Edge Agent workflow. I tried accessing it with MQTT Trigger and it disconnects other clients that are subscribed with Mosquitto Broker.

Do you have any errors in the GEA container’s logs? You can access them by running docker logs THE_CONTAINER_NAME - unless you are using the logger.out option to write them to a file on disk instead.

There is also this related forum post; is this relevant to your setup and the problem you are seeing?

Yes I can see the image, but what about the container logs per my original reply?

Also, this line …

I tried accessing it with MQTT Trigger and it disconnects other clients that are subscribed with Mosquitto Broker.

… leads me to believe that you may be connecting multiple clients to the Mosquitto broker all using the same Client ID, which would lead to the behavior you are seeing.

Hi Finally I can able to connect to mosquitto broker with following settings

[[triggers]]
name = ‘losantdockermosquitto’
type = ‘mqttClient’
protocol = ‘mqtt’
host = ‘172.17.0.2’
port = 1883
username = ‘xxxx’
password = ‘xxxx’
clientId = ‘xyxyxy’
subscriptions = [‘my/first/topic/#’, ‘my/second/topic/#’,‘#’]

Now that mosquitto and losant both are connected. How can I get the published records at Edge work flow ?

After connection with mqtt and in edge worksflow i developed mqtt trigger with following configuration

Once I deploy the flow to edge workflow, I get below error on losant edge agent and it is disconnecting its connection from mosquitto mqtt (If External Broker not configured in edge workflow there is no dissconnection to mosquitto )

Those logs indicate that freedomiotedgeipclosantedgeagent does not exist as a named configuration in your GEA’s TOML file. That name does not match previous examples you’ve posted; could the problem be that you have a typo in the MQTT Trigger config or the name of the config in the TOML file?

I have cross checked the configuration names between workflow and toml file and bother are same still the error persists.

2023-10-19T16:05:42.049Z [info] Agent Starting…
2023-10-19T16:05:42.053Z [info] Agent Version: 1.43.0
2023-10-19T16:05:42.177Z [info] Webserver started on port: 8080
2023-10-19T16:05:42.183Z [info] Workflows initialized and running…
2023-10-19T16:05:42.183Z [info] Connecting to: mqtts://broker.losant.com …
2023-10-19T16:05:42.234Z [info] Local broker listening on 172.17.0.5:1883
2023-10-19T16:05:42.239Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:05:42.525Z [info] Connected to: mqtts://broker.losant.com
2023-10-19T16:05:42.675Z [info] Peripheral device updates received from Losant and applied.
2023-10-19T16:05:42.739Z [info] Workflows received from Losant and applied.

2023-10-19T16:05:42.049Z [info] Agent Starting…
2023-10-19T16:05:42.053Z [info] Agent Version: 1.43.0
2023-10-19T16:05:42.177Z [info] Webserver started on port: 8080
2023-10-19T16:05:42.183Z [info] Workflows initialized and running…
2023-10-19T16:05:42.183Z [info] Connecting to: mqtts://broker.losant.com …
2023-10-19T16:05:42.234Z [info] Local broker listening on 172.17.0.5:1883
2023-10-19T16:05:42.239Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:05:42.525Z [info] Connected to: mqtts://broker.losant.com
2023-10-19T16:05:42.675Z [info] Peripheral device updates received from Losant and applied.
2023-10-19T16:05:42.739Z [info] Workflows received from Losant and applied.
2023-10-19T16:06:57.688Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:06:57.689Z [info] Workflows received from Losant and applied.
2023-10-19T16:06:58.691Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:06:58.694Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:06:58.695Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:06:59.696Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:06:59.698Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:06:59.699Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:00.700Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:00.703Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:00.703Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:01.705Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:01.708Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:01.709Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:02.710Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:02.713Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:02.714Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:03.711Z [info] Debugging status changes received from Losant and applied.
2023-10-19T16:07:03.714Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:03.716Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:03.717Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:04.718Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:04.720Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:04.722Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:05.723Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:05.726Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:05.727Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:06.729Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:06.732Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:06.733Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:07.735Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:07.738Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:07.739Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:08.742Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:08.750Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:08.752Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:09.755Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:09.757Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:09.759Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:10.760Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:10.763Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:10.764Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:11.764Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:11.767Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:11.768Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:12.770Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:12.773Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:12.774Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:13.776Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:13.778Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:13.779Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:14.780Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:14.783Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:14.783Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:15.785Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:15.787Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:15.788Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:16.790Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:16.797Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:16.800Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:17.803Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:17.804Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:17.805Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:18.807Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:18.808Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:18.809Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:19.811Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:19.812Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:19.813Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:20.815Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:20.816Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:20.817Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:21.817Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:21.819Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:21.820Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:22.823Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:22.831Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:22.834Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:23.836Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:23.839Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:23.840Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:24.841Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:24.843Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:24.845Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:25.846Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:25.847Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:25.849Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:26.850Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:26.852Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:26.853Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:27.855Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:27.856Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:27.857Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:28.859Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:28.861Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:28.862Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:29.863Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:29.865Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:29.866Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:30.867Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:30.868Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:30.869Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:31.593Z [info] Workflows received from Losant and applied.
2023-10-19T16:07:31.869Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:31.871Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:07:31.872Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:07:32.874Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:07:32.881Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:10.853Z [info] Workflows received from Losant and applied.
2023-10-19T16:14:15.733Z [info] Debugging status changes received from Losant and applied.
2023-10-19T16:14:10.851Z [error] MQTT Client trigger config, freedomiotedgeipclosantedgeagent, was not found.
2023-10-19T16:14:42.209Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:42.211Z [info] Workflows received from Losant and applied.
2023-10-19T16:14:43.210Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:43.212Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:43.212Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:44.214Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:44.215Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:44.216Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:45.218Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:45.225Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:45.227Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:46.230Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:46.233Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:46.233Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:47.235Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:47.236Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:47.238Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:48.238Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:48.240Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:48.241Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:49.242Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:49.244Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:49.245Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:50.245Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:50.249Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:50.252Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:51.255Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:51.259Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:51.261Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:52.263Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:52.264Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:52.265Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:52.324Z [info] Workflows received from Losant and applied.
2023-10-19T16:14:53.266Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:53.268Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883
2023-10-19T16:14:53.269Z [warn] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) disconnected from mqtt://172.17.0.2:1883
2023-10-19T16:14:54.271Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) attempting to reconnect to mqtt://172.17.0.2:1883 …
2023-10-19T16:14:54.273Z [info] MQTT Client (freedomiotedgeipclosantedgeagent_mqttrigger) connected to mqtt://172.17.0.2:1883

Thanks, I’m going to try and reproduce this on our end. I will follow up when I have more information.

For anybody else who may encounter a similar issue, we discovered the problem was two-fold …

  1. The trigger configuration had a subscription to the topic "" (empty string), which is invalid. So Mosquitto was kicking the GEA’s client off its broker, and the GEA would immediately reconnect to be booted again, leading to the rapid connection fluttering. This only appeared once a workflow with an MQTT Trigger utilizing the client connection was deployed to the device because Losant will establish the client connection to the broker on GEA startup, but will not subscribe to any topics until an MQTT Trigger utilizing the connection is on the GEA.
  2. With that resolved, the agent still was not receiving messages published by the Mosquitto broker, and we discovered that it was a discrepancy between the username that the GEA was using to authenticate and the username in Mosquitto’s ACL file - meaning that the client did not have permission to subscribe to the topics we were expecting.

There are two potential improvements here that Losant will pursue to prevent this confusion from happening again …

  1. "" is an invalid topic subscription, and we should be able to throw an error in the GEA’s logs to alert users to that.
  2. If a subscription fails to open, that could be a warning in the GEA logs as well.