Merge "Log EJ status to statsd." into sc-dev
This commit is contained in:
@@ -1046,7 +1046,7 @@ public class JobSchedulerService extends com.android.server.SystemService
|
|||||||
FrameworkStatsLog.write_non_chained(FrameworkStatsLog.SCHEDULED_JOB_STATE_CHANGED,
|
FrameworkStatsLog.write_non_chained(FrameworkStatsLog.SCHEDULED_JOB_STATE_CHANGED,
|
||||||
uId, null, jobStatus.getBatteryName(),
|
uId, null, jobStatus.getBatteryName(),
|
||||||
FrameworkStatsLog.SCHEDULED_JOB_STATE_CHANGED__STATE__SCHEDULED,
|
FrameworkStatsLog.SCHEDULED_JOB_STATE_CHANGED__STATE__SCHEDULED,
|
||||||
JobProtoEnums.STOP_REASON_CANCELLED, jobStatus.getStandbyBucket(),
|
JobProtoEnums.STOP_REASON_UNKNOWN, jobStatus.getStandbyBucket(),
|
||||||
jobStatus.getJobId(),
|
jobStatus.getJobId(),
|
||||||
jobStatus.hasChargingConstraint(),
|
jobStatus.hasChargingConstraint(),
|
||||||
jobStatus.hasBatteryNotLowConstraint(),
|
jobStatus.hasBatteryNotLowConstraint(),
|
||||||
@@ -1055,7 +1055,9 @@ public class JobSchedulerService extends com.android.server.SystemService
|
|||||||
jobStatus.hasDeadlineConstraint(),
|
jobStatus.hasDeadlineConstraint(),
|
||||||
jobStatus.hasIdleConstraint(),
|
jobStatus.hasIdleConstraint(),
|
||||||
jobStatus.hasConnectivityConstraint(),
|
jobStatus.hasConnectivityConstraint(),
|
||||||
jobStatus.hasContentTriggerConstraint());
|
jobStatus.hasContentTriggerConstraint(),
|
||||||
|
jobStatus.isRequestedExpeditedJob(),
|
||||||
|
/* isRunningAsExpeditedJob */ false);
|
||||||
|
|
||||||
// If the job is immediately ready to run, then we can just immediately
|
// If the job is immediately ready to run, then we can just immediately
|
||||||
// put it in the pending list and try to schedule it. This is especially
|
// put it in the pending list and try to schedule it. This is especially
|
||||||
|
|||||||
@@ -322,7 +322,9 @@ public final class JobServiceContext implements ServiceConnection {
|
|||||||
job.hasDeadlineConstraint(),
|
job.hasDeadlineConstraint(),
|
||||||
job.hasIdleConstraint(),
|
job.hasIdleConstraint(),
|
||||||
job.hasConnectivityConstraint(),
|
job.hasConnectivityConstraint(),
|
||||||
job.hasContentTriggerConstraint());
|
job.hasContentTriggerConstraint(),
|
||||||
|
job.isRequestedExpeditedJob(),
|
||||||
|
job.shouldTreatAsExpeditedJob());
|
||||||
try {
|
try {
|
||||||
mBatteryStats.noteJobStart(job.getBatteryName(), job.getSourceUid());
|
mBatteryStats.noteJobStart(job.getBatteryName(), job.getSourceUid());
|
||||||
} catch (RemoteException e) {
|
} catch (RemoteException e) {
|
||||||
@@ -904,7 +906,9 @@ public final class JobServiceContext implements ServiceConnection {
|
|||||||
completedJob.hasDeadlineConstraint(),
|
completedJob.hasDeadlineConstraint(),
|
||||||
completedJob.hasIdleConstraint(),
|
completedJob.hasIdleConstraint(),
|
||||||
completedJob.hasConnectivityConstraint(),
|
completedJob.hasConnectivityConstraint(),
|
||||||
completedJob.hasContentTriggerConstraint());
|
completedJob.hasContentTriggerConstraint(),
|
||||||
|
completedJob.isRequestedExpeditedJob(),
|
||||||
|
completedJob.startedAsExpeditedJob);
|
||||||
try {
|
try {
|
||||||
mBatteryStats.noteJobFinish(mRunningJob.getBatteryName(), mRunningJob.getSourceUid(),
|
mBatteryStats.noteJobFinish(mRunningJob.getBatteryName(), mRunningJob.getSourceUid(),
|
||||||
legacyStopReason);
|
legacyStopReason);
|
||||||
|
|||||||
@@ -142,13 +142,14 @@ public final class JobStatus {
|
|||||||
* (Atom #21)
|
* (Atom #21)
|
||||||
* * CONSTRAINT_BACKGROUND_NOT_RESTRICTED can be inferred with BatterySaverModeStateChanged
|
* * CONSTRAINT_BACKGROUND_NOT_RESTRICTED can be inferred with BatterySaverModeStateChanged
|
||||||
* (Atom #20)
|
* (Atom #20)
|
||||||
|
* * CONSTRAINT_STORAGE_NOT_LOW can be inferred with LowStorageStateChanged (Atom #130)
|
||||||
*/
|
*/
|
||||||
private static final int STATSD_CONSTRAINTS_TO_LOG = CONSTRAINT_CONTENT_TRIGGER
|
private static final int STATSD_CONSTRAINTS_TO_LOG = CONSTRAINT_CONTENT_TRIGGER
|
||||||
| CONSTRAINT_DEADLINE
|
| CONSTRAINT_DEADLINE
|
||||||
| CONSTRAINT_IDLE
|
| CONSTRAINT_IDLE
|
||||||
| CONSTRAINT_STORAGE_NOT_LOW
|
|
||||||
| CONSTRAINT_TIMING_DELAY
|
| CONSTRAINT_TIMING_DELAY
|
||||||
| CONSTRAINT_WITHIN_QUOTA;
|
| CONSTRAINT_WITHIN_QUOTA
|
||||||
|
| CONSTRAINT_WITHIN_EXPEDITED_QUOTA;
|
||||||
|
|
||||||
// TODO(b/129954980)
|
// TODO(b/129954980)
|
||||||
private static final boolean STATS_LOG_ENABLED = false;
|
private static final boolean STATS_LOG_ENABLED = false;
|
||||||
|
|||||||
Reference in New Issue
Block a user