figured out what is causing it, though still not sure why. Had the app pool set to recycle the process if it got bigger than 1024M of virtual memory. It was recycling whenever it got to about 60M of virtual memory. Turned off that setting and it runs fine. Wierd.