I've read the push subscription can get out of sync between the browser and the push service.
I've seen two remediations, both look to be non-standard:
- ServiceWorkerGlobalScope.onpushsubscriptionchange
- GCM send response, mentioned here, spelled out here
- understandably non-standard
I presume any application should handle both of these points at which a subscription can be identified to be out-of-sync (and any/all).
Questions:
- In general, are there always just the two areas an application can be made aware of a subscription out-of-sync situation? (1. service worker event 2. push service response) Seems reasonable, looking for confirmation.
- Will the ServiceWorkerGlobalScope.onpushsubscriptionchange event (or some equivalent) make it into the authoritative standard?
- In lieu of a service worker event standard, why not just keep the expected subscription endpoint around (in client-side state) and anytime you query the PushManager for the subscription, check if it is out-of-sync (different than expected)?