mirror of
https://gitee.com/he3db/he3pg.git
synced 2024-11-29 18:58:35 +08:00
!182 fix #I7DRYV
Merge pull request !182 from shipixian/dev_performance
This commit is contained in:
commit
921e276375
@ -91,6 +91,7 @@
|
||||
#include "access/xlog.h"
|
||||
#include "miscadmin.h"
|
||||
#include "port/pg_bitutils.h"
|
||||
#include "postmaster/secondbuffer.h"
|
||||
#include "storage/bufmgr.h"
|
||||
#include "storage/lmgr.h"
|
||||
#include "storage/smgr.h"
|
||||
@ -656,6 +657,18 @@ vm_extend(Relation rel, BlockNumber vm_nblocks)
|
||||
|
||||
smgrextend(rel->rd_smgr, VISIBILITYMAP_FORKNUM, vm_nblocks_now,
|
||||
pg.data, false);
|
||||
if (!(InitdbSingle || IsBootstrapProcessingMode() == true) && !push_standby && !he3mirror)
|
||||
{
|
||||
PageKey pageKey;
|
||||
pageKey.relfileNode.dbNode = rel->rd_smgr->smgr_rnode.node.dbNode;
|
||||
pageKey.relfileNode.relNode = rel->rd_smgr->smgr_rnode.node.relNode;
|
||||
|
||||
pageKey.blkNo = vm_nblocks_now;
|
||||
pageKey.forkNo = VISIBILITYMAP_FORKNUM;
|
||||
pageKey.pageLsn = 0;
|
||||
|
||||
ReceivePageFromDataBuffer(&pageKey, (uint8_t *) pg.data);
|
||||
}
|
||||
vm_nblocks_now++;
|
||||
}
|
||||
|
||||
|
@ -30,6 +30,7 @@
|
||||
#include "storage/fsm_internals.h"
|
||||
#include "storage/lmgr.h"
|
||||
#include "storage/smgr.h"
|
||||
#include "postmaster/secondbuffer.h"
|
||||
|
||||
|
||||
/*
|
||||
@ -641,6 +642,18 @@ fsm_extend(Relation rel, BlockNumber fsm_nblocks)
|
||||
|
||||
smgrextend(rel->rd_smgr, FSM_FORKNUM, fsm_nblocks_now,
|
||||
pg.data, false);
|
||||
if (!(InitdbSingle || IsBootstrapProcessingMode() == true) && !push_standby && !he3mirror)
|
||||
{
|
||||
PageKey pageKey;
|
||||
pageKey.relfileNode.dbNode = rel->rd_smgr->smgr_rnode.node.dbNode;
|
||||
pageKey.relfileNode.relNode = rel->rd_smgr->smgr_rnode.node.relNode;
|
||||
|
||||
pageKey.blkNo = fsm_nblocks_now;
|
||||
pageKey.forkNo = FSM_FORKNUM;
|
||||
pageKey.pageLsn = 0;
|
||||
|
||||
ReceivePageFromDataBuffer(&pageKey, (uint8_t *) pg.data);
|
||||
}
|
||||
fsm_nblocks_now++;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user