LocalRegistryAgent.mesa
Copyright Ó 1990, 1991 by Xerox Corporation. All rights reserved.
Spreitze, May 27, 1992 7:22 am PDT
DIRECTORY Atom, Rope;
LocalRegistryAgent: CEDAR DEFINITIONS ~ {
ROPE: TYPE ~ Rope.ROPE;
Milliseconds: TYPE ~ INT;
PropList: TYPE ~ Atom.PropList; --each key is an ATOM, each val is a ROPE
ServiceRegistration: TYPE ~ REF ServiceRegistrationPrivate;
ServiceRegistrationPrivate: TYPE;
MaintainService:
PROC [name:
ROPE, value: PropList, regTimeout, regPeriod: Milliseconds]
RETURNS [ServiceRegistration];
Every regPeriod, the registration is refreshed with msToLive=regTimeout --- from a forked process.
ChangeProps:
PROC [sr: ServiceRegistration, newValue: PropList];
Changes the property list of this registration.
StopService:
PROC [ServiceRegistration];
Retracts the registration. Idempotent.
}.