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.89) (envelope-from ) id 1j1B8a-0004iM-Rm for pgsql-committers@arkaria.postgresql.org; Mon, 10 Feb 2020 15:38:17 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1j1B8Z-0006Wr-5B for pgsql-committers@arkaria.postgresql.org; Mon, 10 Feb 2020 15:38:15 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1j1B8Y-0006Wc-5a for pgsql-committers@lists.postgresql.org; Mon, 10 Feb 2020 15:38:14 +0000 Received: from [66.111.4.29] (helo=out5-smtp.messagingengine.com) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1j1B8Q-0003Rf-Pp for pgsql-committers@lists.postgresql.org; Mon, 10 Feb 2020 15:38:12 +0000 Received: from compute7.internal (compute7.nyi.internal [10.202.2.47]) by mailout.nyi.internal (Postfix) with ESMTP id B712522460; Mon, 10 Feb 2020 10:37:55 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Mon, 10 Feb 2020 10:37:55 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-proxy:x-me-proxy:x-me-sender:x-me-sender :x-sasl-enc; s=fm2; bh=IQDulwi9G+bXs6bjP0YAvQyKFZ+2zdgEe+qsnflCZ Ww=; b=wVAfGiA5IVErZc9wIPJ0l+ltSHSHA/OKk8/fUOlIOqZ6+AG3RwvlNqCSz Z3k7qNV48+UCDDOLPdh0rgBw48Bjraku3LStF30A8gJZI8CVuyaIR19FRWcPE9Y6 jVy8xQog+AttdFhzCyJdszg0vSGkbmHs23ec/+nEQuom9dZ6Z2fURxqKD2NMQzCV Yzm26KQUd46G3o9WGH5G4WTcjoz0+F1tD/oYldEmu3CMN4P4HiKvnWCY+lChgdsi kX1qhJMRNmqlq67HeWGZ3Fg52fnNA6Umi+90q6GVDsRwrHQx5oS6TJ/HHWqzHAj1 rjcU/acYuiX9yHXbQyrGSPrSxIqHw== X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedugedriedugdejhecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefuvfhfhfhokffffgggjggtgfesthejredttdefjeenucfhrhhomheprfgvthgv rhcugfhishgvnhhtrhgruhhtuceophgvthgvrhdrvghishgvnhhtrhgruhhtsedvnhguqh hurggurhgrnhhtrdgtohhmqeenucffohhmrghinhepphhoshhtghhrvghsqhhlrdhorhhg pddvnhguqhhurggurhgrnhhtrdgtohhmnecukfhppeelfedrvdegvddrvdehhedrudduvd enucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpehpvght vghrrdgvihhsvghnthhrrghuthesvdhnughquhgrughrrghnthdrtghomh X-ME-Proxy: Received: from april.pezone.net (p5df2ff70.dip0.t-ipconnect.de [93.242.255.112]) by mail.messagingengine.com (Postfix) with ESMTPA id ECFAF30600DC; Mon, 10 Feb 2020 10:37:54 -0500 (EST) Subject: Re: pgsql: walreceiver uses a temporary replication slot by default To: Robert Haas References: Cc: pgsql-committers From: Peter Eisentraut Organization: 2ndQuadrant Message-ID: <739e2a5e-56d0-2a12-03ca-2c02631b1699@2ndquadrant.com> Date: Mon, 10 Feb 2020 16:37:53 +0100 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Host-Lookup-Failed: Reverse DNS lookup failed for 66.111.4.29 (deferred) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 2020-01-23 21:49, Robert Haas wrote: > On Tue, Jan 14, 2020 at 8:57 AM Peter Eisentraut wrote: >> walreceiver uses a temporary replication slot by default >> >> If no permanent replication slot is configured using >> primary_slot_name, the walreceiver now creates and uses a temporary >> replication slot. A new setting wal_receiver_create_temp_slot can be >> used to disable this behavior, for example, if the remote instance is >> out of replication slots. >> >> Reviewed-by: Masahiko Sawada >> Discussion: https://www.postgresql.org/message-id/CA%2Bfd4k4dM0iEPLxyVyme2RAFsn8SUgrNtBJOu81YqTY4V%2BnqZA%40mail.gmail.com > > Neither the commit message for this patch nor any of the comments in > the patch seem to explain why this is a desirable change. > > I assume that's probably discussed on the thread that is linked here, > but you shouldn't have to dig through the discussion thread to figure > out what the benefits of a change like this are. You are right, this has gotten a bit lost in the big thread. The rationale is basically the same as why client-side tools like pg_basebackup use a temporary slot: So that the WAL data that they are interested in doesn't disappear while they are connected. -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services