Handle connection failures the same way Zend does