简体   繁体   English

Google PubSub和GCM

[英]Google PubSub and GCM

My project has a requirement of pushing notifications to android mobile phones based on certain events. 我的项目需要根据某些事件将通知推送到android手机。 (I need a gcm) (我需要一个gcm)

Users of the mobile phones can subscribe to these events and hence I need a pub/sub. 手机用户可以订阅这些事件,因此我需要一个发布/订阅。

Now, google pub/sub service can help me build the pub sub but it can only 'push' notifications to an HTTPS DOMAIN server, which we don't have. 现在,google pub / sub服务可以帮助我构建pub sub,但是它只能将通知“推送”到HTTPS DOMAIN服务器,而我们没有。 Is there a way I can direct google pub/sub push service directly to the gcm, which then can push it to the respective mobile phones? 有什么方法可以将google pub / sub push服务直接定向到gcm,然后可以将其推送到相应的手机? (assuming its all google in the background and hence must have this facility) (假设其所有Google在后台运行,因此必须具有此功能)

You can push directly to your mobile topic subscribers. 您可以直接推送到您的移动主题订户。 Take a look at GCM PubSub: https://developers.google.com/android/reference/com/google/android/gms/gcm/GcmPubSub 看看GCM PubSub: https : //developers.google.com/android/reference/com/google/android/gms/gcm/GcmPubSub

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM