Nop 4.6.0.6 Time-out error

1 周 前
Hi,
I have updated our nop site to last version 4.6.06 and inserted 1 million of producuts in our store.
Daily we receive hundreds of errore like this:

Microsoft.Data.SqlClient.SqlException (0x80131904): Execution Timeout Expired.  The timeout period elapsed prior to completion of the operation or the server is not responding.

That coming from only 2 pages:

https://www.website.it/instantSearchFor?
and
https://www.website.it/search?

I can image that 1 million is an high number of records not for SQL Server .. but for nop? Dedicated server with SQL Server 2016 has 4 CPU and 16 GByte.

I discovered that timeout is 30 seconds but update the connection string  adding ConnectTimeout=60 not produce any improvements of time; I will try to increase the command timeout but I'am not sure it is the best solution..

Any other suggestion to solve this bad issue?

Thanks in advance

BR
Massimo
1 周 前
Using Extended Events is the recommended method for monitoring query timeouts in SQL Server...

To set up Extended Events in SQL Server Management Studio (SSMS):

Open SSMS and connect to the SQL Server instance.
Navigate to the "Management" folder.
Expand "Extended Events" and right-click on "Sessions".
Select "New Session Wizard" to create a new Extended Events session.
Follow the wizard to define events, filters, and actions based on your monitoring requirements.
Start the session to begin capturing Extended Events data.
Analyze the captured data to troubleshoot performance issues or monitor specific events.

When you get the offending query, you can get recommended indexes to set up by using SQL Server's built-in tuning advisor, accessed through SSMS.
https://learn.microsoft.com/en-us/sql/relational-databases/performance/start-and-use-the-database-engine-tuning-advisor?view=sql-server-ver16
1 周 前
Good suggestion, thanks! In this moment with SQL Command timeout increased we have not more timeout error but I am not sure it is the best way to solve the issue, for server point of view.
I will follow your suggestion, thanks!