ServerXMLHTTP Server timesout with db connection

Discussion in 'Classic ASP' started by rsmith720, May 17, 2009.

Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.
  1. We have an ASP application built which processes requests for xml output. When requests are sent remotely from another server it processes fine, but we also have included a "sand box" of sorts for user testing in the same virtual directory as the xml response page. Whenever requests are sent from this sand box process the request times out. We tested this on our local development servers and don't experience the same results. After systematically working through the code step by step we found that when a connection is made to the sql database on DASP it causes the process to timeout when using the local sand box process but not when requests are made remotely. The same exact db connection works fine in live mode as well as on our development servers for both cases. We are confused as to why this would be happening on the DASP site, and only when there is a call made to the process from the same directory, unless there is some specific setting DASP uses that might be causing this. If anyone can offer us some insight into this would be most appreciated.
     
  2. I'm assuming that you are trapping the error that your sandbox is generating when it tries to connect to the SQL server. Can you give us a full copy of that error?
     
  3. Requested error

    Sorry for the delay, I was traveling and just returned to the office.
    I checked to see if any errors could be trapped at the point of connection, but no errors are being thrown, it is just timing out.

    Thanks-
     
  4. Here's the connection string we are using per the suggestion for SQL 2005 which differs slightly on the "data source" parameter from what we've used in the past for SQL 2000 databases.

    "Provider=SQLOLEDB;Data Source=tcp:sql2k502.discountasp.net;Initial Catalog=SQL2005_xxxxx_xxxxx;User ID=SQL2005_xxxxx_xxxx_xxxx;Password=xxxxxxxx;"
     
  5. What is the error message you are getting that is notifying you that the connection to the SQL server is timing out?
     
  6. The timeout is occuring at the ServerXMLHTTP connection and only times out when there is an attempt to connect to the database. I don't believe any message is being thrown by SQL Server at least at the page level. The DASP server logs may indicate something, but we don't have access to those?

    As stated, this timeout only happens when the process is accessed from the same virtual directory. If I submit requests from another server to the same exact process, it doesn't timeout. And if we test this from our local development environment, we don't experience any latency when it connects to the database, even from the same directory.
     
  7. Bruce

    Bruce DiscountASP.NET Staff

    I have a feeling that this is related to the asp threading model setting.

    Please open a support ticket and ask to switch your site's ASP setting to single apartment thread.
     
Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.

Share This Page