title: Android: Process has died - low resources?
body: <p>I've a little problem with a simple HTTP GET request that I've written and which will request a URL every X minutes. I had it once or twice a day that the process stopped in the midst of the GET request.</p>
  
  <p>Here's an example of the debug log:</p>
  
  <pre><code>12-07 16:29:22.650 V/TAG(11655): Executing HTTP Request
  12-07 16:29:25.336 D/dalvikvm(11655): GC_CONCURRENT freed 366K, 50% free 2824K/5639K, external 0K/0K, paused 3ms+3ms
  12-07 16:29:25.526 D/dalvikvm(11655): GC_CONCURRENT freed 450K, 52% free 2825K/5767K, external 0K/0K, paused 2ms+2ms
  12-07 16:29:29.990 I/ActivityManager( 1339): Process PackageName:remote (pid 11655) has died.
  12-07 16:29:29.990 I/ActivityManager( 1339): Low Memory: No more background processes.
  </code></pre>
  
  <p>Now this just threw up two problems for me:</p>
  
  <ul>
  <li><p>First, the timeout that I've specified does not work:</p>
  
  <pre><code>    HttpParams httpParameters = new BasicHttpParams();
      int timeoutConnection = 10000;
      HttpConnectionParams.setConnectionTimeout(httpParameters, timeoutConnection);
      int timeoutSocket = 10000;
      HttpConnectionParams.setSoTimeout(httpParameters, timeoutSocket);
      HttpClient client=new DefaultHttpClient(httpParameters);
      HttpGet request=new HttpGet(url);
      Log.v(TAG,"Executing HTTP Request");
      HttpResponse response=client.execute(request);
  </code></pre></li>
  <li><p>The second problem is that I cannot see a reason why the process has died - is this the 'died' message the same if it is getting killed due to low memory? Because the timeout has not been reached here (client.execute is in a try / catch block)</p></li>
  </ul>
  
  <p>Thanks for your replies!</p>