Loading apex/jobscheduler/service/java/com/android/server/job/JobConcurrencyManager.java +13 −5 Original line number Diff line number Diff line Loading @@ -741,17 +741,26 @@ class JobConcurrencyManager { pw.increaseIndent(); try { pw.print("Configuration:"); pw.println("Configuration:"); pw.increaseIndent(); pw.print(KEY_SCREEN_OFF_ADJUSTMENT_DELAY_MS, mScreenOffAdjustmentDelayMs).println(); pw.println(); CONFIG_LIMITS_SCREEN_ON.normal.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_ON.moderate.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_ON.low.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_ON.critical.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_OFF.normal.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_OFF.moderate.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_OFF.low.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_OFF.critical.dump(pw); pw.println(); pw.decreaseIndent(); pw.print("Screen state: current "); Loading @@ -770,18 +779,17 @@ class JobConcurrencyManager { pw.println(); pw.println("Current max jobs:"); pw.println(" "); pw.print("Current work counts: "); pw.println(mWorkCountTracker); pw.println(); pw.print("mLastMemoryTrimLevel: "); pw.print(mLastMemoryTrimLevel); pw.println(mLastMemoryTrimLevel); pw.println(); pw.print("User Grace Period: "); pw.print(mGracePeriodObserver.mGracePeriodExpiration); pw.println(mGracePeriodObserver.mGracePeriodExpiration); pw.println(); mStatLogger.dump(pw); Loading apex/jobscheduler/service/java/com/android/server/job/JobSchedulerService.java +12 −25 Original line number Diff line number Diff line Loading @@ -3040,7 +3040,6 @@ public class JobSchedulerService extends com.android.server.SystemService pw.println(); for (int i = mJobRestrictions.size() - 1; i >= 0; i--) { pw.print(" "); mJobRestrictions.get(i).dumpConstants(pw); pw.println(); } Loading @@ -3067,7 +3066,6 @@ public class JobSchedulerService extends com.android.server.SystemService job.dump(pw, " ", true, nowElapsed); pw.print(" Restricted due to:"); final boolean isRestricted = checkIfRestricted(job) != null; if (isRestricted) { Loading Loading @@ -3161,39 +3159,28 @@ public class JobSchedulerService extends com.android.server.SystemService } pw.println(); pw.println("Active jobs:"); pw.increaseIndent(); for (int i=0; i<mActiveServices.size(); i++) { JobServiceContext jsc = mActiveServices.get(i); pw.print("Slot #"); pw.print(i); pw.print(": "); jsc.dumpLocked(pw, nowElapsed); final JobStatus job = jsc.getRunningJobLocked(); if (job == null) { if (jsc.mStoppedReason != null) { pw.print("inactive since "); TimeUtils.formatDuration(jsc.mStoppedTime, nowElapsed, pw); pw.print(", stopped because: "); pw.println(jsc.mStoppedReason); } else { pw.println("inactive"); } continue; } else { pw.println(job.toShortString()); pw.print(" Running for: "); TimeUtils.formatDuration(nowElapsed - jsc.getExecutionStartTimeElapsed(), pw); pw.print(", timeout at: "); TimeUtils.formatDuration(jsc.getTimeoutElapsed() - nowElapsed, pw); pw.println(); if (job != null) { pw.increaseIndent(); job.dump(pw, " ", false, nowElapsed); int priority = evaluateJobPriorityLocked(job); pw.print("Evaluated priority: "); pw.println(JobInfo.getPriorityString(priority)); pw.println(JobInfo.getPriorityString(job.lastEvaluatedPriority)); pw.print("Active at "); TimeUtils.formatDuration(job.madeActive - nowUptime, pw); pw.print(", pending for "); TimeUtils.formatDuration(job.madeActive - job.madePending, pw); pw.println(); pw.decreaseIndent(); } } pw.decreaseIndent(); if (filterUid == -1) { pw.println(); pw.print("mReadyToRock="); pw.println(mReadyToRock); Loading apex/jobscheduler/service/java/com/android/server/job/JobServiceContext.java +24 −1 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ import android.os.RemoteException; import android.os.UserHandle; import android.os.WorkSource; import android.util.EventLog; import android.util.IndentingPrintWriter; import android.util.Slog; import android.util.TimeUtils; Loading Loading @@ -901,8 +902,30 @@ public final class JobServiceContext implements ServiceConnection { mTimeoutElapsed = sElapsedRealtimeClock.millis() + timeoutMillis; } private void removeOpTimeOutLocked() { mCallbackHandler.removeMessages(MSG_TIMEOUT); } void dumpLocked(IndentingPrintWriter pw, final long nowElapsed) { if (mRunningJob == null) { if (mStoppedReason != null) { pw.print("inactive since "); TimeUtils.formatDuration(mStoppedTime, nowElapsed, pw); pw.print(", stopped because: "); pw.println(mStoppedReason); } else { pw.println("inactive"); } } else { pw.println(mRunningJob.toShortString()); pw.increaseIndent(); pw.print("Running for: "); TimeUtils.formatDuration(nowElapsed - mExecutionStartTimeElapsed, pw); pw.print(", timeout at: "); TimeUtils.formatDuration(mTimeoutElapsed - nowElapsed, pw); pw.println(); pw.decreaseIndent(); } } } Loading
apex/jobscheduler/service/java/com/android/server/job/JobConcurrencyManager.java +13 −5 Original line number Diff line number Diff line Loading @@ -741,17 +741,26 @@ class JobConcurrencyManager { pw.increaseIndent(); try { pw.print("Configuration:"); pw.println("Configuration:"); pw.increaseIndent(); pw.print(KEY_SCREEN_OFF_ADJUSTMENT_DELAY_MS, mScreenOffAdjustmentDelayMs).println(); pw.println(); CONFIG_LIMITS_SCREEN_ON.normal.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_ON.moderate.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_ON.low.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_ON.critical.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_OFF.normal.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_OFF.moderate.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_OFF.low.dump(pw); pw.println(); CONFIG_LIMITS_SCREEN_OFF.critical.dump(pw); pw.println(); pw.decreaseIndent(); pw.print("Screen state: current "); Loading @@ -770,18 +779,17 @@ class JobConcurrencyManager { pw.println(); pw.println("Current max jobs:"); pw.println(" "); pw.print("Current work counts: "); pw.println(mWorkCountTracker); pw.println(); pw.print("mLastMemoryTrimLevel: "); pw.print(mLastMemoryTrimLevel); pw.println(mLastMemoryTrimLevel); pw.println(); pw.print("User Grace Period: "); pw.print(mGracePeriodObserver.mGracePeriodExpiration); pw.println(mGracePeriodObserver.mGracePeriodExpiration); pw.println(); mStatLogger.dump(pw); Loading
apex/jobscheduler/service/java/com/android/server/job/JobSchedulerService.java +12 −25 Original line number Diff line number Diff line Loading @@ -3040,7 +3040,6 @@ public class JobSchedulerService extends com.android.server.SystemService pw.println(); for (int i = mJobRestrictions.size() - 1; i >= 0; i--) { pw.print(" "); mJobRestrictions.get(i).dumpConstants(pw); pw.println(); } Loading @@ -3067,7 +3066,6 @@ public class JobSchedulerService extends com.android.server.SystemService job.dump(pw, " ", true, nowElapsed); pw.print(" Restricted due to:"); final boolean isRestricted = checkIfRestricted(job) != null; if (isRestricted) { Loading Loading @@ -3161,39 +3159,28 @@ public class JobSchedulerService extends com.android.server.SystemService } pw.println(); pw.println("Active jobs:"); pw.increaseIndent(); for (int i=0; i<mActiveServices.size(); i++) { JobServiceContext jsc = mActiveServices.get(i); pw.print("Slot #"); pw.print(i); pw.print(": "); jsc.dumpLocked(pw, nowElapsed); final JobStatus job = jsc.getRunningJobLocked(); if (job == null) { if (jsc.mStoppedReason != null) { pw.print("inactive since "); TimeUtils.formatDuration(jsc.mStoppedTime, nowElapsed, pw); pw.print(", stopped because: "); pw.println(jsc.mStoppedReason); } else { pw.println("inactive"); } continue; } else { pw.println(job.toShortString()); pw.print(" Running for: "); TimeUtils.formatDuration(nowElapsed - jsc.getExecutionStartTimeElapsed(), pw); pw.print(", timeout at: "); TimeUtils.formatDuration(jsc.getTimeoutElapsed() - nowElapsed, pw); pw.println(); if (job != null) { pw.increaseIndent(); job.dump(pw, " ", false, nowElapsed); int priority = evaluateJobPriorityLocked(job); pw.print("Evaluated priority: "); pw.println(JobInfo.getPriorityString(priority)); pw.println(JobInfo.getPriorityString(job.lastEvaluatedPriority)); pw.print("Active at "); TimeUtils.formatDuration(job.madeActive - nowUptime, pw); pw.print(", pending for "); TimeUtils.formatDuration(job.madeActive - job.madePending, pw); pw.println(); pw.decreaseIndent(); } } pw.decreaseIndent(); if (filterUid == -1) { pw.println(); pw.print("mReadyToRock="); pw.println(mReadyToRock); Loading
apex/jobscheduler/service/java/com/android/server/job/JobServiceContext.java +24 −1 Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ import android.os.RemoteException; import android.os.UserHandle; import android.os.WorkSource; import android.util.EventLog; import android.util.IndentingPrintWriter; import android.util.Slog; import android.util.TimeUtils; Loading Loading @@ -901,8 +902,30 @@ public final class JobServiceContext implements ServiceConnection { mTimeoutElapsed = sElapsedRealtimeClock.millis() + timeoutMillis; } private void removeOpTimeOutLocked() { mCallbackHandler.removeMessages(MSG_TIMEOUT); } void dumpLocked(IndentingPrintWriter pw, final long nowElapsed) { if (mRunningJob == null) { if (mStoppedReason != null) { pw.print("inactive since "); TimeUtils.formatDuration(mStoppedTime, nowElapsed, pw); pw.print(", stopped because: "); pw.println(mStoppedReason); } else { pw.println("inactive"); } } else { pw.println(mRunningJob.toShortString()); pw.increaseIndent(); pw.print("Running for: "); TimeUtils.formatDuration(nowElapsed - mExecutionStartTimeElapsed, pw); pw.print(", timeout at: "); TimeUtils.formatDuration(mTimeoutElapsed - nowElapsed, pw); pw.println(); pw.decreaseIndent(); } } }