Add logs for PackageUpdatedTask

* That's the bit that updates new packages for work profile,
at least from command line.
* There is variability in how long it could take work profile
apps to show up, from 2-8 seconds.

Bug: 243688989
Change-Id: I710befc5f17b4a16bff523eb03f1e88975cafd43
This commit is contained in:
Vinit Nayak
2023-04-25 17:17:32 -07:00
parent a6a0867b65
commit 6106ae9ac7
3 changed files with 18 additions and 2 deletions

View File

@@ -151,7 +151,12 @@ public abstract class BaseModelUpdateTask implements ModelUpdateTask {
}
public void bindApplicationsIfNeeded() {
if (mAllAppsList.getAndResetChangeFlag()) {
boolean changeFlag = mAllAppsList.getAndResetChangeFlag();
if (TestProtocol.sDebugTracing) {
Log.d(WORK_TAB_MISSING, "bindApplicationsIfNeeded changeFlag? " +
changeFlag);
}
if (changeFlag) {
AppInfo[] apps = mAllAppsList.copyData();
int flags = mAllAppsList.getFlags();
scheduleCallbackTask(c -> c.bindAllApplications(apps, flags));