Added connectionId back to logic