Exemple #1
0
 private void RecordAttemptFailure(ConnectionState state, Exception ex)
 {
     if (Attempts.Any())
     {
         var attempt = Attempts.Last();
         attempt.FailedStates.Add(new AttemptFailedState(state, ex));
     }
 }
Exemple #2
0
 public void RecordAttemptFailure(ConnectionState state, Exception ex)
 {
     lock (_syncLock)
     {
         if (Attempts.Any())
         {
             var attempt = Attempts.Last();
             attempt.FailedStates.Add(new AttemptFailedState(state, ex));
         }
     }
 }