mirror of
https://github.com/NohamR/knowledge-kit.git
synced 2026-05-25 04:17:17 +00:00
docs: 批量博文
This commit is contained in:
28
Chapter1 - iOS/1.33.md
Normal file
28
Chapter1 - iOS/1.33.md
Normal file
@@ -0,0 +1,28 @@
|
||||
# 推送
|
||||
|
||||
> 1、现在 App 开发推送功能,一般都是接入极光推送,那么为什么极光推送就可以实现推送呢?
|
||||
2、极光推送做了哪些事情?与 APNS 怎么交互的?
|
||||
带着这2个问题来看看推送吧
|
||||
|
||||
## 一、推送原理
|
||||

|
||||
|
||||
(这张图转载于网络)
|
||||
|
||||
|
||||
|
||||
说说推送的步骤:
|
||||
1、你的 App 需要推送服务,要向苹果的 APNS 注册推送功能
|
||||
2、当苹果 APNS 推送服务器收到你的注册请求后会返回给你一串 device token
|
||||
3、当应用收到 device token 后,需要将 device token 传给自己的应用服务器(自己公司的服务端)
|
||||
4、当你需要为你的应用推送消息的时候,自己的应用服务器会将消息,以及 device token 打包发送给苹果的 APNS。
|
||||
5、APNS 再将消息推送给你的 手机 App
|
||||
|
||||
|
||||
## 不接入极光推送的话,自己怎么做推送功能
|
||||
|
||||
参考这篇文章:[自己做推送](https://blog.csdn.net/shenjie12345678/article/details/41120637)
|
||||
|
||||
## 所以极光推送逗帮我们做了什么?
|
||||
|
||||
简化了获取 device token 的步骤,我们将申请号的证书上传到极光服务器,程序运行接入极光 SDK ,手机获取 device token, 然后将 device token 上传给极光推送服务器,。
|
||||
Reference in New Issue
Block a user