title: Endless loop in a servlet - recovery possible?
body: <p>Today I fixed a bug in an application that might have lead to an endless loop in a servlet request/response cycle.</p>
  
  <p>So just out of curiousity: What happens, if my servlet actually gets trapped in a for(;;) loop?</p>
  
  <p>Is it somehow possible to recover? Will tomcat detect this? Can this instance be killed without restarting the server?</p>
  
  <p>Or is this one of the worst things that can happen and a very quick way to kill a webcontainer?</p>
  
  <p>EDIT: It was a true endless loop consuming CPU all the time but not memory. I kept it running for a few minutes. I think, I can confirm that tomcat will not detect this kind of thing :-)</p>