Fix bufmgr so CHECKPOINT_END_OF_RECOVERY behaves as a shutdown checkpoint. Recovery code documents clearly that a shutdown checkpoint is executed at end of recovery - a shutdown checkpoint WAL record is written but the buffer manager had been altered to treat end of recovery as a normal checkpoint. This bug exacerbates the bufmgr relpersistence bug.
Fix bufmgr so CHECKPOINT_END_OF_RECOVERY behaves as a shutdown checkpoint.
Recovery code documents clearly that a shutdown checkpoint is executed at
end of recovery - a shutdown checkpoint WAL record is written but the buffer
manager had been altered to treat end of recovery as a normal checkpoint.
This bug exacerbates the bufmgr relpersistence bug.

Bug spotted by Andres Freund, patch by me.

ashwinstar/gpdb,adam8157/gpdb,ashwinstar/gpdb,jmcatamney/gpdb,oberstet/postgres-xl,ashwinstar/gpdb,ashwinstar/gpdb,xinzweb/gpdb,ovr/postgres-xl,yazun/postgres-xl,adam8157/gpdb,zeroae/postgres-xl,lisakowen/gpdb,adam8157/gpdb,50wu/gpdb,jmcatamney/gpdb,techdragon/Postgres-XL,lisakowen/gpdb,pavanvd/postgres-xl,greenplum-db/gpdb,pavanvd/postgres-xl,xinzweb/gpdb,jmcatamney/gpdb,oberstet/postgres-xl,lisakowen/gpdb,oberstet/postgres-xl,zeroae/postgres-xl,greenplum-db/gpdb,50wu/gpdb,50wu/gpdb,ovr/postgres-xl,jmcatamney/gpdb,adam8157/gpdb,Postgres-XL/Postgres-XL,ovr/postgres-xl,greenplum-db/gpdb,jmcatamney/gpdb,oberstet/postgres-xl,pavanvd/postgres-xl,jmcatamney/gpdb,50wu/gpdb,ashwinstar/gpdb,yazun/postgres-xl,jmcatamney/gpdb,xinzweb/gpdb,lisakowen/gpdb,techdragon/Postgres-XL,lisakowen/gpdb,Postgres-XL/Postgres-XL,techdragon/Postgres-XL,ovr/postgres-xl,Postgres-XL/Postgres-XL,xinzweb/gpdb,Postgres-XL/Postgres-XL,adam8157/gpdb,xinzweb/gpdb,adam8157/gpdb,xinzweb/gpdb,lisakowen/gpdb,greenplum-db/gpdb,lisakowen/gpdb,greenplum-db/gpdb,oberstet/postgres-xl,xinzweb/gpdb,50wu/gpdb,jmcatamney/gpdb,greenplum-db/gpdb,techdragon/Postgres-XL,ashwinstar/gpdb,greenplum-db/gpdb,50wu/gpdb,ovr/postgres-xl,zeroae/postgres-xl,adam8157/gpdb,lisakowen/gpdb,ashwinstar/gpdb,pavanvd/postgres-xl,yazun/postgres-xl,greenplum-db/gpdb,50wu/gpdb,yazun/postgres-xl,ashwinstar/gpdb,adam8157/gpdb,xinzweb/gpdb,pavanvd/postgres-xl,yazun/postgres-xl,zeroae/postgres-xl,zeroae/postgres-xl,techdragon/Postgres-XL,Postgres-XL/Postgres-XL,50wu/gpdb