StampChat/stamp

Pull notifications - Android

Opened this issue · 0 comments

Purpose: With current mobile platform's push notifications, all notification messages must go through the platform service (Apple Push Notification service - APNs for iOS or Firebase Cloud Messaging - FCM) and centrally managed via a remote push notification server. This represents a challenge for a decentralised application like Stamp.

While no perfect technologies are yet available to offer a decentralised notification delivery, Stamp will initially adopt a pull notification technique which leverage background tasks to query the server periodically and update the user if there are new messages available for them.

With Android, the background task technique appears to work relatively well. however there is a noticeable performance hit in battery life, which needs to be mitigated and/or inform users about. The notification speed is also not as fast as the push notification, depending on the background task schedule.

A/C:

  • The notification must be able to notify users within 5 minutes of successful broadcast
  • There is no significant battery drain to device
  • There is no significant impact to device performance
  • There should be a message to inform users about the expected notification speed and the decrease in performance/battery (if noticeable)