Skip to content

Commit eb6fd9b

Browse files
wbarnhadrewdogg
andauthored
Log connection errors at ERROR level (dpkp#139)
Co-authored-by: drewdogg <[email protected]>
1 parent 54cbd63 commit eb6fd9b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

kafka/conn.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -916,7 +916,7 @@ def close(self, error=None):
916916
with self._lock:
917917
if self.state is ConnectionStates.DISCONNECTED:
918918
return
919-
log.info('%s: Closing connection. %s', self, error or '')
919+
log.log(logging.ERROR if error else logging.INFO, '%s: Closing connection. %s', self, error or '')
920920
self._update_reconnect_backoff()
921921
self._sasl_auth_future = None
922922
self._protocol = KafkaProtocol(

0 commit comments

Comments
 (0)