YggSRProcsImpl.mesa
Copyright Ó 1988 by Xerox Corporation. All rights reserved.
Bob Hagmann November 1, 1988 7:50:01 am PST
Exported procedures (with X after the name)
SRRestoreObjectX:
PUBLIC
PROC [sPort: Mach.portT, optr: Camelot.optrT, value: Mach.pointerT, valueCnt:
CARD] ~ {
SRRestoreObject[sPort, optr, value, valueCnt];
};
SRRestoreBatchX:
PUBLIC
PROC [sPort: Mach.portT, dataPtr: Mach.pointerT, dataPtrCnt:
CARD] ~ {
SRRestoreBatch [sPort: sPort, dataPtr: dataPtr, dataPtrCnt: dataPtrCnt];
};
SRRePrepareX:
PUBLIC
PROC [sPort: Mach.portT, btid: Camelot.btidT, prepareData: Mach.pointerT, prepareDataCnt:
CARD] ~ {
SRRePrepare[sPort: sPort, btid: btid, prepareData: prepareData, prepareDataCnt: prepareDataCnt];
};
SRRecoveryCompleteX:
PUBLIC
PROC [sPort: Mach.portT] ~ {
SRRecoveryComplete[sPort];
};
Global (but not exported!) procedures
SRRestoreObject:
PROC [sPort: Mach.portT, optr: Camelot.optrT, value: Mach.pointerT, valueCnt:
CARD] ~ {
Global name is SR←RestoreObject.
Recovery of an object. The server must pin and update the object.
YggBuffMan.WriteBytes[optr: optr, value: LOOPHOLE[value], valueCnt: valueCnt];
};
SRRestoreBatch:
PROC [sPort: Mach.portT, dataPtr: Mach.pointerT, dataPtrCnt:
CARD] ~ {
Global name is SR←RestoreBatch.
dataPtr points to a bunch of [optr←t, u←int, char[...]] triples that are just like a bunch of SR←RestoreObject calls
restoreBlock: TYPE = RECORD[
optr: Camelot.optrT,
value: Mach.pointerT,
valueCnt: CARD
];
nowDataPtr: LONG POINTER TO restoreBlock ← LOOPHOLE[dataPtr];
FOR counter:
CARD
IN [0..dataPtrCnt)
DO
TRUSTED {SRRestoreObject[sPort, nowDataPtr.optr, nowDataPtr.value, nowDataPtr.valueCnt]; };
nowDataPtr ← nowDataPtr + UNITS[restoreBlock];
ENDLOOP;
};
SRRePrepare:
PROC [sPort: Mach.portT, btid: Camelot.btidT, prepareData: Mach.pointerT, prepareDataCnt: CARD] ~ {
Global name is SR←RePrepare.
RePrepare the transaction. Used after data server restart to rebuild lock tables.
ERROR;
};
SRRecoveryComplete:
PROC [sPort: Mach.portT] ~ {
Global name is SR←RecoveryComplete.
All done (with recovery).
YggdrasilInit.RecoveryComplete[];
};