我是否需要为 GCM 第 3 方服务器的第二个 SENDER_ID 创建一个新项目?

Do I need to create a new project for second SENDER_ID for GCM 3rd party server?

我有 GCM(Google 云消息)XMPP 连接 运行 Android 应用客户端和 Ubuntu 服务器。服务器文档 (https://developers.google.com/cloud-messaging/ccs) 讨论了发布 (gcm-xmpp.googleapis.com:5235) 和预生产 (gcm-preprod.googleapis.com:5236) 来自服务器的 GCM 连接之间的差异。但是,本节中的措辞指出消息是根据 SENDER_ID 而不是 URL:port 路由到服务器的,服务器已在以下位置注册:

The CCS XMPP endpoint runs at gcm-xmpp.googleapis.com:5235. When testing functionality (with non-production users), you should instead connect to gcm-preprod.googleapis.com:5236 (note the different port). Regular testing on preprod (a smaller environment where the latest CCS builds run) is beneficial both for isolating real users from test code, as well as for early detection of unexpected behavior changes. Note that a connection receives upstream messages destined for its GCM sender ID, regardless of which environment (gcm or gcm-preprod) it is connected to. Therefore, test code connecting to gcm-preprod.googleapis.com:5236 should use a different GCM sender ID to avoid upstream messages from production traffic being sent over test connections.

由于 SENDER_ID 是项目编号,这是否意味着我需要创建启用 GCM 的项目的第二个版本以 运行 我的 GCM 3rdp 方的生产和预生产版本服务器并发?

根据以上评论,我创建了产品的新测试版本并为测试项目生成了服务器凭据。一旦 android 客户端的测试变体使用测试服务器的 SENDER_ID 重新注册 GCM,它们就能够使用新的测试服务器发送和接收消息。生产服务器和测试服务器在网络上 运行 并行,测试客户端和生产客户端路由到适当的服务器。