More bug fixes for socket connection and allow retrieval of pending sessions too from backend.