Added disconnection support to server