I have read apple's push notification guideline and a few stack overflow questions such as these:
and even considered using google's GSM but realized underlaying it uses APN
but none point out what happens when there are multiple users created for an app on the same device or when one user has multiple devices. And only the question "Are push notification tokens unique across all apps for a single device?" addressed the multiple devices case but the answer was 5 years ago, so was wondering if anything changed with iOS 9
.
Does that mean my server(provider) will have have a one to many relationship with a token and the primary key will constitute a user_id
and a user_token
?
Based on the reading material linked in the question, and Apple's documentation that the token may change, the user_id
and user_token
will have a many-to-many
relationship and we should use Apple APN feedback service to remove old tokens.