08-08-2012 02:28 AM
Things seem to work on both sides:
1.) My server application returns:
Response CODE: 1001 Response DESC: The request has been accepted for processing.
2.) My client (running on the dev alpha, built with WebWorks 10.0.1.6) says "Successfully registered" using the "Public/BIS" setting, my app ID and the PPG URL containing CPID.
But: nothing happens in terms of: I don't get any notification when the app is running and it won't start if it's closed.
Is there any method to "debug" this?
Do you have any idea?
08-08-2012 04:09 AM
For clarification, here's my config:
BB10 push client config:
PHP push server:
I did not use the port # given in my push services registration e-mail anywhere.
Perhaps these pieces of information help...
08-08-2012 03:05 PM
We just checked the eval push logs and it looks like your pushes are being delivered to the device. They just don't seem to be making it to your application for some reason. We'll have to investigate some more to see if this issue is unique to you.
In the meantime, could you please send a confirmed push (change the delivery method to "confirmed"). This will allow us to know if the push is even reaching your application.
One thing to note about the address tag. Using a value of "push_all" means a push will be sent to all devices that have apps on them that have reigstered with your application ID (I'm guessing it's just one for now). Just something to note for the future.
You also mentioned trying the device PIN. Although this works for now, it might change in the future, so you really should be using the "token" you get back from the createChannel call in your WebWorks push-enabled application.
You're right about the port. It doesn't matter for BlackBerry 10 anymore.
08-09-2012 04:37 AM
Thanks for your reply and investigations.
I switched to the confirmed delivery method as advised. Nothing changed so far.
Additionally I tried to query the status (<statusquery-message>) of one of my messages, but since I'm on the free service I always get a
"The request was refused. Status Query is not supported by your Push Service."
Oh, and when it comes to using PINs for addressing devices in the request, you should consider updating the "BlackBerry Push Access Protocol Development Guide" found here.
08-09-2012 03:14 PM
I looked up your confirmed push in the eval logs and it looks like it can't reach the application for some reason (the error code is 4502). It is getting to the device though.
What OS version do you have on your Dev Alpha? Have you upgraded it recently? Push definitely wasn't fully supported for these devices until recently.
Good catch for those docs. We'll work on updating those to be clear about the use of tokens for BlackBerry 10.
08-09-2012 04:27 PM
My Dev Alpha is on 10.0.6.386, the most recent update that came out a couple of weeks ago.
Is it possible to check if my app registered successfully with the server? The app says "Creating push channel" > "Successfully registered" not only for my cpXXXX (with my four digit CPID), but also for every other ID like "cpXXX" (the value from my push services registration email).
Oh and one thing I noticed: the token I get returned from a successful registration is identical to my device PIN. Is that subject to change, too? Or something specific to the evaluation server?
08-09-2012 04:34 PM
Yep, sounds like you have the correct OS build. I'm going to try to see if I can reproduce the issue myself.
With the eval environment, although the URL you hit is different based on your content provider ID, the underlying eval database will be the same for everyone. Your app and device are successfully registered to receive pushes. It's just a matter of getting to the bottom of why the push doesn't get to the app. It wouldn't have been able to even get to the device itself if the registration hadn't been successful.
Yep, the token currently matches the device PIN at the moment, but this is subject to change in the future.
08-10-2012 10:09 AM
I just tried with a Dev Alpha device and I am able to successfully receive pushes.
But, after receiving the pushes, I can't seem to swip out of the app.
Seems to be a weird quirk on the Dev Alpha devices.
Can you try keeping the app open and in the foreground when you send the push to it?
And, let me know what happens.
08-10-2012 05:45 PM
Weird. My app does not receive pushes wheather it's running or not.
I'm basically using a slightly modified version of the WebWorks sample code.
My additions / changes to the codebase include:
Fact is: the event listener (common.js, line 484) gets added, but the onInvoke callback (line 506) is never executed.
Could one of my changes have messed things up? I couldn't avoid these (and just use the example code), because signing fails with the following error message (and debug tokens don't work for me for some mystical reason):
Oh Snap! Build request failed with message: [ERROR] Error: Code signing request failed because the Invoke-Target-Key [sample.pushcapture.invoke.target] has been previously used in a different package. [ERROR] Error: fail: 1Error: fail: 1 [ERROR] Native Packager exception occurred
I could mail you my code if you think that helps and DM me your email address...
08-13-2012 08:56 AM
Your additions / changes look correct to me. Just curious, what app ID are you referring to that was previously "pushsample"?
Yes, that signing error is expected. The documentation will be updated shortly to be clearer about changing the invoke target ID in your app if doing signing. Basically, the signer enforces that every app has a unique invoke target ID to avoid the possibilty of getting another app's invoke event.
Just to rule any of your changes out, if you just change the invoke target ID in config.xml and common.js (and leave the rest of the sample unchanged), do you still not receive pushes?
I still have a couple of ideas about what might be going on. I will try them out today and let you know by tomorrow morning.