Implemented WS connect and disconnect logic based on activity lifecycle