Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1f0R2O-0005e5-MI for pgsql-hackers@arkaria.postgresql.org; Mon, 26 Mar 2018 12:15:45 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f0R2N-0000TO-Ck for pgsql-hackers@arkaria.postgresql.org; Mon, 26 Mar 2018 12:15:43 +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_SHA384:256) (Exim 4.89) (envelope-from ) id 1f0R2N-0000TE-1l for pgsql-hackers@lists.postgresql.org; Mon, 26 Mar 2018 12:15:43 +0000 Received: from mail.postgrespro.ru ([93.174.131.138]) by magus.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1f0R2J-0004VV-Us for pgsql-hackers@postgresql.org; Mon, 26 Mar 2018 12:15:42 +0000 Received: from localhost (localhost [127.0.0.1]) by mail.postgrespro.ru (Postfix) with ESMTP id 8742021C1F4E; Mon, 26 Mar 2018 15:15:38 +0300 (MSK) X-Virus-Scanned: Debian amavisd-new at postgrespro.ru X-Spam-Flag: NO X-Spam-Score: 0 X-Spam-Level: X-Spam-Status: No, score=x tagged_above=-99 required=4 WHITELISTED tests=[] autolearn=unavailable Received: from mail.postgrespro.ru (cyclops.l.postgrespro.ru [192.168.27.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mail.postgrespro.ru (Postfix) with ESMTPSA id 5A90521C1F4C; Mon, 26 Mar 2018 15:15:38 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=postgrespro.ru; s=mail; t=1522066538; bh=tga7y0vRNpgG4aDfEKE753i21UFgN882cDlDjZjWfN8=; h=Date:From:To:Cc:Subject:In-Reply-To:References; b=ZXGb/lC8xedXCL6M//80HfgV1/TJmG7zgLkA4zxBuH9sy7flKsagA6QwSS0XHvypo z7zl4vP7P5qppqN+pq0POAlYaejR5gxFU375mHPPqGq2rYe2Pg+jvwYhW3AfMAlppV On06+exZTJd6IBbxY+j4PLUKsagybCTjKbG6SNfQ= MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Date: Mon, 26 Mar 2018 15:15:38 +0300 From: Marina Polyakova To: Teodor Sigaev , Fabien COELHO Cc: pgsql-hackers@postgresql.org Subject: Re: [HACKERS] WIP Patch: Pgbench Serialization and deadlock errors Organization: Postgres Professional In-Reply-To: References: <72a0d590d6ba06f242d75c2e641820ec@postgrespro.ru> <72ca61a8-b515-1bac-b082-b77952c78b64@sigaev.ru> Message-ID: X-Sender: m.polyakova@postgrespro.ru User-Agent: Roundcube Webmail/1.2.4 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 25-03-2018 15:23, Fabien COELHO wrote: >> Hm, I took a look on both thread about patch and it seems to me now >> it's overcomplicated. With recently committed enhancements of pgbench >> (\if, \when) it becomes close to impossible to retry transation in >> case of failure. So, initial approach just to rollback such >> transaction looks more attractive. > > Yep. Many thanks to both of you! I'm working on a patch in this direction.. > I think that the best approach for now is simply to reset (command > zero, random generator) and start over the whole script, without > attempting to be more intelligent. The limitations should be clearly > documented (one transaction per script), though. That would be a > significant enhancement already. I'm not sure that we can always do this, because we can get new errors until we finish the failed transaction block, and we need destroy the conditional stack.. -- Marina Polyakova Postgres Professional: http://www.postgrespro.com The Russian Postgres Company