Android threading issue
<pre><code>DalvikVM[localhost:8604]    
Thread [&lt;1&gt; main] (Running) 
Thread [&lt;7&gt; Binder Thread #2] (Running) 
Thread [&lt;6&gt; Binder Thread #1] (Running) 
Thread [&lt;8&gt; AsyncTask #1] (Running) 
Thread [&lt;9&gt; Binder Thread #3] (Running) 
Thread [&lt;10&gt; Binder Thread #4] (Running)    
Thread [&lt;11&gt; AsyncTask #2] (Running)    
Thread [&lt;12&gt; AsyncTask #3] (Running)    
</code></pre>

<p>While running my application i have seen this in the debug window.
I am wondering is this correct? Should there be these many tasks running. 
For example <code>Thread [&lt;8&gt; AsyncTask #1] (Running)</code> This task downloads a file from a web server. When the task is complete should this not disappear from the above list? </p>

<p>Am i not ending the task correctly?</p>

<pre><code>Tabletask = new CreateTablesTask();
Tabletask.execute();


class CreateTablesTask extends AsyncTask&lt;Object, Integer, Boolean&gt; {        

    ProgressDialog pleaseWaitDialog;

    @Override
    protected void onCancelled() {
        pleaseWaitDialog.dismiss();
    }

    @Override
    protected void onPreExecute() {
        pleaseWaitDialog = ProgressDialog.show(Activity.this, "Test", "Downloading", true, true);
        pleaseWaitDialog.setOnCancelListener(new OnCancelListener() {
            public void onCancel(DialogInterface dialog) {                  
            }
        });
    }

    @Override
    protected void onProgressUpdate(Integer... values) {
        super.onProgressUpdate(values);
    }

    protected Boolean doInBackground(Object... arg0) {
        //Some code in here                 
        return null;
    }
    protected void onPostExecute(Boolean result) {          
        PleaseWaitDialog.dismiss();
        return;
    }

}
</code></pre>
