mirror of
https://github.com/postgres/postgres.git
synced 2025-11-18 02:02:55 +03:00
Cross-check lists of built-in LWLock tranches.
lwlock.c, lwlock.h, and wait_event_names.txt each contain a list of
built-in LWLock tranches. It is easy to miss one or the other when
adding or removing tranches, and discrepancies have adverse effects
(e.g., breaking JOINs between pg_stat_activity and pg_wait_events).
This commit moves the lists of built-in tranches in lwlock.{c,h} to
lwlocklist.h and adds a cross-check to the script that generates
lwlocknames.h. If the lists do not match exactly, building will
fail.
Author: Bertrand Drouvot <bertranddrouvot.pg@gmail.com>
Reviewed-by: Michael Paquier <michael@paquier.xyz>
Discussion: https://postgr.es/m/aHpOgwuFQfcFMZ/B%40ip-10-97-1-34.eu-west-3.compute.internal
This commit is contained in:
@@ -356,9 +356,13 @@ AioWorkerSubmissionQueue "Waiting to access AIO worker submission queue."
|
||||
#
|
||||
# END OF PREDEFINED LWLOCKS (DO NOT CHANGE THIS LINE)
|
||||
#
|
||||
# Predefined LWLocks (i.e., those declared in lwlocknames.h) must be listed
|
||||
# in the section above and must be listed in the same order as in
|
||||
# lwlocknames.h. Other LWLocks must be listed in the section below.
|
||||
# Predefined LWLocks (i.e., those declared at the top of lwlocknames.h) must be
|
||||
# listed in the section above and must be listed in the same order as in
|
||||
# lwlocknames.h.
|
||||
#
|
||||
# Likewise, the built-in LWLock tranches (i.e., those declared at the bottom of
|
||||
# lwlocknames.h) must be listed in the section below and must be listed in the
|
||||
# same order as in lwlocknames.h.
|
||||
#
|
||||
|
||||
XactBuffer "Waiting for I/O on a transaction status SLRU buffer."
|
||||
|
||||
Reference in New Issue
Block a user