Search Postgresql Archives

Difficult while acquiring LWLocks

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all
   There is an use case, where i want some 10 LightWeight Locks and after 9.6 LW locks api's (LWLockAssign) are changed a bit and i am confused too.

 Only reference i cant get was from pg_stat_statement :(

Since GetNamedLWLockTranche method will return the base address of the specified tranche.

From pg_init
" RequestNamedLWLockTranche("Some_10_LWLocks", 10); "


For getting those locks which were requested from pg_init
" LWLockPadded *lwLockPadded = GetNamedLWLockTranche("Some_10_LWLocks");
   LWLock *lock = &(lwLockPadded[index in 0 to 9]).lock; "


Is the above code snippet a valid for requesting some 10 LWLocks?


TIA
 harry

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux