09-26-2008 04:30 AM
I am using 8100 simulator to test my application. In my application, there is a login screen which takes user name and password and connects to server for the authentication. I am using HTTP connection. When I click on login button and my app start comunicating to server, at this time if I get any incoming voice call, the voice call screen is popped up and after finishing the call, again my login screen displays but can't complete the connection and returns the error after the default time out (which is 120 seconds). I again click on Login button, still it doesn't work. This happens 2 to 3 times and suddenly after 3 attempts, it starts working and can connect to server and can authenticate the user! This problem also occur on the device.
Can anyone pleas guide me to solve this issue?
09-26-2008 10:52 AM
09-27-2008 03:46 AM
That is correct that at a time we can have only one channel, either voice or data. So, it is expected that voice calls interrupt network connections.
I am using BES for my connection. Whenever I try to connect to the server using HTTP connection, if the server doesn't respond for 120 seconds (which is a default time out), the HTTP connection returns null and comes out of the try block. So, the same thing is happening whenever I get an incoming call at the time when some communication is going on with server. During these 2-3 tries, I just couldnt not hit the server at all and the HTTP connection returns null and comes out of the try block.
I tried the same thing with default browser. I tried opening www.google.com and simulated incoming call. It couldnt connect once the call is over, I had to try again and it worked second time. So, I wonder why my app needs 2-3 attempt to get the connection again?
09-29-2008 09:27 AM
09-29-2008 10:38 AM
Yes, deviceside=false is being taken care of as I've been using it since long. The only problem is created when I got an incoming call. After the phone call is finished, my app tries to connect for the default time out which is 120 seconds. And I am displaying a dialog alert after 120 seconds saying "connection doesn not exist, try again." So, after that dialog appears, I again click on Login button, I am not able to connect. I can only connect after 2 such attempts. Or if I wait for around couple of minutes before I click on Login button again. My app doesn't try to connect while the call in progress. (In fact, it cannot connect as the data channel cannot be accessed while voice call in progress.)
09-29-2008 12:40 PM
What BlackBerry model and handheld software version are you testing on?
When you mentioned you were not able to reproduce this with the BlackBerry Browser, can you verify how you were testing this? Were you manually opening the browser and loading a web page or were you invoking the browser using the BrowserSession? The first method may not be happening quick enough to reproduce the issue.
Are you making your connection right after a user hangs up or after the callDisconnected method of the PhoneListener? It does take a few seconds for the network to disconnect a call after a user hangs up, but it should be faster than a few minutes.
09-29-2008 01:28 PM
I am using JDE 4.2 and testin on the 8100 simulator.
When I tested with BlackBerry Browser, I did it manually. I didnt use BrowserSession. And yes, you are right that if I manually check, I can't reproduce the issue.
Yes, I am making my connection right after a user hangs up. And because of that only this issue arrise. If I wait for some time after a user hangs up, the issue doesn't arrise at all.
So, does it mean, user has to wait for sometime after the call ends? Isn't there any other way, I can solve this issue?
09-29-2008 02:41 PM
You may have to wait a few seconds for the network to disconnect the call, however it should not be a few minutes.
Are you only seeing this in the BlackBerry Simulator or on a real BlackBerry as well? If it is only with the BlackBerry Simulator it could just be a network simulation issue.
09-29-2008 02:48 PM - edited 09-29-2008 02:49 PM
Initially, when I was running my app on 8100 device, I suddenly got a call and that time only I came to know about that issue. And then I try to reproduce it on the simulator and the also I could see that issue.
Anyway, thanks a lot for your responses. So, we conclude this thread that anyhow we have to wait for some time after the call ends before trying to connect again.