From 7b3332703006501bed85736313c2528aee048480 Mon Sep 17 00:00:00 2001 From: Mike McLean Date: Nov 22 2016 21:41:31 +0000 Subject: avoid tickling race condition with common keep alive timeout setting The default KeepAliveTimeout in Apache httpd 2.4 is 5 seconds. Sleeping for that same time and then resuming calls can tickle a race condition. The previous commit /should/ catch that now, but there's no sense hitting that error so often. See also: https://github.com/mikem23/keepalive-race --- diff --git a/cli/koji b/cli/koji index 5fc6d60..405c4f0 100755 --- a/cli/koji +++ b/cli/koji @@ -4360,7 +4360,7 @@ def anon_handle_list_history(options, session, args): if not options.watch: break else: - time.sleep(5) + time.sleep(options.poll_interval) # repeat query for later events if last_event: kwargs['afterEvent'] = last_event diff --git a/koji/__init__.py b/koji/__init__.py index d77353a..df0b686 100644 --- a/koji/__init__.py +++ b/koji/__init__.py @@ -1568,7 +1568,7 @@ def read_config(profile_name, user_config=None): 'timeout' : None, 'use_fast_upload': False, 'upload_blocksize': 1048576, - 'poll_interval': 5, + 'poll_interval': 6, 'krbservice': 'host', 'krb_rdns': True, 'cert': None,