Timeout Expiry Problem: Need feedback urgently

  • Thread starter Thread starter Mithun Verma
  • Start date Start date
M

Mithun Verma

Hello All,
We have a windows application(24*7) that has timer running on the form. The
timer interval is set at 30 seconds. On every timer tick, a method is
called that executes a stored procedure. On execution of the stored
procedure, certain tables are updated, that causes triggers on the tables to
run. These triggers are in turn executing a stored procedure and so on
resulting in a lot of database activity. We do not have control on the
database(tables, triggers etc cannot be modified by us).
After running a single instance of this application for about 8-9 hours, the
following error was received:

12/1/2003 10:31:57 PM frmSCAllOperations tmr_Tick Error: Error at
IMD.OM.SC.SCStatus.StartNSCMonitor(SqlConnection commonConnection)
at IMDSupportCenter.SC.frmSCAllOperations.tmr_Tick(Object sender,
EventArgs e)System.Exception ---> System.Data.SqlClient.SqlException:
Timeout expired. The timeout period elapsed prior to completion of the
operation or the server is not responding.
at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior
cmdBehavior, RunBehavior runBehavior, Boolean returnStream)
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at IMD.OM.Database.SqlUtility.Execute(SqlParameter& prmOutParam,
SqlConnection cnnCommon)
--- End of inner exception stack trace ---
at IMD.OM.Database.SqlUtility.Execute(SqlParameter& prmOutParam,
SqlConnection cnnCommon)
at IMD.OM.SC.SCStatus.StartNSCMonitor(SqlConnection commonConnection)
I am not sure as to what could be the cause of this problem??

I am thinking of the following option:
Increasing the interval of the timer so that we ping the database at a
lower rate?

Can someone suggest a solution to the above problem or provide valuable
tips/new approaches to counter this problem.

I need to solve this problem ASAP. Please reply ASAP.

Thanks and Regards.
Mithun
 
Hi Mithun,

Sounds to me like you should increase
SqlCommand.CommandTimeout value (the default is 30s) rather then timer
interval.
You might also increase timer interval if the above is true.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top