Reputation: 4120
I'll explain it clearly. I have an app that utilized Google Map v2. Now, when the user is using the app, even if it is on the background, the app must identify the current location of the user, and the app must push a notification if the user is near a landmark,or restaurant,or hotel (etc etc). I think this can be done using the notification builder, but the tricky part is we have an admin panel(web-based) that will enable potential clients to add, update, delete Merchant and Sponsored Promotions relevant for specific Historical or Landmark Site. Since potential types of notifications will increase, the app must fetch the currently added data on the admin pane. I don't know if using the notification builder or this is the best choice. I hope you can give me a detailed explanation or advice about this. Thanks.
Upvotes: 0
Views: 340
Reputation: 393821
Since the app must run in the background in order to maintain the current location of the user, and deliver notifications based on that location, you don't have to use GCM. The background process can access the server periodically to load the updates in notification types.
However, if you wish your app to update its notification types even when it's not running at all, you'll need to use GCM. GCM will also be useful if you prefer to reduce access of your app to the server (in order to save battery life) - it will allow your server to notify the app when an update is available in the notification types, and then your app can load the update from the server (assuming the data is too big to be sent in the GCM notification).
You should estimate how often you expect the server to have updated notification types, and decide what the app's response time should be to such changes (how much time you allow to pass from the server update time to the time the client gets the update). If you require quick response time, GCM would be preferable to polling the server by your background process (to save battery).
Upvotes: 1