04-11-2013 07:09 AM
I am trying to use push notifications for OS < 7.X .
I downloaded the sample server / client code. I deployed the client code on my device and the low-level-sample code on the tomcat provided.
For the record , when i registered for push notifications here i registered using the BIS option. Now that i was actually given a blackberry i was informed it is using BES ( i dont think though this is the root of the problem that i am going to describe..).
On the device , in the sample application i put all the correct settings given from the email i received.
Both my pc which is running the tomcat server and my phone are connected to the same wifi.
I am trying from the device browser to connect to the server , eg https://188.8.131.52:8443/low-level-sample
and the browser opens the page normally , meaning that i am able to connect to my server from the mobile.
Now when i hit register from the device sample app ( i have tried both BIS/BES options on the settings ) , i always get the following error :
Request to register failed. Cause by java.io.IOException: Network operation[Subscribe] failed. Make sure that Content Provider URL is accessible.
In the log i get :
Opening URL: my server url appended with info like username/password/model/connection type etc
Content Provider network command [ Subscribe] failed , caused by could not connect to 184.108.40.206:8443
Command "register" failed with error: java.io.IOException: Network operation[Subscribe] failed. Make sure that Content Provider URL is accessible.
A thought is that i should register again for new push keys and use the BIS/BES option instead of only BIS , but here the problem seems to be no connectivity with the local server , not the RIM server. I already tried to register though and i am waiting for the mail with the new settings.
Also i am a bit confused with the BIS / BES option. I have no idea if my users will have BIS or BES enabled so what do i put in my code ?! In the sample application it asks me to select between BIS or BES but when the app is going to production and i need to programmatically make that choice what will i choose?! Or this choice is made only for the evaluation/development of the app and on production there is another server ?
04-11-2013 08:36 AM
It has to be an externally accessible URL. Did you try turning off Wi-Fi on your phone and using the cellular network to access the URL in your browser?
BES means that you are developing your application for enterprise - companies that have a BES installed that their employees are on.
BIS means that you are developing your application for the general public that anyone can use.
Which one matches what you want to do?
04-11-2013 12:07 PM
Ok for sure my server is not externally accessible so i will try do right now.
About the BIS/BES now... I am developing an application for the public. Obviously most of them will have BIS as they are simple users. To develop this application though i was given a BB with a SIM card with BES enabled. I have absolutely no authorization on our BES Server , actually i dont know anything about it. I only know that i need to develop the app for BIS but using this device that they provided me.
04-11-2013 12:17 PM
You would need a BIS service plan to properly test the application you're developing for the general public.
You would have to ask to see if your device has one on it.
If it doesn't, then you can't really use it for testing purposes.
04-11-2013 01:15 PM - edited 04-11-2013 01:17 PM
How could i explain that to my supervisor with technical details?
When i told them that , he told me that the "whatsapp" application for example is working and get the push , so that means that i have push enabled. Someone else told me that even if i have BES on my phone , i dont need to use the BES server , but i could use the BIS server too , is that true? At last how can i check if i have BIS on my device along with BES?
*The problem is that i am not a BB developer neither is my SuperVisor. But i need to use technical details on why what we already have is not suitable.
04-12-2013 03:36 AM - edited 04-12-2013 04:27 AM
Yes i can both with 3g and wifi.
BUT i could also do that with an older BB/SIM i was given that didnt have BIS/BES though...
And i know it didnt have , cause there was nothing on the service book about it , and next to the 3g signal i was not getting the BB sign. In the new phone/sim that i was given i can see that sign.
My service book looks like this , if it helps :
Do you think that it has BIS enabled?
04-12-2013 10:42 AM - edited 04-12-2013 11:00 AM
So what could be the problem for the error i am getting? I mean does really the server need to be in a public ip? And ok lets forget the server , i just want my phone to connect to BIS take the token and send a push to it with a php script. Could you help me with that? I am trying to send a push with a php script i get code 1001 that means it was sent but i can never see anything on my phone. Through this script i use the details i got from RIM in the mail and as address i put push_all , or the PIN number of the phone. However i dont understand how is it possible to send a push without having a token?! Or an application?? You can just push something on BB only with the PIN ? And if yes why i dont see it? I just need to make sure at first if the BIS is even working. Do you have a sample php script that i could use to test if i get push?
Should i use the the credentials i already have , which are for BIS or ask for new ones that use BES/BIS ?
04-12-2013 11:11 AM
If you're using our sample, then you do need your server to be accessible from the Internet to complete the registration part.
You have to have an app on your device that has successfully registered to receive pushes.
Otherwise, you will net get anything in the app.
You said you wanted to create a general public app so you should stick with the BIS credentials.
Your issue seems to be on the device-side not with your server-side PHP script.
You need to be able to successfully register from the device-side.