DRY HNSW procinfo

This commit is contained in:
Andrew Kane
2024-10-09 21:03:18 -07:00
parent 57c05c59a2
commit a98534e5ab
6 changed files with 22 additions and 10 deletions

View File

@@ -685,11 +685,13 @@ HnswInsertTupleOnDisk(Relation index, Datum value, ItemPointer heaptid, bool bui
HnswElement element;
int m;
int efConstruction = HnswGetEfConstruction(index);
FmgrInfo *procinfo = index_getprocinfo(index, 1, HNSW_DISTANCE_PROC);
Oid collation = index->rd_indcollation[0];
FmgrInfo *procinfo;
Oid collation;
LOCKMODE lockmode = ShareLock;
char *base = NULL;
HnswSetProcinfo(index, &procinfo, NULL, &collation);
/*
* Get a shared lock. This allows vacuum to ensure no in-flight inserts
* before repairing graph. Use a page lock so it does not interfere with