DIRECTORY YggEnvironment, YggInternal, YggDummyProcess; YggLockControl: CEDAR DEFINITIONS = BEGIN Initialize: PROC [lockZoneInitialSize: INT, hashArraySize: NAT]; ForkWatchdogProcess: PROC [ wakeupPeriod: YggDummyProcess.Milliseconds, abortWaitingRequestInterval: INT--seconds--, abortInactiveGrantedRequestInterval: INT--seconds--]; ConsTransHeader: PROC [trans: YggInternal.TransHandle] RETURNS [lockHeader: YggInternal.LockTransHeader]; AbortWaitingRequests: PROC [trans: YggInternal.TransHandle]; UpgradeLocks: PROC [trans: YggInternal.TransHandle]; ReleaseLocks: PROC [trans: YggInternal.TransHandle]; TransferLocks: PROC [from, to: YggInternal.TransHandle]; END. 2YggLockControl.mesa Copyright Ó 1985, 1988 by Xerox Corporation. All rights reserved. Last edited by MBrown on January 24, 1983 4:30 pm Hauser, March 8, 1985 10:40:03 am PST Bob Hagmann May 3, 1988 10:00:03 am PDT LockWatchdogProcess will wake up every wakeupPeriod milliseconds. It will abort any transaction with a waiting lock request older than abortWaitingRequestInterval seconds. It will abort any transaction T that has had no activity for the past abortInactiveGrantedRequestInterval seconds, if T holds a lock that blocks the progress of another transaction. ! (None) Cause all waiting lock requests for trans to fail, raising Lock.TransAborting. ! Lock.Failed[timeout], Lock.TransAborting For all update (intendUpdate, ...) locks l held in trans, convert l to a write (intendWrite, ...) lock. Must not call with lock requests waiting. ! (None) For all locks l held in trans, release l. Must not call with lock requests waiting. ! (None) Make "from"'s lock structure reference "to", instead. Hauser, March 8, 1985 10:39:43 am PST Nodified, added copyright. Ê®˜šœ™IcodešœB™B—šœ™Jšœ"™"K™%K™'—J˜šÏk ˜ Jšœ˜Jšœ ˜ Jšœ˜J˜J˜—Jšœœ˜)˜JšÏn œœœœ˜@J˜šžœœ˜Jšœ+˜+JšœÏc œ˜,Jšœ%Ÿ œ˜5JšœA™AJšœD™DJšœ$™$JšœE™EJšœC™CJšœ+™+J˜—šžœœ!˜6Jšœ+˜2J˜—šžœœ"˜