mirror of
https://github.com/postgres/postgres.git
synced 2025-09-02 04:21:28 +03:00
Patch from Massimo Dal Zotto <dz@cs.unitn.it>
The following patches add to the backend a new debugging flag -K which prints a debug trace of all locking operations on user relations (those with oid greater than 20000). The code is compiled only if LOCK_MGR_DEBUG is defined, so the patch should be harmless if not explicitly enabled. I'm using the code to trace deadlock conditions caused by application queries using the command "$POSTMASTER -D $PGDATA -o '-d 1 -K 1'. The patches are for version 6.0 dated 970126.
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
*
|
||||
* Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: lock.h,v 1.3 1996/11/05 06:11:00 scrappy Exp $
|
||||
* $Id: lock.h,v 1.4 1997/02/12 05:25:13 scrappy Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -211,4 +211,8 @@ extern bool LockReleaseAll(LockTableId tableId, SHM_QUEUE *lockQueue);
|
||||
extern int LockShmemSize(void);
|
||||
extern bool LockingDisabled(void);
|
||||
|
||||
#ifdef DEADLOCK_DEBUG
|
||||
extern void DumpLocks(void);
|
||||
#endif
|
||||
|
||||
#endif /* LOCK_H */
|
||||
|
Reference in New Issue
Block a user