简体   繁体   中英

Android: Does Google Play check versionCodes of installed apks?

Google Play has an automatic update system for apps. When a new version is uploaded to the Developer Console the app is updated on user devices because the new versionCode is greater than the one that is already installed. But users could get a newer apk from other sources.

I would like to know some details about this automatic process, I mean:

A-Does Google Play keeps a value inside so it remembers what versionCode of an app it has officially installed?

or

B-Does Google Play inspects all installed apks so it can compare the version codes to the current versions officially provided by the developers on Google Play?

Note the difference:

-in the A case, it just remember what it officially installed but is not informed about the real versionCode the user has on the device; so it could try to update even when the user already got a newer apk from outside Google Play (fail);

-in the B case, the update system can understand what version in installed because it checks it; so the update doesn't even start if the user upgraded an app from outside the Google Play.

Which is the real case?

It is case A - Google remembers which version of the app was last installed.

It does not check the device every time for the latest installed version.

How to verify this?

If you ever factory reset your phone or flash a ROM, go to play store from your browser and open an app page which you'd installed before you flashed the ROM or did a factory reset. It will still show as installed, although you wiped your device clean and it is not installed anymore.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM