As discussed on the other mail thread:
https://www.postgresql.org/message-id/696885c3db9be6.68269280.fb0eaf68%40m0.mail.sina.com.cn



I need to do two changes on the patch.
1. Find some way to handle static variables.
2. Do not collect useless pages on the third step.

For the first one because the static variables needed on several place and it 
seem worst if
deliver by function parameters, so I keep them.

For the second one I have tryied to keep a commited transaction ID list or 
bitmapset, however
the data structs seem hard to use in src/bin code. So I use min_commited_xid 
and 
max_commited_xid instead to filter the useless pages.

In fact the min_commited_xid and max_commited_xid is the edge transaction 
commited after
diverge record, so it's enough.

Changed patch attached.



----
Best Regards,
Movead Li



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 



 


Attachment: 0001-pg_rewind_enhance.patch
Description: Binary data

Reply via email to