| From: | Gyan Sreejith <gyan(dot)sreejith(at)gmail(dot)com> |
|---|---|
| To: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> |
| Cc: | Euler Taveira <euler(at)eulerto(dot)com>, vignesh C <vignesh21(at)gmail(dot)com>, "kuroda(dot)hayato(at)fujitsu(dot)com" <kuroda(dot)hayato(at)fujitsu(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Peter Smith <smithpb2250(at)gmail(dot)com> |
| Subject: | Re: [Proposal] Adding Log File Capability to pg_createsubscriber |
| Date: | 2026-03-09 22:55:56 |
| Message-ID: | CAEqnbaU50vLy031AbvmfXJ3_qv9iS4pVaMdmsnmpF87r=EqW7Q@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Thu, Mar 5, 2026 at 9:49 AM Euler Taveira <euler(at)eulerto(dot)com> wrote:
Don't duplicate code. If you are reusing a function, my advice is to move
> it to
> src/common. You can always use "ifdef FRONTEND" to use the appropriate log
> message (elog/ereport vs pg_error, for example).
I have made all the changes except for this one, and I am deferring to Amit
Kapila regarding the marks.
Regarding duplicating code - I was trying to keep the change contained. Is
it okay to make that change in a separate check in since it would also
touch src/backend/postmaster/syslogger.c?
Thank you!
Gyan Sreejith
On Fri, Mar 6, 2026 at 5:51 AM Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> wrote:
> On Thu, Mar 5, 2026 at 8:19 PM Euler Taveira <euler(at)eulerto(dot)com> wrote:
> >
> > One of the arguments to have this feature was that pg_createsubscriber
> mixes the
> > server and tool messages. Couldn't we fix it adding "marks" on the
> output saying
> > the server log messages starts here and the server log messages ends
> here?
> >
>
> It will simplify the output to some extent but still it will be mixed
> at different intervals in the LOG which is not good for grepping
> required info. Also, I am not sure if we use such markers at other
> places.
>
> --
> With Regards,
> Amit Kapila.
>
| Attachment | Content-Type | Size |
|---|---|---|
| v7-0001-Add-a-new-argument-l-logdir-to-pg_createsubscribe.patch | application/octet-stream | 12.6 KB |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Sami Imseih | 2026-03-09 23:33:08 | Re: Add missing stats_reset column to pg_stat_database_conflicts view |
| Previous Message | Corey Huinker | 2026-03-09 22:42:46 | Re: Add starelid, attnum to pg_stats and leverage this in pg_dump |