title: Is it ok if a worker thread that pulls from a BlockingQueue never exits in android?
body: <p>I have a thread which basically looks like this:</p>
  
  <pre><code>public void run() throws InterruptedException {
     while(true) {
           String curUrl = taskQueue.take();
           ...
     }
  }
  </code></pre>
  
  <p>I know I can change <code>true</code> to a volatile variable, and set it to false when I no longer need it, but it is used throughout my application, so its difficult to tell when it is no longer needed.</p>
  
  <p>I am wondering if having an infinite loop will have a visible effect on the performance of the rest of the android VM, if its left in a blocked state even when my app is not running.</p>
  
  <p>EDIT 1: The code that starts the thread will only start it if its not already running.</p>