Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unregistering device from notification hub #58

Open
ChristopherMWood opened this issue Jan 15, 2021 · 1 comment
Open

Unregistering device from notification hub #58

ChristopherMWood opened this issue Jan 15, 2021 · 1 comment

Comments

@ChristopherMWood
Copy link

I've been noticing an issue with multiple device registration on Azure notifications hub from using this plugin. I'm not completely sure if my understanding is accurate of what is going on, but it seems that once a device gets registered with Azure hubs, it never gets unregistered from there on out. This creates issues with test devices getting registered hundreds of times during development as well as individuals phones getting registered on production when uninstalling and reinstalling for any reason. Microsofts documentation, shared in the link, shows an example of how to register a phone and shows that unregistering is the first step before trying to register. This way any previous registration is wiped clean. I looked into the repo code and didn't see any code around this.

https://docs.microsoft.com/en-us/azure/notification-hubs/notification-hubs-push-notification-registration-management#example-code-to-register-with-a-notification-hub-from-a-device-using-a-registration

I was able to find the unregister methods in the projects source code but neither of them are accessible or used anywhere else in the project. At least from my github search there were no references past the declarations of the methods. I'm not sure if I'm missing something here in how to prevent duplicate registrations, but I'm currently unable to find a way using this plugin. Any clarity on how that is supposed to be handled, or if a PR is needed to implement it is appreciated. This is an issue that I've found others talking about online to mixed success. Seems like a pretty big documentation/clarification issues on Microsofts end to not make this use case more clear given the number of devices registered to certain tiers of their service is limited making this issue potentially eat up limited resources. Below is another link to a discussion of this issue I found on the Azure github

Azure/azure-notificationhubs-android#5

Any help or clarification is greatly appreciated since it's pretty hard to find reliable info out there about handling this use case.

@ghost
Copy link

ghost commented Jun 16, 2021

Also getting this issue. Devices do not unregister from tags even when
await CrossAzurePushNotification.Current.UnregisterAsync(); is called.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant