Java - Basic Multithreading
<p>I would like to ask  basic question about Java threads. Let's consider a producer - consumer scenario. Say there is one producer, and n consumer. Consumer arrive at random time, and once they are served they go away, meaning each consumer runs on its own thread. Should I still use run forever condition for consumer ? </p>

<pre><code>public class Consumer extends Thread {
    public void run() {
        while (true) {
        }
    }
}
</code></pre>

<p>Won't this keep thread running forever ? </p>
