IE7 stops making network requests after a while

2019-07-16 14:01发布

问题:

Our (asp.net) system is part of a larger system. It is launched via this larger system from javascript that does a window.open call to open a new window.

(aside, authentication data etc is passed into our system via an encrypted query string parameter)

When testing with IE7 (unfortunately the organization has standardized on this) the browser will, after using our system (navigating around pages) for a while (its intermittent), start not making network requests. Pressing F5 causes it to show its loading animation, but nothing actually happens).

You can close our window, and go back to the larger system (in its own window) which still works fine. If you re-launch our system, the new window opens up and it looks like its loading, but no request is made (verified with wireshark). The systems are on separate sub-domains.

Here is the funny thing, if I start up Fiddler, everything starts working fine. As soon as I close Fiddler, it stops making network requests.

The system is quite an html/javascript/ajax heavy system (1MB+ per page), but that shouldn't cause the browser to do this. Obviously Firefox and Chrome work perfectly :)

The only way to get it working again, is to shut down all the IE windows, and start up again.

I've disabled the proxy server, enabled it, done pretty much everything I can think of.

Anyone got any ideas?

UPDATE

I managed to reproduce it with fiddler running. Initially, when its working, I can see all the requests in Fiddler. When it goes into its "no-requests-being-made" mode (again, note that nothing changes, I'm just browsing around), I don't see any thing in Fiddler (i.e. no new requests, nothing). All the requests that fiddler has logged are completed, so there are no open connections.

We're seeing this on almost every machine. After browsing about 15 pages, this starts happening. Could it be some environmental thing? My test machine is a vanilla XP install with McAfee, IE7. Nothing else is running, and no toolbars are installed in IE.

回答1:

Try merging http://www.enhanceie.com/dl/fixHTTPMax.reg to up your HTTP connection limit, then check to see if it takes ~10x as long to run into the problem.

If so, then the problem is that you've enountered a problem where a HTTP connection is being leaked, and then you're eventually hitting the max-connections-per-server limit.



回答2:

Turn on JavaScript debugging in IE and check for any errors that occur.



回答3:

You've got yourself in a little pickle with the fiddler automatic proxy settings.

When fiddler starts it modifies the proxy settings of IE to point at fiddler when fiddler closes it restores the original proxy settings.

If fiddler sees existing proxy settings it will use those in the request it forwards.

In certain error conditions you can be left with no fiddler running but the fiddler proxy modifications still in place in the IE settings. You can end up with a situation where IE only works when Fiddler is running.

Reset IE's proxy settings.

Edit

Failing that the most likely cause is having outstanding requests that havn't yet been fulfilled. Have two of these and in the default IE config all other requests will wait indefinitely for the outstanding requests to complete. Firing up fiddler can cure this for a while because requests aren't going directly to the server. Can you reproduce the problem with fiddler running? Do you see outstanding requests in fiddler?



回答4:

Make sure your setting connect: close in the HTTP header when you're done.