Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ltaET-0000Bm-Jx for pgsql-hackers@arkaria.postgresql.org; Wed, 16 Jun 2021 18:25:45 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1ltaER-0008Qw-Ew for pgsql-hackers@arkaria.postgresql.org; Wed, 16 Jun 2021 18:25:43 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ltaER-0008Qn-36 for pgsql-hackers@lists.postgresql.org; Wed, 16 Jun 2021 18:25:43 +0000 Received: from sfr-1.cri.mines-paristech.fr ([77.158.180.225] helo=smtp.cri.ensmp.fr) by makus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ltaEJ-0002SO-Ak for pgsql-hackers@lists.postgresql.org; Wed, 16 Jun 2021 18:25:41 +0000 Received: from pseudo (185.141.6.84.rev.sfr.net [84.6.141.185]) by smtp.cri.ensmp.fr (Postfix) with ESMTPSA id 5A866C013F; Wed, 16 Jun 2021 20:27:26 +0200 (CEST) Date: Wed, 16 Jun 2021 20:25:31 +0200 (CEST) From: Fabien COELHO X-X-Sender: fabien@pseudo To: Yugo NAGATA cc: "kuroda.hayato@fujitsu.com" , "'pgsql-hackers@lists.postgresql.org'" Subject: Re: pgbench bug candidate: negative "initial connection time" In-Reply-To: <20210617005934.8bd37bf72efd5f1b38e6f482@sraoss.co.jp> Message-ID: References: <20210614170702.af28e1eeaa055a818f5880e0@sraoss.co.jp> <20210617005934.8bd37bf72efd5f1b38e6f482@sraoss.co.jp> User-Agent: Alpine 2.22 (DEB 394 2020-01-19) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk Hello Yugo-san, >> When connection break while the bench has already started, >> maybe it makes more sense to proceed, > > The result would be incomplete also in this case. However, the reason why > it is worth to proceed is that such information is still useful for users, > or we don't want to waste the bench that has already started? Hmmm. It depends on what the user is testing. If one is interested in client resilience under errors, the bench should probably attempt a reconnect. If one is interested in best performance when all is well, then clearly something is amiss and there is no point to go on. >> although I guess that maybe reattempting connections would make also >> sense in such case. > > This might become possible after pgbench gets the feature to retry in deadlock > or serialization errors. Yes, I agree that part of the needed infrastructure would be in place for that. As reconnecting is already in place under -c, so possibly it is just a matter of switching between states with some care. > I am working on rebase of the patch [2] and I will submit this in a few > days. Ok. Very good, I look forward to your submission! I'll be sure to look at it. -- Fabien.