Merge "Show "in parole?" in dumpsys jobscheduler" into pi-dev

This commit is contained in:
Makoto Onuki
2018-05-08 18:09:56 +00:00
committed by Android (Google) Code Review
2 changed files with 5 additions and 0 deletions

View File

@@ -40,6 +40,7 @@ message JobSchedulerServiceDumpProto {
repeated int32 next_heartbeat = 15;
optional int64 last_heartbeat_time_millis = 16;
optional int64 next_heartbeat_time_millis = 17;
optional bool in_parole = 18;
repeated int32 started_users = 2;

View File

@@ -3036,6 +3036,9 @@ public class JobSchedulerService extends com.android.server.SystemService
TimeUtils.formatDuration(mLastHeartbeatTime + mConstants.STANDBY_HEARTBEAT_TIME,
nowElapsed, pw);
pw.println();
pw.print(" In parole?: ");
pw.print(mInParole);
pw.println();
pw.println();
pw.println("Started users: " + Arrays.toString(mStartedUsers));
@@ -3210,6 +3213,7 @@ public class JobSchedulerService extends com.android.server.SystemService
mLastHeartbeatTime - nowUptime);
proto.write(JobSchedulerServiceDumpProto.NEXT_HEARTBEAT_TIME_MILLIS,
mLastHeartbeatTime + mConstants.STANDBY_HEARTBEAT_TIME - nowUptime);
proto.write(JobSchedulerServiceDumpProto.IN_PAROLE, mInParole);
for (int u : mStartedUsers) {
proto.write(JobSchedulerServiceDumpProto.STARTED_USERS, u);