RequestAddinLWLocks(int n) - Mailing list pgsql-hackers

From Jesper Pedersen
Subject RequestAddinLWLocks(int n)
Date
Msg-id 55BB9AA4.6090101@redhat.com
Whole thread Raw
Responses Re: RequestAddinLWLocks(int n)
List pgsql-hackers
Hi,

Currently

   Max(lock_addin_request, NUM_USER_DEFINED_LWLOCKS);

LWLock's are added during startup for extensions.

However, this presents a problem if an extension doesn't specify the
correct number of LWLock's needed, if the total number is <= 4.

The attached patch requires extensions to specify the correct number of
LWLock's needed. This change will break extensions that specifies an
incorrect number, but makes it easier to debug which extension which is
at fault.

Probably too big a change though. Maybe a patch against xfunc.sgml is
better ?

Best regards,
   Jesper


Attachment

pgsql-hackers by date:

Previous
From: Simon Riggs
Date:
Subject: Re: brin index vacuum versus transaction snapshots
Next
From: Jeff Janes
Date:
Subject: Re: LWLock deadlock and gdb advice