title: Prevent activity from being destroyed as long as possible
body: <p>I have an app, a single activity app with fragments in it.</p>
  
  <p>The usual use case for this app is, that you start it and put the phone away and every now and then, you get back to the phone and insert some data... It's a logging app, you are doing something and insert your results into the app...</p>
  
  <p>I have the problem, that every now and then, my activity get's destroyed and is recreated with an empty bundle... (Most of the time this is not the case, but every now and then this happens...). My app sometimes starts a service, even this service is killed in this case...</p>
  
  <p><em>This means, that the system has killed my app, does it? How can I avoid this?</em></p>
  
  <p>I need to keep the user data and the current top fragments... And they are saved to the bundle and everything works as long as their states and the data get saved...</p>
  
  <p>Btw., my activity is always the TOP ACTIVITY, only that the screen turns off often... I just want to keep my activity alive as long as possible until the user leaves it with the back button... Or to save the state reliably</p>
  
  <p><strong>IMPORTANT NOTE</strong></p>
  
  <p><em>onSaveInstance does not always work (it's not part of the lifecycle and therefore not guaranteed to be called)... it only works most of the time... I need a way to that works always... If android kills my app...</em></p>