| From: | John Naylor <johncnaylorls(at)gmail(dot)com> |
|---|---|
| To: | Imran Zaheer <imran(dot)zhir(at)gmail(dot)com> |
| Cc: | pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
| Subject: | Re: Move system identifier generation to a common helper |
| Date: | 2026-09-22 04:53:31 |
| Message-ID: | CANWCAZaaUORye955Qmmv7vXahSoKCBwHLxKmTtkRG-vA4e5FkQ@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Thu, Jun 4, 2026 at 7:22 PM Imran Zaheer <imran(dot)zhir(at)gmail(dot)com> wrote:
> The code used to generate a new system identifier is duplicated in
> multiple locations, including BootStrapXLOG(), pg_createsubscriber, and
> pg_resetwal.
>
> Move the generation logic into a common GenerateSystemIdentifier()
> helper so that all callers use a single implementation, avoiding
> duplication of the same algorithm.
This seems like a useful cleanup, and the first step to take if we end
up using any of the ideas in this thread at some point.
I'm not really a fan of creating a new C file and new header for just
one function. Maybe there's an existing logical place for it?
--
John Naylor
Amazon Web Services
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Chao Li | 2026-09-22 04:59:52 | Re: Adding a range check on the sequence index from the publisher. |
| Previous Message | John Naylor | 2026-09-22 04:45:47 | Re: Stop asserting that Unicode normalization consumes its whole input |