Occasional HABpanel disconnect from the openHAB server

My HABpanel display occasionally disconnects from the openHAB server, and I can’t figure out why.

As a workaround I implemented a nightly reboot of the Pi. But if someone knows a better way to solve that problem, please post in the comments.