title: Implementing thread timeout in executor service
body: <p>So right now I have a fairly basic Executor service that I use to break my program into threads, like so:</p>
  
  <pre><code>ExecutorService threadPool = Executors.newFixedThreadPool(12);
  for (int i = 0; i &lt; objectArray.length; i++) {
      threadPool.submit(new ThreadHandler(objectArray[i], i));
            // The i is used elsewhere
  }
  </code></pre>
  
  <p>I was wondering if there was a good way to detect / close "crashed" or "frozen" threads?   I took a look at the documentation but it doesn't really seem to fit in with how I'm using this at all...</p>
  
  <p>Can someone help me with this?  Thanks</p>