Documentation and Configuration of mySQL Persistence Service

I’m a bit confused on how to configure the mySQL Persistance Service. There seems to be some misunderstandings regarding the documentation and the code itself?

In my analysis of my connection-ERRORs (Connection errors after MySQL server reboot), I came across this issue from a year ago:

It contradicts the documentation and is still open since a year now!

basically I’m concerned about these two configuration items:

# the reconnection counter

# the connection timeout (in seconds)
  • The documentation implies the “reconnectCnt” isnt’t a “Counter”, but a 0/1 switch? and the “waitTimeout” is a period of time, in which openHAB will reset the connection if no transactions are executed.
  • The issue #4084 implies, the “reconnectCnt” is indeed a counter for errors after which openHAB resets the Connection and “waitTimeout” is the session timeout.
  • Here in the forum there are a few examples of mysql persistance configurations and they also refer to “reconnectCnt = 1”.

so what is it then? :wink: