Shipping OneSignal for Shipaton
Have you ever noticed how much of your push notification code has nothing to do with your product?
Token tables, refresh callbacks, stale-token pruning, a separate iOS pipeline-none of it is the feature, yet all of it needs maintaining.
Stock+ is a Kotlin Multiplatform app whose core product is price alerts, delivered as push notifications. This blog post describes how we migrated it from direct Firebase Cloud Messaging to OneSignal for the Shipaton hackathon: what actually changed architecturally, and the four silent failures I had to go hunting for along the way.
Addressing users, not devices
Direct FCM builds a message around a registration token. One token, one device. That sounds simple, but it quietly generates a lot of server-side work: a table of tokens per user, a refresh callback because tokens rotate, pruning on UNREGISTEREDbecause they go stale, a hand-written fan-out loop because a phone and a tablet are...
Copyright of this story solely belongs to hackernoon.com. To see the full text click HERE