mirror of
https://github.com/postgres/postgres.git
synced 2025-08-28 18:48:04 +03:00
Separate messages for standby replies and hot standby feedback.
Allow messages to be sent at different times, and greatly reduce the frequency of hot standby feedback. Refactor to allow additional message types.
This commit is contained in:
@@ -56,6 +56,18 @@ typedef struct
|
||||
XLogRecPtr flush;
|
||||
XLogRecPtr apply;
|
||||
|
||||
/* Sender's system clock at the time of transmission */
|
||||
TimestampTz sendTime;
|
||||
} StandbyReplyMessage;
|
||||
|
||||
/*
|
||||
* Hot Standby feedback from standby (message type 'h'). This is wrapped within
|
||||
* a CopyData message at the FE/BE protocol level.
|
||||
*
|
||||
* Note that the data length is not specified here.
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
/*
|
||||
* The current xmin and epoch from the standby, for Hot Standby feedback.
|
||||
* This may be invalid if the standby-side does not support feedback,
|
||||
@@ -64,10 +76,9 @@ typedef struct
|
||||
TransactionId xmin;
|
||||
uint32 epoch;
|
||||
|
||||
|
||||
/* Sender's system clock at the time of transmission */
|
||||
TimestampTz sendTime;
|
||||
} StandbyReplyMessage;
|
||||
} StandbyHSFeedbackMessage;
|
||||
|
||||
/*
|
||||
* Maximum data payload in a WAL data message. Must be >= XLOG_BLCKSZ.
|
||||
|
Reference in New Issue
Block a user