[EF] Connection resiliency

- connection retry policy
- works great with async
- four modes
    - DefaultExcutionStrategy
    - DefaultSqlExecutionStrategy
    - DbExecutionStrategy
    - SqlAzureExecutionStrategy
- throws RetryLimitExceededException

##Configuration

1
2
3
4
5
6
7
8
public class MyConfiguration : DbConfiguration 
{
public MyConfiguration()
{
SetExecutionStrategy("System.Data.SqlClient",
() => new SqlAzureExecutionStrategy(1, TimeSpan.FromSeconds(30)));
}
}

MSDB

參考網址