Timeout expired. 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.
This situation occurs when Sitecore receives many requests in a second.
In this situation, you have two options:
Add Max Pool Size in ConnectionStrings.config file
Generally, you will add max pool size in the config file using patching.
You just need to go to the app config, find the connection string file, and add max pool size in the core and master config.
Add
Max Pool Size = {Count of pool size}
that you will set in the core or master database.<add name="core" connectionString="Data Source=YOURDATASOURCE;Initial Catalog=YOURCATALOG;User ID=USERNAME;Password=PASSWORD;Max Pool Size=200;"" />
Restart Sitecore instance
This is a temporary solution for someone who is getting this error in a local instance and is not sending many requests to the Sitecore instance.
Follow the steps below:
Press Windows+R to run the command.
Type
services.msc
and press Enter.
It will redirect you to the Microsoft Management Console. Find SQL-related services and restart them.
You will find that similar to the above, restarting SQL Server can also resolve the pool size error temporarily.
Note: You might encounter this error again. It is important to identify which process is sending so many requests.
For more information, you can refer to Sitecore Stack Exchange and Sitecore documentation.