database - TimeoutExpired when using EF6 MainContextDropInitializer on SQL Azure -


i have database on sql azure, when run automated unit tests try drop db , recreate it.

the constructor context is:

public maincontext(bool dropdb)             : base("main")         {              database.commandtimeout = 300;             this.configuration.lazyloadingenabled = true;             system.data.entity.database.setinitializer<maincontext>(new maincontextdropinitializer());              this.database.connection.statechange += connection_statechange;         } 

however when trying execute code keep getting following error:

timeout expired. timeout period elapsed prior completion of operation or server not responding.

the db quite small setting command timeout of 300 should sufficient. interestingly issue occurred since upgrade azure db v12.

any ideas?

have had @ doc https://msdn.microsoft.com/en-us/data/dn456835.aspx? talks how can use sqlazure execution strategy transient fault handling , retries.


Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -