Tuesday, January 7, 2014

The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.|

if you obtain this error then you are using max pool size that is being connected with sqlserver. so you have to enable the  Pooling and increase the Max Pool Size which is by default 100.

Eg:-
   <add name="Connection String" connectionString="server=192.168.8.2;uid=sa;pwd=P@ssw0rd;database=SchoolTest;Pooling=true;Max Pool Size=2500;Connect Timeout=50;TrustServerCertificate = true" providerName="System.Data.SqlClient" />