Connection dev 4 4

Same as gh-1838 

General permissions testing:
 * Start insight. Leave the application opened
 * Computer goes to sleep
 * Perform action when network is back up

* Unplug to stop connection, perform an action e.g. expand a dataset or select a new object.

--rebased-from #1838