Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.92) (envelope-from ) id 1jAgRz-0001rI-GS for pgsql-hackers@arkaria.postgresql.org; Sat, 07 Mar 2020 20:53:35 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1jAgRx-00025r-6A for pgsql-hackers@arkaria.postgresql.org; Sat, 07 Mar 2020 20:53:33 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1jAgRw-00025k-RN for pgsql-hackers@lists.postgresql.org; Sat, 07 Mar 2020 20:53:32 +0000 Received: from mail-wr1-x434.google.com ([2a00:1450:4864:20::434]) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1jAgRt-0001EK-Pl for pgsql-hackers@postgresql.org; Sat, 07 Mar 2020 20:53:32 +0000 Received: by mail-wr1-x434.google.com with SMTP id n15so6350674wrw.13 for ; Sat, 07 Mar 2020 12:53:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=jybIdL+9G/cGD+oArrEWFVi0azFC3CMF6q4MEIdjUdQ=; b=pxNUFsFcPWhKchuN1JyodCozQVtKT5xXN32WiAWOFmaOjZX1hId9TZ7+wzcsH7D+/L mXuwQy0b+ZmIOPxtdpqacKPnlGshgE0qqPCNQ0hErXj0K//lg1f3iS8XoE8dZ0EUJMqq s+gt82sxMC0cP3BMcgnXk/J69/NaDEKg7im+CYiZ+BidC2tArAbeWyJps3PW8jNs9kXz +qNKfVP9SgwZGgY/o3AftyUj2zRVchiVPqDBi7pJchzrHjiSPJey/pzybQofWzjTS4WO 8eo0ckI97uXUfF8KSLNNRebaq6jcf2KSFblLHrjb92/FCUEF4m/lvp+zxDyimIuAIntW VdCQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=jybIdL+9G/cGD+oArrEWFVi0azFC3CMF6q4MEIdjUdQ=; b=X6ko30/5wEM3runP6ZI+WEKI8NIoYx4goqzPbIdwhjHqRzI2h8EPysFfyVnq1dQX9V HMN3rOQqYGI67ywXrQLoSlRsnhlKkruNh4yP03NDAuWUkfGxSVcYvdwD2ULsEt2b5zk5 1DM9PECe0i3B3yZKpBeVP7ObSUTlwnHRNPfOiKbasECWay5BqEhV8IeGotKPi46KHtY4 i3M1L8tVBCUdG3pTTKV393FccugfsgCVDCyCwth4cYPWzZ2RgWS4Z8Z9kz94/NlwIq3V qbKxP1D+AGe45z9+YNi1xnJuqDiQ5JqzJ+AzDz3LYp+NztpFg4uKeLXHuPKf6JcweKEj z0wg== X-Gm-Message-State: ANhLgQ0l+79nTzDMq94q1t5RcnxhYWFLvsgYogVCY+i0umHRYxlfNw/K SeCQIMJmqB5/teJawevNqRY= X-Google-Smtp-Source: ADFU+vvzbGu1aDK/HK6SfhtBu/67DHPOqytyvVEQPFL9isbCxGOtoZ9W4UaFrPeyFGK6h03sPniPVA== X-Received: by 2002:adf:ded2:: with SMTP id i18mr10997389wrn.173.1583614406918; Sat, 07 Mar 2020 12:53:26 -0800 (PST) Received: from nol ([2a01:e0a:c:bcf0:dbc8:f7e9:89ae:5cd7]) by smtp.gmail.com with ESMTPSA id m3sm35613655wrx.9.2020.03.07.12.53.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 07 Mar 2020 12:53:26 -0800 (PST) Date: Sat, 7 Mar 2020 21:53:28 +0100 From: Julien Rouhaud To: Tom Lane Cc: Michael Paquier , Michael Paquier , pgsql-hackers Subject: Re: Add an optional timeout clause to isolationtester step. Message-ID: <20200307205328.ffidfyo3me46qscn@nol> References: <20200227080735.l32fqcauy73lon7o@nol> <20200303080642.GA1890@paquier.xyz> <20200303092551.GB1890@paquier.xyz> <20200304051510.GE2593@paquier.xyz> <20200305035354.GQ2593@paquier.xyz> <20200306131547.GA2904@nol> <20200307014142.GC1531@paquier.xyz> <20200307061615.c47sju2bytuiaazv@nol> <8441.1583595994@sss.pgh.pa.us> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <8441.1583595994@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Sat, Mar 07, 2020 at 10:46:34AM -0500, Tom Lane wrote: > Julien Rouhaud writes: > > On Sat, Mar 07, 2020 at 10:41:42AM +0900, Michael Paquier wrote: > >> On Fri, Mar 06, 2020 at 02:15:47PM +0100, Julien Rouhaud wrote: > >>> Here's a patch to add an optional "timeout val" clause to isolationtester's > >>> step definition. When used, isolationtester will actively wait on the query > >>> rather than continuing with the permutation next step, and will issue a cancel > >>> once the defined timeout is reached. > > >> One problem with this approach is that it does address the stability > >> of the test on very slow machines, and there are some of them in the > >> buildfarm. > > > Looking at timeouts.spec and e.g. a7921f71a3c, it seems that we already chose > > to fix this problem by having a timeout long enough to statisfy the slower > > buildfarm members, even when running on fast machines, so I assumed that the > > same approach could be used here. > > The arbitrarily-set timeouts that exist in some of the isolation tests > are horrid kluges that have caused us lots of headaches in the past > and no doubt will again in the future. Aside from occasionally failing > when a machine is particularly overloaded, they cause the tests to > take far longer than necessary on decently-fast machines. Yeah, I have no doubt that it has been a pain, and this patch is clearly not a bullet-proof solution. > So ideally > we'd get rid of those entirely in favor of some more-dynamic approach. > Admittedly, I have no proposal for what that would be. The fault injection framework that was previously discussed would cover most of the usecase I can think of, but that's a way bigger project. > But adding yet > more ways to set a (guaranteed-to-be-wrong) timeout seems like the > wrong direction to be going in. Fair enough, I'll mark the patch as rejected then. > What's the actual need that you're trying to deal with? Testing the correct behavior of non trivial commands, such as CIC/reindex concurrently, that fails during the execution.