Skip to main content
Participant
April 24, 2006
Answered

CFHTTP

  • April 24, 2006
  • 8 replies
  • 1271 views
Okay I will describe our problem.

We are running CF 6.1 and IIS 6 on server 2003.

We have a service that people post to and get a response. In the script we have a CFHTTP call to a remote URL. If the CFHTTP takes longer than 18 seconds which can happen IIS seems to lose site of the CFHTTP. The web browser does nothing. It literally just sits there.

So what we have been doing is setting the timeout value on the CFHTTP to 17 seconds to prevent this hang.

We thought maybe it was a CF problem so to rule it out we wrote an ISAPI filter that has nothing to do with cold fusion where you can pass in the time to sleep.

Here is the URL to the script that calls the dll. Pass in time is in miliseconds so 18 seconds will be 18000. Try it for 18000 then 19000 and you will see the effect.

http://mercury.velocitygroup.co.uk/sleepTestPost2.htm

So as it is calling a dll cold fusion does not appear to be the problem

We cannot work out where this arbitrary 18 seconds is coming from. We need our CFHTTP to last for 31 seconds. Does anyone know where this 18 seconds is coming from and how to change it.
    This topic is closed to new replies. Start a new post to keep the conversation going.
    Correct answer VelocityPay
    Beware of ISAPI extensions. Assuming you intend to use the IIS server exclusively for ColdFusion, it is the recommended practice to disable all other Web Service Extensions in the IIS Manager, with the exception of Macromedia Server Extensions.

    I agree with Mr Black's point about script timeouts relating only to ASP files. However, ISAPI-induced timeout effects are usually not that straightforward. As far as IIS is concerned, ColdFusion's functionality is on a par with that of the next ISAPI application. IIS forwards CFM, CFC, CFR, etc. requests to the appropriate Coldfusion DLL for processing. The server DLL sends the result back to IIS, which in turn sends it to the client as the response to the client's request. Any ISAPI filter that can disrupt the global timeout settings of the IIS server can therefore affect the performance of CFM pages, albeit indirectly.



    Thanks all we have worked out what the problem is.

    Our office broadband box firewall closes connection at 18 seconds. So in actual fact there had never been a problem on the production system. So we had invented a solution to problem that never existed. It just appeared to exist. No magical setting missing.

    This one was driving us crazy and it was only random luck we picked up on it.

    Thanks all for your help and input.

    Thread Closed

    8 replies

    BKBK
    Community Expert
    Community Expert
    April 24, 2006
    First, if you're using the IIS server exclusively for ColdFusion, then it is advisable to disable all other Web Service Extensions in the IIS Manager, with the exception of Macromedia Server Extensions. Second, have you verified that the value of the default timeout value for scripts in IIS isn't too low? To find the setting, open the IIS snap-in, right-click on the website, and follow Home Directory => Configuration => Options.

    Participant
    April 24, 2006
    i think I am being a bit slow.

    I opened up the snap in for IIS. Right clicked on the website in question. Selected properties -> Home Directory -> Configuration -> Options and this is what I have set

    Application configuration

    Enable session state - Checked and set to 20 min
    Enable buffering checked

    ASP script timeout - > Set to 90 seconds.

    There is no option to configure other script timeouts. as far as i can tell

    BKBK
    Community Expert
    Community Expert
    April 24, 2006
    Have you verified that there is no variable named URL.RequestTime, set, for example, in a cfparam tag? And also that the timeout value in the Coldfusion Administrator is high enough?