3

我使用标签处理 Urban Airship 推送通知。对于每个新安装 UA 在观众下维护新的 App ID。在我的应用程序中,我有两个登录选项:1.Male 2.Female

从 UA 我通过添加适当的标签发送消息。

情况1:

  • 在第一次安装时,在观众下,我的设备注册了选定的标签(我登录为男性)和 APP ID。

  • 在这种情况下,一切正常。

案例2:

  • 如果我从设备中删除了应用程序并再次安装并以不同的用户身份登录(例如:女性)。

  • 现在在观众下,我的设备注册了女性标签和新的应用程序 ID。(现在我的设备在UA下注册了新的APP ID)

  • 如果我通过添加所需的女性标签从 UA 发送推送,则将收到的推送推送到我的设备。

  • 但在少数情况下,设备也会收到来自男性标签的消息。

观察:

  • 现在在 UA 下,我的设备有两个带有两个不同标签的 APP ID。

  • 可能是,由于这个原因,我的设备收到了两个标签消息,而与所选标签无关

需要解决方案:

为什么android每次新安装都要维护新的APP ID?

如何在新安装之前从 UA 中删除我的设备以前的 APP ID

(或者)

如何用新的 APP ID 覆盖以前的 APP ID

笔记:

我在设备中安装了集成推送通知的应用程序。使用 APID 注册并保持 Active 为 True 的设备。

重新安装 App 后,新的 APID 生成并显示为 True。但是,之前 APID 的 Active 状态仍然保持为 True。为什么以前的 APID 的 Active 状态没有更改为 False。

在 IOS 中,新安装后以前的 Device Token 的状态变为非活动状态。为什么只在android中发生?

提前致谢..

4

1 回答 1

2

城市飞艇支援队的回应:

每当您卸载和重新安装应用程序时,Android 设备都会获得一个新的 APID,这只是因为 GCM 的工作方式以及我们的系统如何处理它。如果这给您带来不便,我们深表歉意,但是是的,这是预期的行为。一旦你尝试推送到旧的 APID,我们的系统就会意识到之前的安装不再是活跃的,并且应该将旧的 APID 标记为非活跃的。新的将保持活动状态。

If you uninstall and reinstall an app fast enough, you may experience behavior like you saw, where one last push to an old tag for the old APID gets through. The old APID will then be marked inactive by our library if this occurs, and it should not happen again for that installation. We find that this is extremely rare in production and is only ever an issue during testing.

If you want to manually deactivate the old APID that you know is no longer active, just push to it directly and GCM will give us feedback that it is no longer valid. We will no longer attempt to push to it after that point.

最后,您使用的是什么版本的库?请确保您使用的是最新版本:http: //urbanairship.com/resources/developer-resources——旧版本无法可靠地处理此行为。

于 2013-09-19T04:33:20.277 回答