Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eeKZ0-0000Jy-9z for pgsql-hackers@arkaria.postgresql.org; Wed, 24 Jan 2018 12:54:02 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eeKYz-0002sJ-Qw for pgsql-hackers@arkaria.postgresql.org; Wed, 24 Jan 2018 12:54:01 +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.84_2) (envelope-from ) id 1eeKYz-0002s8-Jh for pgsql-hackers@lists.postgresql.org; Wed, 24 Jan 2018 12:54:01 +0000 Received: from mail-wm0-x22d.google.com ([2a00:1450:400c:c09::22d]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1eeKYs-000766-Ea for pgsql-hackers@postgresql.org; Wed, 24 Jan 2018 12:54:01 +0000 Received: by mail-wm0-x22d.google.com with SMTP id v71so8438697wmv.2 for ; Wed, 24 Jan 2018 04:53:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=2ndquadrant-com.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=flAkac0cf+QwPNyWfUOsze133RYkcQctsBn6RQ3TNf8=; b=aszI9WwSciQtCLXlhpsGZzWLYPWVOA43VxW4jPuPcx9e9A72QH4+PnwfNUongZOkLN HkScfr4r95hjR1CXV6fG4eVH13rzIjQx7UcLa0JrrKo3IoQPJz/NP3E7EdJcCtTGfJOr 7jK4qMlvKMbFxVZVi9cKEeQIetNThuMWxGPhf/+uxnQyxp3R9WaSgScL4jRhPZ7A2VKY ZnV3E1t1CQn9Glp0mCVNf1mDTNrYZslFx0csXbQ2MOIZdU+avdD78G4AlAoCcs/ba6uT M98vaIPL9HhmepRQh2UztTNXJOM+mZ388ReA4uAgkGDjPSCxRkNjdjnWc020Kkaf8rvq zlmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=flAkac0cf+QwPNyWfUOsze133RYkcQctsBn6RQ3TNf8=; b=uAyFpaLk4NFxF1HyZk3NNv1lUAEkj9fFUYcwotLSAdh7qXSP5alJZw13glF1cBrHqk LvWkTn/KmKu7EoocIPvHHrkyB5DF6kvClnHSQI7q/V/hRxIDWIv0BMKW7JZYe/A+Y0ho f0bIJMi/IDEBUz+DOkVJgHWTSPY1ZSCAXYPm3jW00/Bxui+d5OruH6OEh8YyoSN5wp91 Apd5GU/1+wMWvWwQh0nYO1yxt7b9ZDdyacUEsm1ggPuJm6H3L9IxbmNDwVnUo7oB6cKR GSbKESsU2j/oFXuNtmHNxHWfw8EbjeyPfcad1y3Q7BK9M7tZrgqE21qHOEZQg9A4LuJI Bfeg== X-Gm-Message-State: AKwxytfuxwAOD0N1el6h+j7A8B/YWtOsoH5/IuGE/vJm7IDSJDtqHV+H 0KveBvho7CXFsHoQzY0VGEY3oOVMpwGYiS7AgTyqfF2IyXUX9nIaoQLe5UHwk1Bc4enuJ76oID9 +OEwCCoE27XIgvRbtoSQACAXaZuE3Y1RQhl1Umk6Ib8nu2fsTO7zE/eNxnL/DGucPqrgb4RMwSC kaYjCbs/Iccj8= X-Google-Smtp-Source: AH8x224Nc27kqAMBrZPBqQBPqsPbbYkcVJ2srqSwgfs1DQEvSgttF/ltYAmuFybUETVam254dCVDdA== X-Received: by 10.28.62.203 with SMTP id l194mr4497414wma.121.1516798431892; Wed, 24 Jan 2018 04:53:51 -0800 (PST) Received: from [192.168.0.106] (150.123.broadband11.iol.cz. [90.178.123.150]) by smtp.gmail.com with ESMTPSA id 14sm2319941wry.39.2018.01.24.04.53.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 24 Jan 2018 04:53:51 -0800 (PST) Subject: Re: [PATCH] Logical decoding of TRUNCATE To: Peter Eisentraut , Marco Nenciarini , Simon Riggs Cc: PostgreSQL-development References: <269bf0d2-6ac4-c032-6979-22aad6a9f5fb@2ndquadrant.it> <35a1d60b-f66d-4001-499b-2336ca81fc6c@2ndquadrant.it> <1a4ace10-1997-6644-d17a-5a17bf250270@2ndquadrant.it> <28a59551-b1f5-8ed4-65cf-76d17e7ee7e6@2ndquadrant.it> <1cb9bd52-9e3a-21bf-0c0c-afa90f463629@2ndquadrant.com> <0361327b-5d59-32b0-cb13-e844acf0f0d0@2ndquadrant.it> <31773cc5-3b29-1740-e7d2-dc48e80a06ce@2ndquadrant.com> <35df4fd5-6b74-9c15-9246-ead8854cc669@2ndquadrant.com> <5462dc00-4941-167e-b287-d7bd9b2283e9@2ndquadrant.com> From: Petr Jelinek Message-ID: <3952d6e6-f438-f393-9a02-aae871d2fc3e@2ndquadrant.com> Date: Wed, 24 Jan 2018 13:53:50 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: <5462dc00-4941-167e-b287-d7bd9b2283e9@2ndquadrant.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On 24/01/18 13:50, Peter Eisentraut wrote: > I wonder whether this should be dealing with sequences at all. We are > not currently publishing any information about sequences, so it seems > weird to do it only here. Also, I'd imagine that if we ever get to > publishing sequence events, then the sequence restarts would be > published as independent events. > That depends on if we consider this to be part of sequence handling or truncate statement replication handling. It's true that if we had sequence replication, the restart would get propagated that way anyway. OTOH, if we'll want to add option in the future to propagate cascade (to any additional tables on downstream), it may need to reset sequences which are not even present upstream and as such would not be handled by sequence replication. -- Petr Jelinek http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services