I finally found why the MQTT binding was not working properly with random behaviour of boiler switch and temperature setpoint.
Apparently Openhab keeps a the MQTT configuration in the internal database despite you change the config file, this confuses the mqtt client and makes it disconnect constantly.
In this forum I found the solution: https://community.openhab.org/t/mqtt-config-under-oh2/15497/9
Connect to the Karaf Console (ssh openhab@localhost -p 8101 with password: habopen) to check if previous configs has been stored stored in the OH2 "internal database" by using:
You can start clean by configuring your mqtt.cfg and mqtt-eventbus.cfg and clearing out whatever is stored already by:
config:delete org.openhab.mqtt and then restart OH2 to reload the .cfg files