Resources:
Http://blog.sina.com.cn/s/blog_3e3fcadd0100yjo2.html
http://blog.csdn.net/windskier/article/details/6560925
http://blog.csdn.net/zmyde2010/article/details/6756368
Http://blog.sina.com.cn/s/blog_514048cb0100wi2j.html
Http://www.cnblogs.com/ylligang/articles/2665181.html
Method:
① for a service, you can first set it to run in the foreground
②android:persistent= "true". It is also the process resident system that applies to apps placed under/system/app. will never be killed. can be protected from out-of-memory killer.
It is not possible to completely keep the process from being killed, and we can make the process less likely to kill by doing something:
1) Increase the priority of the process:
* Background operation takes the form of service running in the foreground, because a process running a service is higher than a running background activity;
* Pressing the back key causes the activity in the process to run in the background instead of the destory, which requires the reload of the backend button (no activity is first killed in the running process).
* Reliance on other high-priority processes;
2) Force modify process properties:
* Set in Process: Setpersistent (TRUE);
* Set in the manifest file (as above).
How to make an Android app not be killed?