Re: More protocol.h replacements this time into walsender.c - Mailing list pgsql-hackers

From Jacob Champion
Subject Re: More protocol.h replacements this time into walsender.c
Date
Msg-id CAOYmi+mTZcww9k2o+Stc9QSD-cUPC4t_c0Nn_TFQA2c443UdkA@mail.gmail.com
Whole thread Raw
In response to Re: More protocol.h replacements this time into walsender.c  (Dave Cramer <davecramer@gmail.com>)
Responses Re: More protocol.h replacements this time into walsender.c
List pgsql-hackers
On Thu, Jul 24, 2025 at 12:04 PM Dave Cramer <davecramer@gmail.com> wrote:
> Patch attached

+/* Replication Protocol sent by the primary */
+
+#define PqMsg_XlogData              'w'
+#define PqMsg_PrimaryKeepAlive      'k'
+#define PqMsg_PrimaryStatusUpdate   's'
+
+
+/* Replication Protocol sent by the standby */
+
+#define PqMsg_StandbyStatus         'r'
+#define PqMsg_HotStandbyFeedback    'h'
+#define PqMsg_RequestPrimaryStatus  'p'

Since these are part of the replication subprotocol (i.e. tunneled,
via CopyData) rather than the top-level wire protocol, do they deserve
their own prefix? PqReplMsg_* maybe?

+/* These are the codes sent by the frontend and backend. */
+
+#define PqMsg_PasswordMessage 'p'
+
+/* These are the codes sent by the frontend and backend. */

Is this change intended?

--Jacob



pgsql-hackers by date:

Previous
From: "Joel Jacobson"
Date:
Subject: Re: Optimize LISTEN/NOTIFY
Next
From: Laurenz Albe
Date:
Subject: Re: Commitfest 2025-03 still has active patches