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.96) (envelope-from ) id 1whnef-000Qae-2m for pgsql-hackers@arkaria.postgresql.org; Thu, 09 Jul 2026 12:15:02 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1whnee-00CwgU-18 for pgsql-hackers@arkaria.postgresql.org; Thu, 09 Jul 2026 12:15:01 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1whnee-00CwgJ-0D for pgsql-hackers@lists.postgresql.org; Thu, 09 Jul 2026 12:15:00 +0000 Received: from mail-oi1-x229.google.com ([2607:f8b0:4864:20::229]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1whnec-00000000Jav-3qFX for pgsql-hackers@postgresql.org; Thu, 09 Jul 2026 12:14:59 +0000 Received: by mail-oi1-x229.google.com with SMTP id 5614622812f47-49c86d1d21cso815471b6e.3 for ; Thu, 09 Jul 2026 05:14:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1783599299; cv=none; d=google.com; s=arc-20260327; b=WL8wthyM8B0cCXxMfJSiPS7gA2INpiF37hBHyPZPZZNXFbLWxcXsaOAmGBoQp0JHZb o9d+QHYecRgLFK1haPnUUouvYQX+ZJ9hGGpjJr27/kCnhLADi4n+rbSV5QCOtmTCnowp SFo3t+zcMk4QDQYTtxvbfyes7WGQ/e+TMWINBf9WxI+YKLGUzq7ivZdAQF9J6ANFyD12 T0DoUk+bpwzD7vE0aPNNLQPnRXIX4grrT+Q0dOdVH3sspy8oX46q/c5MtzZCvPCqec2S FvdyfEeGTj7Ov79kCHAeGQKUPcmXdfyLoIgquKamfS+/o3ytvog2dS39uCQvEgny7L5T D2wA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20260327; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=57UOJpx5WkppeJ9YchglfB6z68sYGbAyLpSFmytw3jY=; fh=fRU9cZBUNa06MH5lYM/8yasuW/YPqNHDyw3BMd20lc0=; b=aiGtycP9f+ALXgN/xq9iUwf8Ur1YpQJs1lCtRvsJFU4+gvRwWI9fbThAddnCW7s4Py nJb9Rln4Y/4bONHhxSrSKLqbuxum89k51WFd0m+BZ6BIpTiZYPPTNVN6Q6I5Ph1uxwGh ct2RbmpHStPVrcfbKqoNQsGWYHV9o56Ag+AYdPnc0a/wD0L9tjdZfuCbX3r8urv8htSW 5Lq0ERG60tT5Y6qhDSRPvEYi9mLVS+88Uu/LbDKJRU8gAqtJcrqyECqDiUIkOF+pH+Bf MSrWnLMH+ce8/Tw9VncUkazrmyHIcgPzalWRBI8AKPgJol72IkUmZ1fAPfXmnUnVKyaC sYdQ==; darn=postgresql.org ARC-Authentication-Results: i=1; mx.google.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1783599298; x=1784204098; darn=postgresql.org; h=content-transfer-encoding:content-type:cc:to:subject:message-id :date:from:in-reply-to:references:mime-version:from:to:cc:subject :date:message-id:reply-to:content-type; bh=57UOJpx5WkppeJ9YchglfB6z68sYGbAyLpSFmytw3jY=; b=P44GOyog6fr3QNVsMsmUvVQAEpk7TRgNXBOR0whrxgtqkW1Ueqzy2YBLOZLvOCscai ADlyRPOil44md3sDcabbMpJQQITL8OJc9FUvtV+Qc6nGwpz63FlkKqAPmP6X5S0HKdJw VWhs5MuA1J3R/5b/tWAdMiJvEaT63c/zdW1YzmJFoIDggUNtAywUbM60Y+jM2ZzVSCqy 3C8u4LM6gtshEU4VfJYBvj36a9bC73J49SlLZZMJ0+N1lLDvAUWueIbnAAhSi8TUlrfR reWK8D4xqcrzxjB5U3AyH6DVZdaFe7CD+PU7WzgI00IuaiEcg67RPtIqRucQX5Un5TvD +VfQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1783599299; x=1784204099; h=content-transfer-encoding:content-type:cc:to:subject:message-id :date:from:in-reply-to:references:mime-version:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=57UOJpx5WkppeJ9YchglfB6z68sYGbAyLpSFmytw3jY=; b=Ec/3trUOB7ke97AE2u7Van1H1GKrW8QdecrwW24R3B19EXhiozL/YcXLnP9rTmuIxg Ndat7wZkmW5tx1XJ2R0f1rOEFoSl5ZUfGTQDniaq9LJ0f4sXJiOXaIC0ylni0DKt7dHC ScIDcJsFinRKHxR++Sp5LLhHTeej1IN9JVii1hHe0YWqk4RKgBlZDpi1KzXTstpTgYU2 F8rL1DEh09hKvQ+cQEUt9RpmjUacrfOMbgcZSDfr8s22KxDgvAJFyDlj4hUDfLrXmx6E xDLauRpo/Fxzv4ltJrK0kJD9KWC1/zFTOIWsWoWPct3Qs12ezPwe1ilkyBhL+GKF0jCc zEWw== X-Forwarded-Encrypted: i=1; AFNElJ+IGOZFdgLceipK4IZ70naibq0uq0w8w+wbjvxJZUytu8u1B3srAT4ha5gpbm9D2bA6E0NcaJWEW7P6yGAF@postgresql.org X-Gm-Message-State: AOJu0YzoS9xoL6f2Zd/qOS0fdritS2Y64OHjJJN/8zJsg/iqHvx2h6Bn SVAtBbu0m5rnVL8dR6zuCoJTsk8Kjg/PRozcZqoXHZK3nAOcl8R6MXwfydfgO6OLA7yxBxSEjFY x2zYnz/005qlMBSBtNduBgcVnBcqi010= X-Gm-Gg: AfdE7cm4qcmVJKSfFK7yr54jHgxHcd65KG6lzqf1Ua6Wl8mNa01rDQb9H+OiQG8awyd kFP8Rz7yuTq5jX/esgtU/jfbUwZtoj6INVr9VMRFDfz2QjoRmsV4jf8FutrSH9MSuPpWTA+aNsT gV9Up3GrDy5E7kH8wEEux9zNUoT73+51nB7tg/bp0lufmSpG9OR0yWEriCAeBxJOg26w3oWhm4U 1bJViB7zCTABP45CzCBJbPZ4ll6XZvy6KosvBVV8/G+A1ca9Vohf0Zrzcv6p/BbDiQMKyJ0euBd OhFmG5eZpqaIul4VvNN9aINMEV/PkXA5tADRY3ePJAvqYY7QzoAnh023SjYuRx6MQBqI+lYKhm3 wpd8wBbsgECY= X-Received: by 2002:a05:6808:448a:b0:4a0:93e4:e15b with SMTP id 5614622812f47-4a203eb8751mr5965162b6e.24.1783599298475; Thu, 09 Jul 2026 05:14:58 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: From: Fujii Masao Date: Thu, 9 Jul 2026 21:14:46 +0900 X-Gm-Features: AUfX_mzfNwQtMdFakTVmMHV7p8hI-L5WZ-atvlJqLASfTv4YsnVcfnSl2YMKTJs Message-ID: Subject: Re: Add a hook for handling logical decoding messages on subscribers. To: Masahiko Sawada Cc: Amit Kapila , Bharath Rupireddy , PostgreSQL-development Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Wed, Jun 24, 2026 at 3:02=E2=80=AFAM Masahiko Sawada wrote: > Right. I'm implementing a basic DDL replication solution using this > hook as a sample implementation. Other than that, this feature can be > used to add additional information for the replicated transaction that > is not replicated via logical replication protocol, such as the > executed user or context-specific information, which can then be > dispatched to a CDC system connected to the subscriber. +1 for the proposed hook, although I haven't read the patch yet. I know of a system that uses logical decoding messages to propagate data to external systems. In that system, the application writes the data to be propagated as logical decoding messages, and a CDC pipeline consumes them via logical decoding and sends them to other systems, for example through Kafka. In that system, when the remote site is maintained by physical replication, the same logical decoding messages can be decoded on the standby at the remote site to deliver them to external systems there. However, if the remote site uses logical replication instead, those messages are currently neither delivered to nor processed on the subscriber at the remote site. As a result, the CDC pipeline at the remote site cannot consume the data they carry. The proposed hook might be useful for this use case. An extension could process the incoming logical decoding messages on the subscriber and forward them to the local CDC pipeline, or store or re-emit them in a form that local consumers can process. Regards, --=20 Fujii Masao