On Mon, Apr 17, 2023 at 4:22 PM Tom Lane <t...@sss.pgh.pa.us> wrote: > The fact that we've gotten away without adding *any* new message types > for about twenty years suggests to me that the growth rate isn't such > that we need sub-message-types yet. I'd keep the structure the same > until such time as we can't choose a plausible code value for a new > message, and then maybe add the "x-and-subtype" convention Jeff suggests.
One thing I think we should do in this area is introduce #defines for all the message type codes and use those instead of having hard-coded constants everywhere. I'm not brave enough to tackle that day, but the only reason the current situation isn't a disaster is because every place we use e.g. 'Z' we generally also have a comment that mentions ReadyForQuery. If it weren't for that, this would be pretty un-greppable. -- Robert Haas EDB: http://www.enterprisedb.com