Skip to content

Commit

Permalink
Improved debug print a little bit.
Browse files Browse the repository at this point in the history
  • Loading branch information
jirihnidek committed May 3, 2022
1 parent 0c04115 commit 3c72146
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/rhsm/connection.py
Original file line number Diff line number Diff line change
Expand Up @@ -1011,12 +1011,13 @@ def _request(self, request_type, method, info=None, headers=None, cert_key_pairs

keep_alive_http_header = response.getheader("Keep-Alive")
if keep_alive_http_header is not None:
log.debug("Trying to parse 'Keep-Alive' HTTp header")
keep_alive_timeout, max_request_num = self.parse_keep_alive_header(keep_alive_http_header)
if keep_alive_timeout is not None:
self.__conn.keep_alive_timeout = keep_alive_timeout
log.debug(f"Connection timeout: {keep_alive_timeout} is used from 'Keep-Alive' HTTP header")
if max_request_num is not None:
self.__conn.max_request_num = max_request_num
log.debug(f"Max number of requests: {max_request_num} is used from 'Keep-Alive' HTTP header")

# Look for server drift, and log a warning
if drift_check(response.getheader("date")):
Expand Down

0 comments on commit 3c72146

Please sign in to comment.