Do you have any other Items that publish to those topics?
It is not necessarily OH that is publishing to those topics. What topics do your devices publish to? It is common and reasonable to expect your device to publish to both of those topics in response to the command you sent.
Then the publishes are coming from the device, not openHAB. There is nothing openHAB can do about it. Look at your device, though the device publishes them for a reason.
just out of curiosity: did you have an mqtt-eventbus.cfg running bevor commenting the file?
if so, I suspect you had the above logic in the eventbus? (commandUpdates and stateUpdates?). If still yes, please have a look here:
just a minor tweak, but you should consider avoiding those special characters, as they tend to confuse humans - and algorithms. I personally think underscores are fine, but there are loads of different “-” out there, which could accidentially slip in and until you figure out, what’s going on, you spend a night with error logs!
just out of curiosity: did you have an mqtt-eventbus.cfg running bevor commenting the file?
if so, I suspect you had the above logic in the eventbus? (commandUpdates and stateUpdates?). If still yes, please have a look here:
Yes that was the case. I tried to follow the topic, deleting the cache, but still no success… I still have the duplicated messages
Just to be clear, please post your mqtt-eventbus.cfg.
What’s your platform, you’re running OH2 from?
if /var/lib/openhab2/cache and /var/lib/openhab2/tmp won’t work, you should have a look in
/var/lib/openhab2/config/org/openhab/mqtt-eventbus.config it should be empty then, if not, do as in the “Clear the Cache”-thread described and stop OH2, delete cache and tmp again but plus empty the mqtt-eventbus.config, then start OH2 again