This project is read-only.

JSON deserialization infinite loop

Topics: ASP.NET Web API
Aug 1, 2012 at 5:55 PM

I just posted this JSON.NET bug that we encountered while using Web API:

We've also discovered that when JSON.NET gets in this bad state during a request, it pegs a core. If another request has the same problem it pegs another core and so on.

Why doesn't the request time out? We've had to manually kill the w3p process - recycling the app pool is not sufficient.

We are using IIS 7.5 on Windows Service 2008 R2 x64. The web site connection timeout is set to 120 seconds.

Aug 2, 2012 at 7:23 PM

This issue has been fixed by James:

and I expect the fix will be available in the next release of Json.NET.

Thanks for reporting the issue

Aug 2, 2012 at 7:29 PM
Edited Aug 2, 2012 at 7:30 PM

Wow, James - thanks!

Am I stuck until the next version of Json.NET is released? 

From what I understand, I can't build and use Json.NET in Web API because it's unsigned and there doesn't seem to be any nightly or pre-release NuGet packages available. Is there a way around this?

Aug 25, 2012 at 12:24 AM

The fix should be available in Json.NET 4.5.8: