[incfs] Correctly wait for async .so's extraction
StorageID for an installation changes as we go from a staging
directory to the final one. That's why the only correct way
of waiting for the extraction to complete is by the whole
MountID, even if later it would cause the call to wait on all
instances of the app.
+ measure the waiting timing
Bug: 153513507
Test: adb install megacity.apk
Change-Id: I83558f155867ae5503719ecb63d591fc969c3995
diff --git a/services/incremental/IncrementalService.h b/services/incremental/IncrementalService.h
index e7705df..c016bab 100644
--- a/services/incremental/IncrementalService.h
+++ b/services/incremental/IncrementalService.h
@@ -308,8 +308,8 @@
StorageId mNextId = 0;
using Job = std::function<void()>;
- std::unordered_map<StorageId, std::vector<Job>> mJobQueue;
- StorageId mPendingJobsStorage = kInvalidStorageId;
+ std::unordered_map<MountId, std::vector<Job>> mJobQueue;
+ MountId mPendingJobsMount = kInvalidStorageId;
std::condition_variable mJobCondition;
std::mutex mJobMutex;
std::thread mJobProcessor;