Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 75215f12 authored by Suprabh Shukla's avatar Suprabh Shukla
Browse files

Filter out uninteresting UidObserver callbacks in NPMS

NPMS depends on three different process state thresholds for evaluating
network access. But holding the common lock for evaluating the network
rules may cause a lot of contention on the handler as uid changes are
frequent.
Separating out a fast check to filter out uninteresting proc-state
callbacks before posting to the handler for full evaluation of the
rules. This is especially useful when we use no cutpoint for the uid
observer registration.

This also fixes an inconsistency where changes crossing
TOP_THRESHOLD_STATE may not be received if the app transitioned
from some process-states below BFGS.

Test: atest FrameworksServicesTests:NetworkPolicyManagerServiceTest
Test: atest CtsHostsideNetworkTests

Bug: 319728914
Change-Id: Ia7a5aef1ce9705a55912749985c7ee950c24ac84
parent 5a8e66fd
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