Lessor

Undocumented in source.

Constructors

this
this(int64 ttl, long interval)
Undocumented in source.

Members

Functions

Attach
string Attach(LeaseID id, LeaseItem[] items)
Undocumented in source. Be warned that the author may not have intended to support it.
Checkpoint
string Checkpoint(LeaseID id, int64 remainingTTL)
Undocumented in source. Be warned that the author may not have intended to support it.
Demote
void Demote()
Undocumented in source. Be warned that the author may not have intended to support it.
Detach
string Detach(LeaseID id, LeaseItem[] items)
Undocumented in source. Be warned that the author may not have intended to support it.
GetLease
LeaseID GetLease(LeaseItem item)
Undocumented in source. Be warned that the author may not have intended to support it.
Grant
Lease Grant(LeaseID id, int64 ttl)
Undocumented in source. Be warned that the author may not have intended to support it.
Leases
Lease[] Leases()
Undocumented in source. Be warned that the author may not have intended to support it.
Lookup
Lease Lookup(LeaseID id)
Undocumented in source. Be warned that the author may not have intended to support it.
Promote
void Promote(long extend)
Undocumented in source. Be warned that the author may not have intended to support it.
Recover
void Recover(RangeDeleter rd)
Undocumented in source. Be warned that the author may not have intended to support it.
Renew
int64 Renew(LeaseID id)
Undocumented in source. Be warned that the author may not have intended to support it.
Revoke
string Revoke(LeaseID id)
Undocumented in source. Be warned that the author may not have intended to support it.
SetCheckpointer
void SetCheckpointer(Checkpointer cp)
Undocumented in source. Be warned that the author may not have intended to support it.
SetRangeDeleter
void SetRangeDeleter(RangeDeleter rd)
Undocumented in source. Be warned that the author may not have intended to support it.
checkpointScheduledLeases
void checkpointScheduledLeases()
Undocumented in source. Be warned that the author may not have intended to support it.
clearScheduledLeasesCheckpoints
void clearScheduledLeasesCheckpoints()
Undocumented in source. Be warned that the author may not have intended to support it.
expireExists
Tuple!(Lease, bool, bool) expireExists()
Undocumented in source. Be warned that the author may not have intended to support it.
findDueScheduledCheckpoints
LeaseCheckpoint[] findDueScheduledCheckpoints(int checkpointLimit)
Undocumented in source. Be warned that the author may not have intended to support it.
findExpiredLeases
Lease[] findExpiredLeases(int limit)
Undocumented in source. Be warned that the author may not have intended to support it.
init
void init(Lease l)
Undocumented in source. Be warned that the author may not have intended to support it.
initAndRecover
void initAndRecover()
Undocumented in source. Be warned that the author may not have intended to support it.
isPrimary
bool isPrimary()
Undocumented in source. Be warned that the author may not have intended to support it.
revokeExpiredLeases
void revokeExpiredLeases()
Undocumented in source. Be warned that the author may not have intended to support it.
runLoop
void runLoop()
Undocumented in source. Be warned that the author may not have intended to support it.
scheduleCheckpointIfNeeded
void scheduleCheckpointIfNeeded(Lease lease)
Undocumented in source. Be warned that the author may not have intended to support it.
unsafeLeases
Lease[] unsafeLeases()
Undocumented in source. Be warned that the author may not have intended to support it.

Variables

_isPrimary
bool _isPrimary;
Undocumented in source.
_mutex
Mutex _mutex;
Undocumented in source.
checkpointInterval
long checkpointInterval;
Undocumented in source.
cp
Checkpointer cp;
Undocumented in source.
itemMap
LeaseID[LeaseItem] itemMap;
Undocumented in source.
leaseCheckpointHeap
Heap!LeaseQueue leaseCheckpointHeap;
Undocumented in source.
leaseHeap
Heap!LeaseQueue leaseHeap;
Undocumented in source.
leaseMap
Lease[LeaseID] leaseMap;
Undocumented in source.
minLeaseTTL
int64 minLeaseTTL;
Undocumented in source.
rd
RangeDeleter rd;
Undocumented in source.

Meta