OH receives not any mqtt message

Hi,

i get every 2 minutes 15 mqtt messages from a mosqitto server. Even i can see every of the 15 massages in the log of the mosqitto server. That seems to work

But, the mqtt-binding receives each time just 6 or 7 messages. But not each time the same 6/7 messages, the mqtt-binding receives each time by random 6 or 7 out of 15 messages.

Here are my events.log

2018-01-21 23:38:28.359 [vent.ItemStateChangedEvent] - Temperatur_Heizung_OG_Vorlauf_1wire changed from 51.31 to 51.06
2018-01-21 23:38:29.097 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Kalt_1wire changed from 20.75 to 18.00
2018-01-21 23:38:29.110 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Warm_1wire changed from 32.31 to 32.19
2018-01-21 23:38:29.852 [vent.ItemStateChangedEvent] - Temperatur_OG_Bad_Fussboden_1wire changed from 26.19 to 26.00
2018-01-21 23:38:30.584 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Dusche_Oben_1wire changed from 23.94 to 23.88
2018-01-21 23:38:30.603 [vent.ItemStateChangedEvent] - Temperatur_T14_1wire changed from 28.81 to 28.75
...
2018-01-21 23:40:29.412 [vent.ItemStateChangedEvent] - Temperatur_Heizung_OG_Vorlauf_1wire changed from 51.06 to 50.88
2018-01-21 23:40:30.155 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Kalt_1wire changed from 18.00 to 16.31
2018-01-21 23:40:30.167 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Warm_1wire changed from 32.19 to 32.00
2018-01-21 23:40:30.654 [vent.ItemStateChangedEvent] - Temperatur_T8_1wire changed from 43.50 to 43.00
2018-01-21 23:40:30.902 [vent.ItemStateChangedEvent] - Temperatur_EG_Kueche_Fussboden_1wire changed from 24.44 to 24.38
2018-01-21 23:40:30.914 [vent.ItemStateChangedEvent] - Temperatur_OG_Bad_Fussboden_1wire changed from 26.00 to 25.88
...
2018-01-21 23:42:30.470 [vent.ItemStateChangedEvent] - Temperatur_Heizung_OG_Vorlauf_1wire changed from 50.88 to 50.63
2018-01-21 23:42:31.215 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Kalt_1wire changed from 16.31 to 15.88
2018-01-21 23:42:31.233 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Warm_1wire changed from 32.00 to 31.81
2018-01-21 23:42:31.974 [vent.ItemStateChangedEvent] - Temperatur_OG_Bad_Fussboden_1wire changed from 25.88 to 25.75
2018-01-21 23:42:32.700 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Dusche_Oben_1wire changed from 23.88 to 23.81
2018-01-21 23:42:32.714 [vent.ItemStateChangedEvent] - Temperatur_T14_1wire changed from 28.75 to 28.69
...
2018-01-22 00:10:17.943 [vent.ItemStateChangedEvent] - Temperatur_Wohnzimmer_KNX changed from 22.34 to 22.3
2018-01-22 00:10:45.277 [vent.ItemStateChangedEvent] - Temperatur_Heizung_OG_Vorlauf_1wire changed from 48.13 to 47.94
2018-01-22 00:10:46.017 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Kalt_1wire changed from 17.88 to 18.00
2018-01-22 00:10:46.029 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Warm_1wire changed from 29.63 to 29.50
2018-01-22 00:10:46.514 [vent.ItemStateChangedEvent] - Temperatur_T8_1wire changed from 41.50 to 41.00
2018-01-22 00:10:46.772 [vent.ItemStateChangedEvent] - Temperatur_OG_Bad_Fussboden_1wire changed from 24.50 to 24.44
2018-01-22 00:10:47.508 [vent.ItemStateChangedEvent] - Temperatur_Wasser_Dusche_Oben_1wire changed from 23.25 to 23.19

as you can see, the item Temperatur_OG_Bad_Fussboden_1wire is received in each block, but the item Temperatur_T14_1wire just 2 times in the 4 blocks.

is there a limit of received messages or …?

Is it because it’s only set to on change and the value hasn’t been changing every message? What happens if you change to on Update instead of on Change? (sorry I don’t know the exact terminlogy or where to find it, but this sticks out as a potential reason for me)

eg. if the figures were
28.81
28.81
28.81
28.75
28.75
28.75
28.69
28.69
that’s only two changes, so it only reports twice

I understand what you mean, but it receives each time just 6 values, since days (every 2 minutes).

It would be unbelievable, that in thousands of update-blocks each time exactly 6 values have changed

or is there a config-value in openhab where i can switch between update and change???
Because in mosqitto i can see all 15 messages each time (and i can receive them with another client, so I’m sure the 15 values are really received and send by mosqitto-server)

Almost. Not a config value, but different rule triggers:

https://docs.openhab.org/configuration/rules-dsl.html

The section you need to look for:
https://docs.openhab.org/configuration/rules-dsl.html

Item <item> received update
Item <item> changed

but my problem is the updating of items through incoming mtqq messages.

I have 15 incoming mqtt messages and just 6 or 7 of them updating an item. But not always the same 6/7 messages trigger an update. Each time another 6 out of 15 trigger the update.

Then check your qos settings in your mqtt config:

Hi,

i have further investigated and found the following warning in the Karaf-consol:

23:58:18.665 [WARN ] [core.internal.events.OSGiEventManager] - Dispatching event to subscriber 'org.eclipse.smarthome.io.monitor.internal.EventLogger@206ce622' takes more than 5000ms.

there are a number of this messages and it is always at the same time, when the mqtt messages came in.

What does that mean. Or what can i do?
Would it help to get the messages with a bigger delay between each message??

@sihui
i do not think that the qos settings are the problem, because i’am quite sure that the messages arrive in OH. Because with another mqtt-client i can receive all the messages without any problem.