UCP showing errors at random times and session gets logged out

I have custom installed freePBX in ubuntu 20.04 . The webrtc phone and widgets all work fine, but at random times the UCP shows this error

and gets logged out .

UPDATE on this:
I am facing the same issue like this post but no one seemed to have the solution : Problems with UCP

Any help would be appreciated

Given its a custom install, it might be hard to get help for this one, you can look at the web error logs in Linux to see if you are seeing something actionable.