public override bool Exists() { var retryCount = 0; while (true) { try { _connection.Open(); _connection.Close(); return(true); } catch (SqlException e) { if (IsDoesNotExist(e)) { return(false); } if (!RetryOnNoProcessOnEndOfPipe(e, ref retryCount)) { throw; } } } }
private bool Exists(bool retryOnNotExists) { var retryCount = 0; while (true) { try { _connection.Open(); _connection.Close(); return(true); } catch (SqlException e) { if (!retryOnNotExists && IsDoesNotExist(e)) { return(false); } if (!RetryOnExistsFailure(e, ref retryCount)) { throw; } } } }