Skip to content
Commit 3bb8afe6 authored by Tim Murray's avatar Tim Murray
Browse files

Add infinitely deferred broadcasts.

- Adds a flag that prevents a broadcast from being delivered to a
  cached app until that app is no longer cached.

- As of this CL, this flag is only honored for unordered broadcasts to
  runtime receivers. Ordered broadcasts, alarm/interactive broadcasts,
  and manifest broadcasts are never deferred.

- This CL prevents the modern queue from cold starting processes for
  manifest receivers that would not be eligible to receive a
  particular broadcast, as in the case of USER_PRESENT.

- Unordered broadcasts with a completion callback (ie, resultTo
  broadcasts) are always marked as infinitely-deferred. resultTo
  broadcasts must still be dispatched only to runtime receivers or
  manifest receivers that disallow process starts in order to be
  deferred.

- This CL marks various BATTERY_CHANGED-esque broadcasts as infinitely
  deferred.

- This CL marks SCREEN_ON and SCREEN_OFF broadcasts as infinitely
  deferred.

- This CL marks USER_PRESENT broadcasts are infinitely deferred.

Test: atest BroadcastDeliveryGroupTest
Test: atest BroadcastQueueModernImplTest
Test: atest BroadcastQueueTest
Bug: 261065790
Bug: 263141882
Bug: 263143790

Change-Id: I9a356c8701d73f5687831fbe5b699e4485f07dd5
parent a9c38b7b
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