Group install and failure notifications under summaries

A bulk update produced one standalone notification per app for both
successes and failures, flooding the shade. Bundle these terminal
notifications into two groups, each with a collapsible summary that
lists the apps via InboxStyle:

- "N apps installed" on the (LOW, silent) installed channel, expiring
  on its own since it's informational.
- "N apps failed" on the (HIGH) alerts channel, persisting until
  handled and carrying a Retry action per app.

Summaries are rebuilt from the live posted notifications rather than
tracked state, so they stay correct across retries, dismissals and
process restarts, and are only posted on Android N+ where the system
actually renders groups.

Retry re-queues the download via a new DownloadRetryReceiver; the
worker resumes from verified files on disk, so retrying an install
failure re-installs without re-downloading.
This commit is contained in:
Rahul Patel
2026-05-30 18:07:28 +05:30
parent 9bd5e3f8e7
commit aa5d3fcc4b
8 changed files with 249 additions and 14 deletions

View File

@@ -188,6 +188,11 @@
android:name=".data.receiver.DownloadCancelReceiver"
android:exported="false" />
<!-- Retry Download Receiver-->
<receiver
android:name=".data.receiver.DownloadRetryReceiver"
android:exported="false" />
<!-- SessionInstaller (as device owner) -->
<receiver
android:name=".data.receiver.DeviceOwnerReceiver"