Skip to content
Commit 61ffd79f authored by Kweku Adams's avatar Kweku Adams
Browse files

Try to avoid overlapping job execution.

In certain situtations, when an app schedules a new job using the same
job ID as an already executing job, JobScheduler may start running the
new job before it has fully stopped the old job and cleaned up state.
This may cause some incorrect behavior within apps that don't properly
handle this possibility. To alleviate that, try to avoid executing the
new job until the old job has finished, and document the behavior as
much as possible.

We still continue to start TOP+EJs immediately so that developers can
operate with that guarantee.

Bug: 231148615
Test: atest frameworks/base/services/tests/mockingservicestests/src/com/android/server/job
Test: atest frameworks/base/services/tests/servicestests/src/com/android/server/job
Test: atest CtsJobSchedulerTestCases
Change-Id: Ieedd7a9b91c350e0b835163fa9a73913d1edd345
parent 50f19f21
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment