Re: More protocol.h replacements this time into walsender.c

From: Jacob Champion <jacob(dot)champion(at)enterprisedb(dot)com>
To: Dave Cramer <davecramer(at)gmail(dot)com>
Cc: Nathan Bossart <nathandbossart(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: More protocol.h replacements this time into walsender.c
Date: 2025-07-24 21:05:33
Message-ID: CAOYmi+mTZcww9k2o+Stc9QSD-cUPC4t_c0Nn_TFQA2c443UdkA@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Jul 24, 2025 at 12:04 PM Dave Cramer <davecramer(at)gmail(dot)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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Laurenz Albe 2025-07-24 21:11:06 Re: Commitfest 2025-03 still has active patches
Previous Message Joel Jacobson 2025-07-24 21:03:27 Re: Optimize LISTEN/NOTIFY