refactor some protocol message sending in walsender and basebackup
Peter Eisentraut <peter.eisentraut@enterprisedb.com>
From: Peter Eisentraut <peter.eisentraut@enterprisedb.com>
To: pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2022-06-23T14:36:36Z
Lists: pgsql-hackers
Attachments
- 0001-Fix-attlen-in-RowDescription-of-BASE_BACKUP-response.patch (text/plain) patch 0001
- 0002-Change-timeline-field-of-IDENTIFY_SYSTEM-to-int8.patch (text/plain) patch 0002
- 0003-Refactor-sending-of-RowDescription-messages-in-repli.patch (text/plain) patch 0003
- 0004-Refactor-sending-of-DataRow-messages-in-replication-.patch (text/plain) patch 0004
Some places in walsender.c and basebackup_copy.c open-code the sending of RowDescription and DataRow protocol messages. But there are already more compact and robust solutions available for this, using DestRemoteSimple and associated machinery, already in use in walsender.c. The attached patches 0001 and 0002 are tiny bug fixes I found during this. Patches 0003 and 0004 are the main refactorings. They should probably be combined into one patch eventually, but this way the treatment of RowDescription and DataRow is presented separately.
Commits
-
Refactor sending of DataRow messages in replication protocol
- 16d52fc89dbe 16.0 landed
-
Refactor sending of RowDescription messages in replication protocol
- 2ce648f750a9 16.0 landed
-
Change timeline field of IDENTIFY_SYSTEM to int8
- ec40f3422412 16.0 landed
-
Fix attlen in RowDescription of BASE_BACKUP response
- 4e85b97304a7 16.0 landed