7

When I make a XmlHttpRequest (via jQuery's $.ajax) to a particular URL, my Chrome consistently hangs every time with a status on the request of 'Pending'.

After that Chrome must be closed ie. forcibly from Task Manager, and it exhibits general signs of mayhem such as the Cookies and Scripts tabs being empty when they were full of normal looking data immediately prior.

This is odd because (a) my coworkers, running a seemingly identical everything, have no such problems; (b) I have been using Chrome to run this code (our company's JavaScript app) for many months and this just started happening for no apparent reason.

I checked out the Apache logs, they appear to be processing the request normally and to completion, but Chrome never sees the reply, apparently.

A couple of other clarifications: prior to the failure, the same Chrome and Apache return a truckload of JS and image files normally, eg., things seem to be fine right up until they aren't. The request is not particularly large (a few hundred bytes in and out) or complex in any obvious way.

If anybody can give me some hints of where to look, I'd be grateful!

4
  • A couple of other clarifications: prior to the failure, the same Chrome and Apache return a truckload of JS and image files normally, eg., things seem to be fine right up until they aren't. The request is not particularly large (a few hundred bytes in and out) or complex in any obvious way. Commented May 26, 2012 at 5:10
  • Thanks jmort253, it's kind of you to write all that. Commented May 29, 2012 at 19:14
  • Is this in someway related to your question? stackoverflow.com/questions/11296036/… Commented Dec 16, 2013 at 17:43
  • Look into this question: stackoverflow.com/questions/5585918/… The cause could be caused by an extension or security software (e.g. an anti-virus) Commented Feb 18, 2015 at 17:16

1 Answer 1

11

I'm experiencing similar behavior with slightly different symptoms. My ajax requests work fine, every second request up to 6 requests, then they all start failing (same url as when working, same payload, etc), but in my case they're not even hitting the server, just stuck in "Pending" in Inspector.

I dont have an answer for you, but to help debug, have you tried chromes net-internals?

Point your browser at:

chrome://net-internals/#sockets 

and/or

chrome://net-internals/#events 

I see my requests in #sockets go into "active", but never come back, and in #events I can see that the request stalls after the HOST_RESOLVER_IMPL_REQUEST stage.

I'm thinking it could be a resource issue caused by not properly ending the request, but thats just pure speculation.

Sign up to request clarification or add additional context in comments.

3 Comments

Excellent, thanks a lot, will try that out. Didn't know about that at all. Incidentally, I see several similar-sounding queries on the Chrome support forums, most unanswered.
No problem. For me, the "not properly ending the request" was the cause, and net-internals ended up being perfect for my debugging.
When I went into chrome://net-internals/#events and went to the URL that was causing issues, I saw this error: net_error = -20 (ERR_BLOCKED_BY_CLIENT). It turns out that it was Adblock Plus causing the issue. Now I'm just worried that this might happen to my end users if they have Adblock Plus installed.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.