6.2.2.1 Refresh kCCFailedLinks and kCCFailedConnections
This task refreshes and reconciles the contents of the kCCFailedLinks and kCCFailedConnections variables.
The KCC updates kCCFailedLinks by inspecting the repsFrom abstract attribute associated with each NC replica on the local DC. It first resets the FailureCount of each tuple in kCCFailedLinks to 0. Then, for each NC replica r, for each tuple rf in r!repsFrom, if rf.consecutiveFailures > 0:
If a tuple f exists in kCCFailedLinks such that f.UUIDDsa = rf.uuidDsa and f.FailureCount ≠ 0:
Set f.FailureCount to MAX(f.FailureCount, rf.consecutiveFailures)
Set f.TimeFirstFailure to MIN(f.TimeFirstFailure, rf.timeLastSuccess)
Set f.LastResult to rf.resultLastAttempt
If a tuple f exists in kCCFailedLinks such that f.UUIDDsa = rf.uuidDsa and f.FailureCount = 0:
Set f.FailureCount to rf.consecutiveFailures
Set f.TimeFirstFailure to rf.timeLastSuccess
Set f.LastResult to rf.resultLastAttempt
If no tuple f exists in kCCFailedLinks such that f.UUIDDsa = rf.uuidDsa, add tuple g to kCCFailedLinks such that:
g.UUIDDsa = rf.uuidDsa
g.FailureCount = rf.consecutiveFailures
g.TimeFirstFailure = rf.timeLastSuccess
g.LastResult = rf.resultLastAttempt
For each tuple k in kCCFailedConnections, the KCC attempts to connect to that DC by calling the IDL_DRSBind method. If the method call is successful, the KCC removes k from kCCFailedConnections. Otherwise, it increments k.FailureCount by 1.