01-17-2013 03:19 AM - edited 01-17-2013 03:47 AM
Hello dear development adisor.
As you recomended I create a new thread regarding PUSH service on Blackberry 10.
What we have:
- we have an android app that works fine with PUSH;
- we convert it using blackbery command line tools into bar file;
- inside bar file we add at "android" folder a configuration file android.cfg, as we have also our application blackberry version we also have official blackberry credentials to work with PUSH service and we try to use them, as they are legal and official, our configuration file:
<?xml version="1.0" encoding="utf-8"?>
<android>
<push>
<appid><our_app_id></appid>
<ppgurl>http://pushapi.na.blackberry.com</ppgurl>
<tokenprefix></tokenprefix>
</push>
</android>
- we add at the MANIFEST.MF file appropriative permission:
Entry-Point-System-Actions: _sys_use_consumer_push
- we sign bar file using command line tools and received from the blackberry sign keys;
- we appload application at the device and get next results:
- application successfully registered at PUSH server;
- when application exit other users can see it as online, this means that we are in push;
- when some one send us a message, from a blackberry push server we get an answer "The request has been accepted for processing"
- the message never deliver to application.
Another unsuccessfull example, this time we try to use Blackberry 10 SDK for Adobe AIR. We use Native SDK tool to monitor device logs:
in the IDE, in the Target Navigator view, right-click the device target -> click Launch SSH Session -> in the terminal that appears type "slog2info -w".
What we does:
- we use official example;
- we use same blackberry push enabled credentials we specified above (app_id and ppg_url);
- when connect via Wi-Fi and launch app at Blackberry 10 device it does next:
- app registering successfully:
msg::createChannel
id::createChannel_1464438156
dat:json:{"providerApplicationId":"<our_app_id>"," targetKey":"sample.pushreceiver.invoke.push","dNam e":"Blackberry10.AIR.PushApp.debug.testDev_shApp_d ebugd926e770","perimeter":1,"ppgUrl":"http://pushapi.na.blackberry.com"}
msg::onCreateChannelComplete
id::createChannel_1464438156
dat:json:{"token":"<received_token>"}
- we initiate at our web side a message but app never receive it;
- when connect via BIS and launch app at Blackberry 10 device it does next error "Create channel failed as the push transport is unavailable. Verify your mobile network and/or Wi-Fi are turned on. If they are on, you will be notified when the push transport is available again."
Please help us to find out a point of problem and solve the issue.
Best regards.
Yuriy.
01-17-2013 11:25 AM
Hi Yuriy,
Did you add 'bb' in the tokenPrefix element?
Do you have any other apps on the device that are using this same push account? Note that if you try to use the same account in 2 applications simultaneously you will run into issues when trying to register.
Are you testing using a production or evaluation account?
01-18-2013 04:16 AM
01-18-2013 08:26 AM
The token prefix has nothing to do with the credentials, it is used so that you can differentiate a BlackBerry device. Could you clarify what happens when you try to specify it?
For the AIR application, could you try deleteing then resetting the device and try again? The device registration may have gotten into an odd state.
Also, what OS build are you using?
01-18-2013 09:14 AM
01-18-2013 09:25 AM
Thanks for the clarification.
If you close the application then send the push, does the application eventually launch in a minimized state? (trying to determine if the Push arrives to the device but not the app)
01-18-2013 09:33 AM
01-18-2013 09:37 AM
No need to monitor at this point, and from the above you only stated that the Native SDK was used for the AIR app which failed to create the channel. For clariity, can you confirm that you have tested the same for Android?
If so please run a subscription query on the device PIN being used and let me know the response from the BlackBerry Push Server.
01-18-2013 02:31 PM
01-18-2013 02:33 PM
Please run the autoloader from here to restore your device:
https://developer.blackberry.com/devzone/blackberr