Обсуждение: PGRPROC

Поиск
Список
Период
Сортировка

PGRPROC

От
"Sumaira Ali"
Дата:
<div style="background-color:"><div>if pgproc is used to represent a process and proclock represents a process and its
locksof interest, then why does pgproc contain the following information about locks?</div><div><font color="#008000"
size="2"><p>/*<p>*XLOG location of first XLOG record written by this backend's<p>* current transaction. If backend is
notin a transaction or hasn't<p>* yet modified anything, logRec.xrecoff is zero.<p>*/</font><font
size="2"><p>XLogRecPtrlogRec;<p></font><font color="#008000" size="2">/* Info about LWLock the process is currently
waitingfor, if any. */</font><font size="2"><p></font><font color="#0000ff" size="2">bool</font><font size="2">
lwWaiting;</font><font color="#008000" size="2">/* true if waiting for an LW lock */</font><font
size="2"><p></font><fontcolor="#0000ff" size="2">bool</font><font size="2"> lwExclusive; </font><font color="#008000"
size="2">/*true if waiting for exclusive access */</font><font size="2"><p></font><font color="#0000ff"
size="2">struct</font><fontsize="2"> PGPROC *lwWaitLink; </font><font color="#008000" size="2">/* next waiter for same
LWlock */</font><font size="2"><p></font><font color="#008000" size="2">/* Info about lock the process is currently
waitingfor, if any. */</font><font size="2"><p></font><font color="#008000" size="2">/* waitLock and waitHolder are
NULLif not currently waiting. */</font><font size="2"><p>LOCK *waitLock; </font><font color="#008000" size="2">/* Lock
objectwe're sleeping on ... */</font><font size="2"><p>PROCLOCK *waitHolder; </font><font color="#008000" size="2">/*
Per-holderinfo for awaited lock */</font><font size="2"><p>LOCKMODE waitLockMode; </font><font color="#008000"
size="2">/*type of lock we're waiting for */</font><font size="2"><p>LOCKMASK heldLocks; </font><font color="#008000"
size="2">/*bitmask for lock types already held on <p>* this lock object by this backend */</font><font
size="2"><p>SHM_QUEUEprocHolders; </font><font color="#008000" size="2">/* list of PROCLOCK objects for locks held <p>*
orawaited by this backend */</font><font size="2"><p>};</font></div></div><br clear="all" /><hr />MSN 8 with <a
href="http://g.msn.com/8HMWENUS/2740">e-mailvirus protection service: </a> 2 months FREE* 

Re: PGRPROC

От
Bruce Momjian
Дата:
The proclock is structure links locks and procs, either for locks held,
or procs waiting for locks.

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073