Connect/Disconnect improvement

Connect/Disconnect improvement