WorldHealthOrganization / app

COVID-19 App
Other
2.13k stars 509 forks source link

Consider using instance id api to properly sync notification topics #1865

Open advayDev1 opened 3 years ago

advayDev1 commented 3 years ago

Given that country changing is now allowed, the topic management code is fragile.

Instead of keeping track of which topics are subscribed to in the user db, instead go to the source of truth: https://developers.google.com/instance-id/reference/server#get_information_about_app_instances and add or remove topics based on that list.

brunobowden commented 3 years ago

Agreed. This part of the system definitely needs an overhaul.

matthewblain commented 3 years ago

@advayDev1 can you comment on this doc: https://docs.google.com/document/d/1Itu46Qz43EVw2vasY0YvYDWydAlUyqMAEUgtRcROTGA/edit

advayDev1 commented 3 years ago

I will take a look monday

advayDev1 commented 3 years ago

Added comments for what i remember @matthewblain

stale[bot] commented 3 years ago

This item has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.