BlackBerry Push Notification registration time

旧时模样 提交于 2019-12-12 10:23:53

问题


So i register my App with BlackBerry and i could receive push msgs but after a certain time around (3 hr) i try to push to the device again but no luck, then i have to register again with BlackBerry so i could receive pushes.

what is the time that i need to be register again and is that related that i have a development credentials not a production one ?


回答1:


Registration should be persistent. But RIM's servers are sometimes flaky: are you seeing this happen consistently?

Are you using OS 5.0.0 or earlier? If it's the older OS versions, you need to make sure your listening thread is always running. For 5.0.0 and above, the OS takes care of this for you.

Another thought relates to confirmed delivery and application acknowledgment. If you are using this level of service (available for either Push Plus or Push Essentials), but your application is not acknowledging the notification, RIM may mark your device as suspended and won't send it any further notifications.

The default is to use the UNCONFIRMED delivery method. If you're using RIM's server-side SDK in Java, and you have code like this:

pushMessageControl.getQualityOfService().setDeliveryMethod(DeliveryMethod.CONFIRMED);

Or if you're not using their SDK, but have the following in your push request XML:

<quality-of-service delivery-method="confirmed"/>

Then you need to call the following in your BlackBerry app in the notification handler:

pushInputStream.accept();

The pushdemo sample device application that is part of the Push SDK supports optional application acknowledgment, so you should study that code to see what to do.



来源:https://stackoverflow.com/questions/4935310/blackberry-push-notification-registration-time

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!