seedvault/app
t-m-w a091142a3f Allow restoring data for a greater number of apps
Restore app data in smaller batches when performing a full restoration
from a backup set, to prevent a Binder exception that causes the
process to fail entirely.

Android may encounter this exception when trying to call the
transport.startRestore() method if too many packages are involved; in
testing, 300 is an example of too many. Instead of using
IRestoreSession.restoreAll(), use restorePackages() and provide the
package names in batches of 100.

This issue reveals itself when using SeedVault with the D2D patch and
with an OS, such as stock Pixel OS, that includes an abundance of
packages. (Prior to this patch, the call to restoreAll() meant that the
framework would request data restoration for all packages installed,
even if they were not in the metadata.)

In logs, this issue appears as follows:
```
I BackupManagerService: Full restore; asking about 300 apps
W BpBinder: Large outgoing transaction of 528540 bytes, interface descriptor <uncached descriptor>, code 14
E JavaBinder: !!! FAILED BINDER TRANSACTION !!!  (parcel size = 528540)
E BackupManagerService: Unable to contact transport for restore: data parcel size 528540 bytes
```

Change-Id: Ibb5bb4572d9e873beccd6056da5fe3ae4dce71c2
2023-10-31 21:38:36 -04:00
..
development Fix and improve E2E tests 2023-10-17 21:24:38 -04:00
libs 14: Update AOSP libs from gradle, from android-14.0.0_r1 2023-10-09 00:01:53 +05:30
src Allow restoring data for a greater number of apps 2023-10-31 21:38:36 -04:00
build.gradle.kts Switch to Kotlin build scripts + version catalog 2023-10-19 00:22:51 -04:00
lint.xml Ignore extra translations 2023-03-10 00:07:24 +05:30