Add stagedApexInfos to ApexStagedEvent
Previously, the event struct had the list of staged APEX names. This leads to calling getStagedApexInfo(name), which in turn calls getStagedApexInfos(session). Note that StagingManager gets the list of APEX names by calling getStagedApexInfos(session). Hence, the same method gets called repeatedly. getStagedApexInfos(session) is quite heavy because it involes mounting APEXes in the session and running an external program. Passing stagedApexInfos in ApexStagedEvent and providing getStagedApexInfos() make apexd & observers happy. (no need to run the same operation over and over.) Bug: 370712193 Test: StagingManagerTest Test: StagedInstallInternalTest Change-Id: I8d6a0baf6caff453f22d87a694a9eae91361a490
Loading
Please register or sign in to comment