wtg / Shuttle-Tracker-SwiftUI

Rensselaer campus shuttle tracker
https://shuttletracker.app
Mozilla Public License 2.0
9 stars 2 forks source link

Send notifications for new announcements #136

Closed Gerzer closed 1 year ago

Gerzer commented 1 year ago

We should send a notification to the user for each new announcement. There are two possible approaches:

Each approach has unique benefits and downsides.

Local Notifications

The two key benefits of local notifications is that they are substantially easier to implement and don’t require any new server-side logic. The most notable downside is that the notification to users is delayed until whatever system background mechanism (such as Background App Refresh) that we choose decides to wake our app so that it can poll the server for new announcements.

Push Notifications

The key benefit of push notifications is that they are nearly instantaneous, but they’re much more difficult to implement. We’ll need to set up a remote notification server and to register our app with APNs. For the server-side logic, we should probably use APNSwift.

I’ll create an issue in the Shuttle Tracker Server repository if we decide to pursue the push notifications approach.