I have following connection string:
metadata=res:///Database.csdl|res:///Database.ssdl|res://*/Database.msl;provider=System.Data.SqlClient;provider connection string="Data Source=.\SQLEXPRESS;AttachDbFilename='Database.mdf';Integrated Security=True;User Instance=True;Connection Timeout=300;"
I expect that this connection string can never get timeout (because it is 5 mins). However, on a very easy database.table.Count() call to Entity Framework it fails in 10 seconds with "Timeout" exception. Why does Entity Framework ignores SQL timeout? How to set timeout for Entity Framework?