Last edited by:
Kolling on March 10, 1983 6:07 pm
Taft on April 10, 1983 5:25 pm
TransactionActionsImpl:
PROGRAM
IMPORTS AT: OldAlpineTransaction, AlpineTransaction
EXPORTS OldAlpineTransaction =
BEGIN OPEN AE: OldAlpineEnvironment;
OldAlpineTransaction.
Create:
PUBLIC PROC [conversation:
AE.Conversation, createLocalWorker:
BOOL ←
TRUE]
RETURNS [transID:
AE.TransID] ~ {
Work:
PROC ~ {
transID ← AlpineTransaction.Create[conversation, createLocalWorker];
};
DoWork[Work];
};
CreateWorker:
PUBLIC PROC [conversation:
AE.Conversation, transID:
AE.TransID, coordinator:
AE.FileStore] ~ {
Work:
PROC ~ {
AlpineTransaction.CreateWorker[conversation, transID, coordinator];
};
DoWork[Work];
};
AssertAlpineWheel:
PUBLIC
PROCEDURE[conversation:
AE.Conversation, transID:
AE.TransID, enable:
BOOLEAN] =
BEGIN
Work:
PROC ~ {
AlpineTransaction.AssertAlpineWheel[conversation, transID, enable];
};
DoWork[Work];
END;
Finish:
PUBLIC
PROCEDURE[conversation:
AE.Conversation, transID:
AE.TransID, requestedOutcome:
AT.RequestedOutcome, continue:
BOOL ←
FALSE]
RETURNS [outcome:
AE.Outcome, newTrans:
AE.TransID] =
BEGIN
Work:
PROC ~ {
[outcome, newTrans] ← AlpineTransaction.Finish[conversation, transID, requestedOutcome, continue];
};
DoWork[Work];
END;
DoWork:
PROC [work:
PROC]
RETURNS [] ~ {
operationReason: OldAlpineEnvironment.OperationFailure;
unknownWhat: OldAlpineEnvironment.UnknownType;
{
ENABLE {
AlpineTransaction.OperationFailed => {operationReason ← why; GOTO operationFailed};
AlpineTransaction.Unknown => {unknownWhat ← what; GOTO unknown};
};
work[];
EXITS
operationFailed => ERROR AT.OperationFailed[operationReason];
unknown => ERROR AT.Unknown[unknownWhat];
};
};
END.
CHANGE LOG
Edited on July 25, 1984 9:31:01 am PDT, by Kupfer
Add SkiPatrolLog probe.
changes to: DIRECTORY, MiscActionsImpl, AssertAlpineWheel
Edited on July 27, 1984 3:19:07 pm PDT, by Kupfer
Let the probe routine get the user RName from the transaction ID.
changes to: AssertAlpineWheel, DIRECTORY, MiscActionsImpl
Edited on August 6, 1984 3:33:38 pm PDT, by Kupfer
Remove the possible race condition in SkiPatrolLog probes by assigning the PROC to a temporary variable.
changes to: DIRECTORY, AssertAlpineWheel