Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rPJbi-00AjTI-C5 for pgsql-hackers@arkaria.postgresql.org; Mon, 15 Jan 2024 09:50:15 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1rPJbf-00Ea23-PI for pgsql-hackers@arkaria.postgresql.org; Mon, 15 Jan 2024 09:50:11 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rPJbe-00Ea1X-LQ for pgsql-hackers@lists.postgresql.org; Mon, 15 Jan 2024 09:50:11 +0000 Received: from out2-smtp.messagingengine.com ([66.111.4.26]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1rPJbW-001ucy-Rw for pgsql-hackers@postgresql.org; Mon, 15 Jan 2024 09:50:10 +0000 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id DB6A65C005E; Mon, 15 Jan 2024 04:49:58 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Mon, 15 Jan 2024 04:49:58 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm3; t=1705312198; x= 1705398598; bh=jG7F4AqcMSx7TF8vpW5T9cHTo2ayme4HO4o4Ugu1sho=; b=n g9yFaa8Gwkn7+l6dGkpElfq3EmVuUUm2q1Vk3YI3Uc8e1OrFuBNy72lVO7yq83M6 9tEwfsi4b9gPqqWrkM7f0qS2v4Mnn4vmeIdQPJQ3n9VSukhI3jiVVeMJJilcwdvI 8JC7akSXS2kkwGFBSNf8utAgqoEuBU3Iv7TOFhpVQ2ImEVGXGRkloIXVqKSjQNuq 6wN8V5lZofEiDsKlUfy41uz4XbEcQa8NuZ4dU1OImwqW39IyjC6hKne5KfpogEY8 L6Me8xlpmQ0hyndKmf5MBafiMMv775k3UFcI/4DUKEAkIVP0QgCthRc1VGaB9sa/ 3465FJS7OSK8qCN409Geg== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvkedrvdejuddgtdelucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhepfffhvfevuffkgggtugfgjgesthekredttddtjeenucfhrhhomheptehlvhgr rhhoucfjvghrrhgvrhgruceorghlvhhhvghrrhgvsegrlhhvhhdrnhhoqdhiphdrohhrgh eqnecuggftrfgrthhtvghrnhepvdektdffudfftdffffehfffhjeejhffgieeuueekjeek fffgudffhfduffffueevnecuffhomhgrihhnpegvnhhtvghrphhrihhsvggusgdrtghomh enucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpegrlhhv hhgvrhhrvgesrghlvhhhrdhnohdqihhprdhorhhg X-ME-Proxy: Feedback-ID: ia2694551:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Mon, 15 Jan 2024 04:49:58 -0500 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alvh.no-ip.org; s=schmee; t=1705312196; bh=pg/OITF+/XaSJZLHwf+vGUlT35UOAMDeTYH0kZyF/pk=; h=Date:From:To:Cc:Subject:In-Reply-To:From; b=LII42OrJeLkRbAy6t5Mi/31OoGNKxcfaUBYL6+WLPqwdxKk9FyElGCh8Wr6gWH9TG Sch82OYU0YA/+UEY99IO2g2OJgAK9YYAGsx3lXPUD6UxwHKyy6RgwcDtRDeXby60Mr rBpy5LCOttBBrrJ/ZCZuLNG9m+oSf2ABnuDNMHzDApKvmfxeHbnnFBWLl7eIJPT8aT atmp5GZir6QQ4SqAbBcpqqx/9YLlddUc5eT4uePtA4LmO+UPGrKY+xkyF9/EFDlQ/y vfMCRUOhBnMqUU0rhcGot+jIM84B9FsixDCHto3Oms3TJ+xPf0lDeR6h0ORskTm/y9 cSjsHJz9dfKGw== Received: by schmee.alvh.no-ip.org (Postfix, from userid 1000) id 9160F9D; Mon, 15 Jan 2024 10:49:56 +0100 (CET) Date: Mon, 15 Jan 2024 10:49:56 +0100 From: Alvaro Herrera To: Michael Paquier Cc: Jelte Fennema-Nio , Anthonin Bonnefoy , Anton Kirilov , Robert Haas , pgsql-hackers@postgresql.org Subject: Re: Add PQsendSyncMessage() to libpq Message-ID: <202401150949.wq7ynlmqxphy@alvherre.pgsql> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On 2024-Jan-15, Michael Paquier wrote: Looks good! Just some small notes, > +/* > + * Wrapper for PQpipelineSync and PQsendPipelineSync. > * > * It's legal to start submitting more commands in the pipeline immediately, > * without waiting for the results of the current pipeline. There's no need to the new function pqPipelineSyncInternal is not a wrapper for these other two functions -- the opposite is true actually. We tend to use the term "workhorse" or "internal workhorse" for this kind of thing. In the docs, after this patch we have - PQpipelineSync - PQsendFlushRequest - PQsendPipelineSync Wouldn't it make more sense to add the new function in the middle of the two existing ones instead? Looking again at the largish comment that's now atop pqPipelineSyncInternal(), I think most of it should be removed -- these things should be explained in the SGML docs, and I think they are, in the "Using Pipeline Mode" section. We can just have the lines this patch is adding. -- Álvaro Herrera 48°01'N 7°57'E — https://www.EnterpriseDB.com/ "I can't go to a restaurant and order food because I keep looking at the fonts on the menu. Five minutes later I realize that it's also talking about food" (Donald Knuth)