iOS APNS 开发 [沙盒] 与生产 [英] iOS APNS Development [sandbox] vs Production

查看:50
本文介绍了iOS APNS 开发 [沙盒] 与生产的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

伙计们,我在弄清楚 APNS(推送通知)开发人员(沙盒)和生产模式之间的主要区别时遇到了一些麻烦.特别是我有以下问题:

Guys I'm having some trouble figuring out the key differences between the APNS (push notification) Developer (Sandbox) and Production modes. In particular I have the following questions:

1) 我可以在应用商店中启动一个只注册了 APNS 开发者证书的带有推送通知的应用吗?或者我是否需要使用 APNS Production 来处理我想在应用商店中启动的应用?

1) Can I launch an app on the app-store with Push Notifications that is only registered for the APNS Developer Certificate? Or do I need to use to use APNS Production for apps I want to launch on the app store?

2) 一般来说,除了开发 APNS 上的开发"和生产 APNS 上的生产"之外,还有哪些功能性原因会影响我的决定.特别是为什么我会选择为我的应用程序实施 APNS 开发人员证书,为什么不只在生产推送帐户上运行所有内容?

2) In general, what are the functional reasons other than "development on development APNS" and "production on production APNS" that would inform my decision. In particular why would I choose to implement an APNS Developer certificate for my app at all and why not just run everything on a Production push account?

以下是 Apple 在其网站上的说明,但并未触及我问题的核心:

Here's what Apple says on it's website but it doesn't get to the heart of my question:

开发:使用开发环境进行提供商应用的初始开发和测试.它提供与生产环境相同的一组服务,但服务器单元的数量较少.开发环境还充当虚拟设备,支持模拟端到端测试.您在 gateway.sandbox.push.apple.com 上访问开发环境,出站 TCP 端口 2195.

Development: Use the development environment for initial development and testing of the provider app. It provides the same set of services as the production environment, although with a smaller number of server units. The development environment also acts as a virtual device, enabling simulated end-to-end testing. You access the development environment at gateway.sandbox.push.apple.com, outbound TCP port 2195.

生产:在构建提供者应用的生产版本时使用生产环境.使用生产环境的应用必须满足 Apple 的可靠性要求.

Production: Use the production environment when building the production version of the provider app. Apps using the production environment must meet Apple’s reliability requirements.

推荐答案

如果您想将您的应用发布到应用商店,您将需要使用生产供应配置文件,因此所有通过 APNS 开发者证书发送的通知将不会到达您的应用使用生产配置文件签名.

If you want to post your app to the app store you will need to use a Production Provisioning Profile, therefore all notifications sent with APNS Developer Certificate will not arrive to your app signed with a Production Provisioning Profile.

为什么不只使用生产 APNS 证书?好吧,您可以这样做,但是...

Why not use only a production APNS certificate? Well you can do this but...

  • 为了进行测试,您需要使用 Production Ad Hoc Provisioning Profile 构建您的应用,这需要大量额外的编译工作
  • 在开发中使用生产证书,因此使用临时构建,您无法使用调试器运行.使故障排除非常痛苦.
  • 测试通知使一切都投入生产,因此您必须格外小心

这篇关于iOS APNS 开发 [沙盒] 与生产的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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