title: 64bit Console app / ThreadPool out of memory
body: <p>I have an ASP.NET web app and it's using 5GB memory running on 64bit Windows 7 machine with 8GB memory without any problem.  </p>
  
  <p>However, when I create a new C# console application on the same machine and reuse the same components the web app uses, the console app runs out of memory at about 1.6GB (by looking at System.Environment.WorkingSet and System.Diagnostics.Process.GetCurrentProcess().WorkingSet64).  There are still plenty of physical memory left.  It repros on 2 different machines.  </p>
  
  <p>Both web app and console app use ThreadPool.QueueUserWorkItem to start a background thread to load the large amount of data.  The exception happens at the background thread.</p>
  
  <p>I wonder if there is any default memory limit setting on console app or ThreadPool.  What debug variables I can look at to see this limit?</p>