Renamed ConnectionError -> ProtocolError, simplified Retry logic, added tests.