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 1wALVS-002I7d-1N for pgsql-hackers@arkaria.postgresql.org; Wed, 08 Apr 2026 05:31:14 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.96) (envelope-from ) id 1wALVQ-0053pS-3D for pgsql-hackers@arkaria.postgresql.org; Wed, 08 Apr 2026 05:31:13 +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 1wALVQ-0053pI-2K for pgsql-hackers@lists.postgresql.org; Wed, 08 Apr 2026 05:31:13 +0000 Received: from mail-lj1-x231.google.com ([2a00:1450:4864:20::231]) by makus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.98.2) (envelope-from ) id 1wALVP-00000001ANd-1bev for pgsql-hackers@lists.postgresql.org; Wed, 08 Apr 2026 05:31:12 +0000 Received: by mail-lj1-x231.google.com with SMTP id 38308e7fff4ca-38e0ef48ac0so20261871fa.3 for ; Tue, 07 Apr 2026 22:31:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1775626270; cv=none; d=google.com; s=arc-20240605; b=LCU1AKcrYwB9bBL046Cokd7Hr8PuWBVoZwQAd6+M8rqZv3FkCOosluSVXdZsCemlwh zTyVE6Fkhb913ti+Kjly0C3QfbnPLsDSDyaXh7FFvPStOiEFvlrKbt6pz7gIVX1DYeTn DuMUV65/95VQUvyQ6yblA0mt2FCq1bRaItbvy5Q9D2Yh6mrzhd3GlQ61+wHqO3rvfI6t DRyze/7loXZ0KGVsC1uLwkDMHlBsFmbI18WCYIWaqV2ptC7kADm6zZr0y4hJoFZS1LsD YANST4sKYEdmHFEHRI26uVc4om8Aec5yAI1d0TeWH3pDFj17kBhbPRZ6H4SZgfK5VDBY RPPw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=6JfGHbJNDXif69FMQ57sonru46a754jYDrwL9tjX1e8=; fh=uzDMEq2f1d+tDqXBaijkm5MKRahMRz5MOMQlA2yITJM=; b=hAUcvw5GwxJEaJMVYfKQaSmGJjJDTKEAAeYXSgtady8MA95B/2r6A4ImVc4o6B63q/ 4ZuUYH+h05n7h+/Ivb/eykgWTKKbkKVzuuxfAEhhuJZinz76yCPA6TjDIGdECFrUu3gc ZB1NDtWnHSM74xi/xzd4s11Pm6ww4mQkEbIb+DFr9+39FyYDGBS/MvQHurjGgQgWbe7p ubarjDd7dcluuEFSEEoFocDZxTI9BeJA8S+mkgMQVgqRm/0J4GuCV1sALbRMnd9QHdNa M2i+h13XzjoI0DooXsJY6MVgCru70mMB9VH4+0ahP24Jkpi1YeDse7hynqmUWHxr8YMP slcg==; darn=lists.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=1775626270; x=1776231070; darn=lists.postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=6JfGHbJNDXif69FMQ57sonru46a754jYDrwL9tjX1e8=; b=epksAQ0uIBZvpO/cXHyXd1A8PqQzNThOAfTjTNgiKHdiEIbGAYE4Uhvaf3HxHwooUU 4km72mJJMp6Ep6JT1c2h2bx2d29F95EERHOiGxqV3e9VcX8h7FQOEh+tTrGHv80rbvsp W0p8gcIqSyAlMrmiO6j66ScsRiedgKAoYfCqGIHjakJU2vqZnqvxN0gH46hN5NJ44n0e wkImVTRx6+C8UVJxNcstP7GKkCdqgUrpgPopdj9yxBt+NEon9oKkEdRQNo7bkE/K8YVc Tsh1Yb/EU4fd7KYol7gmgLua8/fdNmllnX8Puj5dJ559ieftM+tGiP3iiZSX4aOu3dWi s3eQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1775626270; x=1776231070; h=content-transfer-encoding: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; bh=6JfGHbJNDXif69FMQ57sonru46a754jYDrwL9tjX1e8=; b=ramtxz+gX/7gDaWwHtHgJtajoGaiUqwigqzfZ0r/e4fgzQyKF4HZL+ok5DSoGgpPkt YAinygGldtOQxsNrBJA4SHneJs5lBR+VV8FjWpO33+sbt/uZxou5Q0RALrBEhJLqhey9 JDx10PtWi5E8BL9Vg3FFm6J2kt0etxcXaBhXvfeTA+JDSSlGVyCqFgPoO7nGVH20K22G 1RGIBmKQh+MxNNJS+hXiKuM7+861aG+XMAcRi96AfkXegyU3WVS/R7eXq1fkBLd2jd20 3R/ZAnm1P1MJ7nBZeqgBdzKRgv8ECUY/68bFwsa1hGuG+RnEGeWAGhjzzXjvql6WtYSg 6HjA== X-Forwarded-Encrypted: i=1; AJvYcCWd3O9cPCHhB8Uzl8MEMbVPtZ7xn6123mPU4q9jSlVkrRPjZtSm7gKvP0k+eHHq8IDvRSVVH6/DYQhTYFH+@lists.postgresql.org X-Gm-Message-State: AOJu0YwN4us2ymTvWhcvLzYzwumpXeHAEWRo0hkegxNdrzurO4DE2QTz XJNQoFMGMoIk6VyxKusvExoJWSpiyToFkpWflQJwf1H8fEmw8VMV65YTc2plC4B2U53WjnAQFGC h1ugwQgf9iFJpQG61On/nwQYPkpYldxo= X-Gm-Gg: AeBDievx4gFD8Z6K+sKu9+EugpROuyi+Lh1QoXOwxJy2Cscbz12TsrLK6Qs4RvnQsBI 9HeBNcjUYeaaXHN36brZUAxQjZ27NnyGWz4/U79fPcV4fMUlojC8PmhyiMrmCj6u8KDV+4X+Bl6 BFWYTUO7OB+gCqJ5UIVWJV8DwSOEiBjt9CBqw4p+/W9mZG3U+8KONT/ChIDJnm9agi6NWaxou0d Ipi0xR+K7eWc6nYn0v0gFgDVjTwDFUUwygTvfHTHvL1flzZB+HAcVaaInh2w7CSmWciyMrdYffN cFAPRbQlQzLvSu/2acdxGuBcZIamJRrAOGCXYqg= X-Received: by 2002:a05:651c:110c:b0:38d:e7cc:2971 with SMTP id 38308e7fff4ca-38de7cc31afmr53467431fa.9.1775626269708; Tue, 07 Apr 2026 22:31:09 -0700 (PDT) MIME-Version: 1.0 References: <4c2eb422-696c-4e34-84e7-6c6cd95781ab@eisentraut.org> <618f670b-b097-4bd1-8d88-a6eaad031c06@eisentraut.org> In-Reply-To: <618f670b-b097-4bd1-8d88-a6eaad031c06@eisentraut.org> From: Amit Kapila Date: Wed, 8 Apr 2026 11:00:58 +0530 X-Gm-Features: AQROBzC5chhlZBCaCVUAaa6QlVapEhhQFFqpkEWY0BqknJ-GN1BIvHzO5LOPOSA Message-ID: Subject: Re: [Proposal] Adding Log File Capability to pg_createsubscriber To: Peter Eisentraut Cc: "Hayato Kuroda (Fujitsu)" , Gyan Sreejith , Peter Smith , shveta malik , Shlok Kyal , vignesh C , Euler Taveira , "pgsql-hackers@lists.postgresql.org" 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 Tue, Apr 7, 2026 at 7:07=E2=80=AFPM Peter Eisentraut wrote: > > On 01.04.26 07:05, Hayato Kuroda (Fujitsu) wrote: > > Dear Peter E., > > > >> Instead of creating a new logging API in pg_createsubscriber locally, > >> why not extend logging.c to support a log file. > > > > I had a concern to extend the common module. Do you have possible idea = to use > > pg_logging_set_logfile() on others? I cannot, tee command on linux seem= s enough > > for others. > > pg_upgrade was mentioned. > I see that pg_upgrade has some specific requirements related to verbose/status/report kind of messages which doesn't seem to be directly handled by the generic API pg_log_generic(). For example, apart from other things, we need to unset/reset log_file when we want to send messages only to the terminal and quite some specific handling for status or other kinds of messages. If you think pg_log_generic could be extended to handle various upgrade cases then I think it would be a good use case for it and we should go-ahead with what you are proposing. OTOH, maybe we can give it a separate try and use the resulting API for both pg_createsubscriber and pg_upgrade. I am fine either way you would like to go-ahead with this. --=20 With Regards, Amit Kapila.