mirror of
https://github.com/scylladb/scylladb.git
synced 2026-05-31 20:16:43 +00:00
scylla-housekeeping always wants to run in the installation to check if we are running the latest version. This happens regardless of whether or not we said yes or no to the housekeeping scylla_setup question - as that question only deals with whether or not we want to do this through a timer. It is fine to try to run scylla-housekeeping, as long as we time it out. The current code doesn't. The naive solution is to add a timeout parameter to urllib.request.open. However, that timeout is not respected and in my tests I saw real timeouts up to four times higher the timeout we set. For a reasonable 5s timeout, this mean a 20s real timeout which can lead to a very bad user experience. This seems to be a known problem with this module according to a quick Google search. This patch then takes a slightly more complex solution and uses multiprocess to enforce a well-defined user-visible timeout. Fixes #3980 Signed-off-by: Glauber Costa <glauber@scylladb.com> Message-Id: <20190506122335.5707-1-glauber@scylladb.com>