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 1lGkl9-00026z-M4 for pgsql-hackers@arkaria.postgresql.org; Mon, 01 Mar 2021 15:47:00 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lGkl8-0000qL-JC for pgsql-hackers@arkaria.postgresql.org; Mon, 01 Mar 2021 15:46:58 +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 1lGkl8-0000qE-9D for pgsql-hackers@lists.postgresql.org; Mon, 01 Mar 2021 15:46:58 +0000 Received: from mail.postgrespro.ru ([93.174.131.139]) by makus.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1lGkl4-00049Y-OJ for pgsql-hackers@postgresql.org; Mon, 01 Mar 2021 15:46:57 +0000 Received: from [192.168.1.72] (109-252-124-197.nat.spd-mgts.ru [109.252.124.197]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mail.postgrespro.ru (Postfix) with ESMTPSA id EAF1721C0154; Mon, 1 Mar 2021 18:46:51 +0300 (MSK) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=postgrespro.ru; s=mail; t=1614613612; bh=DZx1u9pSPc7Yw/jz1SM/4j9VAzGJcooGaCRhmVZxF6Q=; h=Subject:To:References:From:Date:In-Reply-To; b=WnzuWI79jaELrTHbBT2M2AS5GL41T3pUdsRRAJCZ+tbsphfMaO3pvoFlfz268ehrj d4DvLrVWrg2ZvVj+VN4pWGrHvvYduHTZmLgyZ0sVGagc7EHHxQozKg3b6LHhf2/xHq zxMYyAxKeeYEKncsod6xAIS+Qnh11RvA0lEDTmDg= Subject: Re: Improving connection scalability: GetSnapshotData() To: AJG , pgsql-hackers@postgresql.org References: <20200301083601.ews6hz5dduc3w2se@alap3.anarazel.de> <1614447658602-0.post@n3.nabble.com> From: Konstantin Knizhnik Message-ID: <4ac9a8e1-d170-7a2c-5ab5-36cbd5946a50@postgrespro.ru> Date: Mon, 1 Mar 2021 18:46:51 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <1614447658602-0.post@n3.nabble.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 27.02.2021 20:40, AJG wrote: > Hi, > > Greatly appreciate if you could please reply to the following questions as > time allows. > > I have seen previous discussion/patches on a built-in connection pooler. How > does this scalability improvement, particularly idle connection improvements > etc, affect that built-in pooler need, if any? > > > Same general question about an external connection pooler in general in > Production? Still required to route to different servers but no longer > needed for the pooling part. as an example. > > > Many Thanks! > Connection pooler is still needed. The patch for GetSnapshotData() mostly improves scalability of read-only queries and reduce contention for procarray lock. But read-write upload cause contention for many other resources: relation extension lock, buffer locks, tuple locks and so on. If you run pgbench at NUMA machine with hundreds of cores, then you will still observe significant degradation of performance with increasing number of connection. And this degradation will be dramatic if you replace some non-uniform distribution of keys, for example Zipfian distribution. > > > > -- > Sent from: https://www.postgresql-archive.org/PostgreSQL-hackers-f1928748.html > >