mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-14 18:37:03 +08:00
As introduced by f9900df5f94, a REINDEX CONCURRENTLY job done for an index with predicates or expressions would set PROC_IN_SAFE_IC in its MyProc->statusFlags, causing it to be ignored by other concurrent operations. Such concurrent index rebuilds should never be ignored, as a predicate or an expression could call a user-defined function that accesses a different table than the table where the index is rebuilt. A test that uses injection points is added, backpatched down to 17. Michail has proposed a different test, but I have added something simpler with more coverage. Oversight in f9900df5f949. Author: Michail Nikolaev Discussion: https://postgr.es/m/CANtu0oj9A3kZVduFTG0vrmGnKB+DCHgEpzOp0qAyOgmks84j0w@mail.gmail.com Backpatch-through: 14
47 lines
1.2 KiB
Makefile
47 lines
1.2 KiB
Makefile
# src/test/modules/injection_points/Makefile
|
|
|
|
MODULE_big = injection_points
|
|
OBJS = \
|
|
$(WIN32RES) \
|
|
injection_points.o \
|
|
injection_stats.o \
|
|
injection_stats_fixed.o
|
|
EXTENSION = injection_points
|
|
DATA = injection_points--1.0.sql
|
|
PGFILEDESC = "injection_points - facility for injection points"
|
|
|
|
REGRESS = injection_points reindex_conc
|
|
REGRESS_OPTS = --dlpath=$(top_builddir)/src/test/regress
|
|
|
|
ISOLATION = inplace
|
|
|
|
TAP_TESTS = 1
|
|
|
|
# The injection points are cluster-wide, so disable installcheck
|
|
NO_INSTALLCHECK = 1
|
|
|
|
export enable_injection_points
|
|
|
|
ifdef USE_PGXS
|
|
PG_CONFIG = pg_config
|
|
PGXS := $(shell $(PG_CONFIG) --pgxs)
|
|
include $(PGXS)
|
|
else
|
|
subdir = src/test/modules/injection_points
|
|
top_builddir = ../../../..
|
|
include $(top_builddir)/src/Makefile.global
|
|
|
|
# XXX: This test is conditional on enable_injection_points in the
|
|
# parent Makefile, so we should never get here in the first place if
|
|
# injection points are not enabled. But the buildfarm 'misc-check'
|
|
# step doesn't pay attention to the if-condition in the parent
|
|
# Makefile. To work around that, disable running the test here too.
|
|
ifeq ($(enable_injection_points),yes)
|
|
include $(top_srcdir)/contrib/contrib-global.mk
|
|
else
|
|
check:
|
|
@echo "injection points are disabled in this build"
|
|
endif
|
|
|
|
endif
|