summaryrefslogtreecommitdiff
path: root/keystore/java/android/security/AndroidKeyStoreMaintenance.java
diff options
context:
space:
mode:
authorJeongsik Mun <jeongsik.mun@samsung.com>2021-01-05 16:51:28 +0900
committerTodd Kennedy <toddke@google.com>2021-03-02 21:12:27 +0000
commit8f35d505babb6b60ec07aa84b1caa01524f808b2 (patch)
tree1e3aa06f1cecd74d61a20989eadcd909f1368de5 /keystore/java/android/security/AndroidKeyStoreMaintenance.java
parent9995d6ca517d6c034c61f0b986342de55f18e456 (diff)
Avoid running RegisteredServicesCache tasks on main thread
Since RegisteredServicesCache tasks from SyncManager and AccountManager run on the main thread of SystemServer, It could cause draining the main thread and end up with ANR when receiving a lot of broadcasts or notifying changes through a listener. This CL changes a few things to avoid running it on main thread. 1. RegisteredServicesCache uses BackgroundThread by default for receiving broadcasts and a listener, instead of main thread. 2. AccountManager uses its own handler for a listener. Bug: 171907687 Test: atest SyncManagerTest CtsSyncManagerTest AccountManagerServiceTest Change-Id: I838c15b797b46fd58bb3c6ce9ee444a4737775d8
Diffstat (limited to 'keystore/java/android/security/AndroidKeyStoreMaintenance.java')
0 files changed, 0 insertions, 0 deletions