Too long to respond.

Last night when I was testing a web app locally, the app displayed in the Chrome browser suddenly went to a message saying page cant be displayed… took too long to respond. Not sure what suddenly is causing this problem. It’s happening everytime I run the program and let it sit for a few seconds. Ive tried restarting, rebooting the computer. I didnt change anything in the programming that would cause this that I know of. Anyone else have this problem?? How can I get past it?
Thanks.

  • look at what you did prior to this behavior happening. There is a good chance that your program goes into an infinite loop and therefore becomes unresponsive. Or plain and simple crashed. If you know for example that this happens after closing a particular page, you can pinpoint the faulty code easier.

If nothing obvious can be identified, then perhaps start logging every step of the program (system.debuglog), with clear messages telling you where the program is at and what it is doing. You may find that everything stops after a specific message. that will also help you pinpoint the problem. Or, the same message happens over and over again. In this lucky event, you have your loop!

  • check whether the program runs when that happens. Did some condition make it close (not necessarily crash) the same strategy as above can help here also.

Ok so this is what happens when it crashes… I guess I haven’t seen it crash yet… lol. Ive only been programming web apps for a few weeks now so Im pretty new to it. I’ll do some tracing an figure it out! Thank you.

Check the open event of the app class you have a loop or method call that has a loop?

Probably stupid to ask but… have you tested using different browsers?

A couple of weeks ago I had a similar problem and was banging my head against the wall, it then occured to me to test the web app using Firefox and Safari, found out that Firefox and Safari were displaying the app correctly. For some strange reason Chrome started using up to 300% CPU and web developer tools was logging some seriously bad and misterious network calls, loading the app with it as impossible. I had to completely wipe out Chrome from my macbook, did a complete reinstall and everything is back to normal.

[quote=479558:@Hector Marroquin]Probably stupid to ask but… have you tested using different browsers?

A couple of weeks ago I had a similar problem and was banging my head against the wall, it then occured to me to test the web app using Firefox and Safari, found out that Firefox and Safari were displaying the app correctly. For some strange reason Chrome started using up to 300% CPU and web developer tools was logging some seriously bad and misterious network calls, loading the app with it as impossible. I had to completely wipe out Chrome from my macbook, did a complete reinstall and everything is back to normal.[/quote]

Here is what ended up being the problem:

#If Not DebugBuild Then If Not Session.Secure Then Dim host As String = Session.Header("Host") Dim url As String = "https://" + host ShowURL(url) End If #EndIf

I put the debug statements in to stop the problem. When this is on the webserver I want it to go secure. But it was trying to force this when running locally. When it couldn’t, it was shutting it down. Added in the debug statements and it fixed the problem.