推送通知:为什么使用Google的GCM / FCM上的Amazon SNS? [英] Push notifications: Why use Amazon SNS over Google's GCM/FCM?

本文介绍了推送通知:为什么使用Google的GCM / FCM上的Amazon SNS?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Phonegap Build为Android和iOS创建了一个移动应用程序。去年,我几乎完成了编写代码以使用GCM(Google云消息传递)来进行远程推送通知 - 这些通知也可以通过Apple的APNS发送出去 - 但该项目被搁置了。

今年该项目复活,我发现Google已将所有内容都改为Firebase(FCM)。然后我读了一些关于Amazon SNS处理通知的诱人的东西。正当我开始认为SNS可能是更好的选择时,我注意到你仍然必须设置GCM / FCM,并将所有这些细节传递给SNS。

strong>当我必须进行完整的FCM设置时,使用SNS还有什么好处?这两项服务似乎都提供了相同的功能:如果需要与APNS进行交互,订阅主题,为您提供有一个很好的API / SDK等等。就我所见,应用程序代码和服务器端代码不会更简单。为什么要在FCM上添加另一个图层(SNS)?



(我不想让这是一个基于意见的问题:我想知道无论SNS是否节省我的努力,给我任何优势,或添加FCM所没有的功能。)

我们先回答几个问题。

1.您是否想要开发,维护和运行代码与GCM进行交谈?

2.您是否希望执行相同的操作另一个平台(iOS,Kindle Fire),如果您选择为其他移动平台开发应用程序。

3.您是否想自己管理registration_id的变更?

4。您是否关心几毫秒后才向用户发送通知?

如果您对上述任何问题回答否,我建议您使用SNS向iOS,Android和Kindle Fire设备发送推送通知。


SNS与GCM对话,向Android设备发送通知。这是SNS可以为您提供的功能。

简单API将通知发送到异构平台。

管理应用程序registration_ids。作为一名开发人员,您不必担心registration_ids的更改。

非常好。如果您的应用程序变得非常流行,您不必担心管理基础架构。

可以容忍GCM停机时间&节流。

I have created a mobile app for Android and iOS using Phonegap Build. Last year I had nearly finished writing code to use GCM (Google Cloud Messaging) for remote push notifications - which can go out via Apple's APNS too - but the project was shelved.

This year the project is resurrected and I find Google has changed everything to Firebase (FCM). I then read some enticing things about Amazon SNS handling notifications. Just when I started to think SNS might be a better option, I noticed you still have to set up GCM/FCM anyway, and pass all those details to SNS.

So is there any benefit to using SNS when I've got to do the full FCM setup as well?! Both services seem to offer the same features: interact with APNS if required, subscribe to topics, provide you with a nice API/SDK, etc. The app code, and the server-side code would be no simpler, as far as I can see. Why add another layer (SNS) on top of FCM?

(I'm trying not to let this be an opinion-based question: I want to know whether SNS is saving me any effort, giving me any advantage, or adding any features that FCM does not have.)

解决方案

Let's answer a few questions first.

1.Do you want to develop, maintain and run the code to talk to GCM?
2.Do you wish to do the same for another platform (iOS, Kindle Fire), if you choose to develop your app for other mobile platforms.
3.Do you want to manage change of registration_id's by yourself?
4.Do you care if a notification is delivered to your users a few milliseconds later?
If you answered NO to any of the questions above, I recommend using SNS to deliver push notifications to iOS, Android and Kindle Fire devices.

SNS talks to GCM to deliver notifications to android devices. Here is what SNS can offer you.

Simple API to send notification to heterogeneous platforms.
Manages application registration_ids. As a developer you don't have to worry about change of registration_ids.
Scales really well. You don't have to worry about managing infrastructure if your app becomes super popular.
Can tolerate GCM downtime & throttling.

这篇关于推送通知:为什么使用Google的GCM / FCM上的Amazon SNS?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆