Loading apex/jobscheduler/service/java/com/android/server/job/JobSchedulerService.java +10 −0 Original line number Diff line number Diff line Loading @@ -339,6 +339,11 @@ public class JobSchedulerService extends com.android.server.SystemService public void onPropertiesChanged(DeviceConfig.Properties properties) { boolean apiQuotaScheduleUpdated = false; boolean concurrencyUpdated = false; for (int controller = 0; controller < mControllers.size(); controller++) { final StateController sc = mControllers.get(controller); sc.prepareForUpdatedConstantsLocked(); } synchronized (mLock) { for (String name : properties.getKeyset()) { if (name == null) { Loading Loading @@ -384,6 +389,11 @@ public class JobSchedulerService extends com.android.server.SystemService && !concurrencyUpdated) { mConstants.updateConcurrencyConstantsLocked(); concurrencyUpdated = true; } else { for (int ctrlr = 0; ctrlr < mControllers.size(); ctrlr++) { final StateController sc = mControllers.get(ctrlr); sc.processConstantLocked(properties, name); } } break; } Loading apex/jobscheduler/service/java/com/android/server/job/controllers/JobStatus.java +5 −0 Original line number Diff line number Diff line Loading @@ -1388,6 +1388,11 @@ public final class JobStatus { } if (isReady()) { sb.append(" READY"); } else { sb.append(" satisfied:0x").append(Integer.toHexString(satisfiedConstraints)); sb.append(" unsatisfied:0x").append(Integer.toHexString( (satisfiedConstraints & mRequiredConstraintsOfInterest) ^ mRequiredConstraintsOfInterest)); } sb.append("}"); return sb.toString(); Loading apex/jobscheduler/service/java/com/android/server/job/controllers/QuotaController.java +371 −269 File changed.Preview size limit exceeded, changes collapsed. Show changes apex/jobscheduler/service/java/com/android/server/job/controllers/StateController.java +9 −0 Original line number Diff line number Diff line Loading @@ -18,7 +18,9 @@ package com.android.server.job.controllers; import static com.android.server.job.JobSchedulerService.DEBUG; import android.annotation.NonNull; import android.content.Context; import android.provider.DeviceConfig; import android.util.IndentingPrintWriter; import android.util.Slog; import android.util.proto.ProtoOutputStream; Loading Loading @@ -84,6 +86,13 @@ public abstract class StateController { public void rescheduleForFailureLocked(JobStatus newJob, JobStatus failureToReschedule) { } /** Notice that updated configuration constants are about to be read. */ public void prepareForUpdatedConstantsLocked() {} /** Process the specified constant and update internal constants if relevant. */ public void processConstantLocked(@NonNull DeviceConfig.Properties properties, @NonNull String key) {} /** * Called when the JobScheduler.Constants are updated. */ Loading core/java/android/provider/Settings.java +0 −15 Original line number Diff line number Diff line Loading @@ -11887,21 +11887,6 @@ public final class Settings { */ public static final String POWER_MANAGER_CONSTANTS = "power_manager_constants"; /** * Job scheduler QuotaController specific settings. * This is encoded as a key=value list, separated by commas. Ex: * * "max_job_count_working=5,max_job_count_rare=2" * * <p> * Type: string * * @hide * @see com.android.server.job.JobSchedulerService.Constants */ public static final String JOB_SCHEDULER_QUOTA_CONTROLLER_CONSTANTS = "job_scheduler_quota_controller_constants"; /** * ShortcutManager specific settings. * This is encoded as a key=value list, separated by commas. Ex: Loading Loading
apex/jobscheduler/service/java/com/android/server/job/JobSchedulerService.java +10 −0 Original line number Diff line number Diff line Loading @@ -339,6 +339,11 @@ public class JobSchedulerService extends com.android.server.SystemService public void onPropertiesChanged(DeviceConfig.Properties properties) { boolean apiQuotaScheduleUpdated = false; boolean concurrencyUpdated = false; for (int controller = 0; controller < mControllers.size(); controller++) { final StateController sc = mControllers.get(controller); sc.prepareForUpdatedConstantsLocked(); } synchronized (mLock) { for (String name : properties.getKeyset()) { if (name == null) { Loading Loading @@ -384,6 +389,11 @@ public class JobSchedulerService extends com.android.server.SystemService && !concurrencyUpdated) { mConstants.updateConcurrencyConstantsLocked(); concurrencyUpdated = true; } else { for (int ctrlr = 0; ctrlr < mControllers.size(); ctrlr++) { final StateController sc = mControllers.get(ctrlr); sc.processConstantLocked(properties, name); } } break; } Loading
apex/jobscheduler/service/java/com/android/server/job/controllers/JobStatus.java +5 −0 Original line number Diff line number Diff line Loading @@ -1388,6 +1388,11 @@ public final class JobStatus { } if (isReady()) { sb.append(" READY"); } else { sb.append(" satisfied:0x").append(Integer.toHexString(satisfiedConstraints)); sb.append(" unsatisfied:0x").append(Integer.toHexString( (satisfiedConstraints & mRequiredConstraintsOfInterest) ^ mRequiredConstraintsOfInterest)); } sb.append("}"); return sb.toString(); Loading
apex/jobscheduler/service/java/com/android/server/job/controllers/QuotaController.java +371 −269 File changed.Preview size limit exceeded, changes collapsed. Show changes
apex/jobscheduler/service/java/com/android/server/job/controllers/StateController.java +9 −0 Original line number Diff line number Diff line Loading @@ -18,7 +18,9 @@ package com.android.server.job.controllers; import static com.android.server.job.JobSchedulerService.DEBUG; import android.annotation.NonNull; import android.content.Context; import android.provider.DeviceConfig; import android.util.IndentingPrintWriter; import android.util.Slog; import android.util.proto.ProtoOutputStream; Loading Loading @@ -84,6 +86,13 @@ public abstract class StateController { public void rescheduleForFailureLocked(JobStatus newJob, JobStatus failureToReschedule) { } /** Notice that updated configuration constants are about to be read. */ public void prepareForUpdatedConstantsLocked() {} /** Process the specified constant and update internal constants if relevant. */ public void processConstantLocked(@NonNull DeviceConfig.Properties properties, @NonNull String key) {} /** * Called when the JobScheduler.Constants are updated. */ Loading
core/java/android/provider/Settings.java +0 −15 Original line number Diff line number Diff line Loading @@ -11887,21 +11887,6 @@ public final class Settings { */ public static final String POWER_MANAGER_CONSTANTS = "power_manager_constants"; /** * Job scheduler QuotaController specific settings. * This is encoded as a key=value list, separated by commas. Ex: * * "max_job_count_working=5,max_job_count_rare=2" * * <p> * Type: string * * @hide * @see com.android.server.job.JobSchedulerService.Constants */ public static final String JOB_SCHEDULER_QUOTA_CONTROLLER_CONSTANTS = "job_scheduler_quota_controller_constants"; /** * ShortcutManager specific settings. * This is encoded as a key=value list, separated by commas. Ex: Loading