AMQP / MQTT connection

Pimmetje4 days ago

I would like to have realtime data from traccar to my AMQP/MQTT server.

I tried

<entry key='event.forward.enable'>true</entry>
<entry key='event.forward.type'>amqp</entry>
<entry key='event.forward.url'>amqp://traccar:password@host:5672/</entry>
<entry key='event.forward.exchange'>amq.topic</entry>
<entry key='event.forward.routingKey'>traccar/events</entry>
<entry key='event.forward.exchangeType'>topic</entry>

But i does not seem to connect. How can i debug this?

Turbovix4 days ago

I use the configuration like this:

<entry key='forward.enable'>true</entry>
<entry key='forward.type'>mqtt</entry>
<entry key='forward.url'>mqtt://user:password@XXXXXXXX:1883</entry>
<entry key='forward.retry.enable'>true</entry>
<entry key='forward.retry.delay'>50</entry>
<entry key='forward.topic'>satvix/positions</entry>

<entry key='event.forward.type'>mqtt</entry>
<entry key='event.forward.url'>mqtt://user:password@XXXXXX:1883</entry>
<entry key='event.forward.topic'>satvix/events</entry>
Pimmetje4 days ago

I copy & paste it only replacing username password and XXX for hostname. Restarted the docker. It does not seem to connect. No errors in the logs either.

Turbovix4 days ago

It's not copy and paste, I gave the example of my configuration. You need to check other points, is it a local connection?, does the MQTT service you use require authentication?, is there a port block on your network? and so on. You need to do these checks. The first of all is to try to log in and publish on your broker.

Pimmetje4 days ago

I hope i know how to check that and did that in the correct way. Is there any way to get a more verbose logging on this?