summaryrefslogtreecommitdiff
path: root/services/java/com/android/server/IdleMaintenanceService.java
Commit message (Collapse)AuthorAgeFilesLines
* Move some system services to separate directoriesAmith Yamasani2013-12-191-327/+0
| | | | | | | | Refactored the directory structure so that services can be optionally excluded. This is step 1. Will be followed by another change that makes it possible to remove services from the build. Change-Id: Ideacedfd34b5e213217ad3ff4ebb21c4a8e73f85
* Implement issue #10691359: Kill long-running processesDianne Hackborn2013-09-161-19/+50
| | | | | | | | | | | | | | | | | | | | | We now have the activity manager kill long-running processes during idle maintanence. This involved adding some more information to the activity manager about the current memory state, so that it could know if it really should bother killing anything. While doing this, I also improved how we determine when memory is getting low by better ignoring cases where processes are going away for other reasons (such as now idle maintenance). We now won't raise our memory state if either a process is going away because we wanted it gone for another reason or the total number of processes is not decreasing. The idle maintanence killing also uses new per-process information about whether the process has ever gone into the cached state since the last idle maintenance, and the initial pss and current pss size over its run time. Change-Id: Iceaa7ffb2ad2015c33a64133a72a272b56dbad53
* Idle maintenance scheduling broken.Svetoslav2013-05-031-49/+137
| | | | | | | | | | | | | | | 1. The scheduling was relying on receiving battery level broadcasts which however are not sent if the device is asleep. The maintenance window was not bound and we could miss a frame if the user did not interact the device longer than the min time between two maintenance windows. 2. Hide the idle maintenance intents since this will be rewritten to user services. bug:8688454 Change-Id: I17b421b09823cb46ec218cabda19e02432d94f8c
* Perform idle maintenance when the device is charging.Svetoslav2013-04-301-30/+36
| | | | | | | | | | | | Added the precondition that the device should be charging to the existing ones of the device not being used for awhile and the battery level being high enough. Note that even if the device is charging, we have to check the battery level since the user can unplug it at any time. bug:8688454 Change-Id: I709b1620571301743dc3504a6a625e2018951bfa
* Adding idle maintenance service.Svetoslav2013-02-151-0/+202
It is beneficial that there is a mechanism on the platform to notify applications whether it is safe to perform somehow expensive operations while the user is not using the device. Thus, user experience will not be degraded. An example is discarding of unused blocks on a mounted file system instead of doing this on every write operation. bug:8056794 Change-Id: I708bad9d3ce6c8f1d5a1c05c0abf46f81a3d464b