`$session = $registry->getConnection();` might be better - if nothing else just to show people that its possible.