I have openhab in a docker container, and upgraded it from 3.4.0 to 3.4.4.
When upgrading from 3.4.4 to 3.4.5 mariadb persistence was lost, so I ended up dumping the database and renaming it from items to Items and item0001 to Item1 and so on… (search and replace long sql file).
Now it works correct on 3.4.5 but when upgrading to 4.0.2 old data is lost (graphs are empty in basic UI).
I thing I have something messed up from my mysql binding when upgrading to jdbc, but I cannot see what it is.
It’s JDBC, but after upgrading it is not listed in settings. I believe the problem comes from my previous mysql persistence usage, and by some cause it fails to work.
After testing again, I had to install manually again JBDC after upgrade, just to get a “flat line”. I selected a bigger date range and discovered that at some point I restored and old backup and last 3 days are “lost somewhere”, so everything was working ok
All I can recommend is checking your persistence config. Watch the logs for errors. Consider putting the jdbc add-on into debug or trace level logging.