Hi,
I have never worked with gSOAP, but have already worked a lot with
networking in Palm OS. There is a very well known limitation in the Palm
stack that may be related to the problems you are facing with gSOAP. The
Palm stack supports only 16 sockets open at the same time. With all
these sockets open, the stack gets completely useless until you restart
the network.
So, in order to write a network program in Palm OS, you have to be
very carefull about closing sockets. And remember that simply closing a
socket is not enough. The default behavior is to keep the socket open
'lingering' after you close it. So you may have to make sure to
configure the socket to avoid lingering. There is a function to set this
option. But once again, beware. This function has a bug in some version
os the Palm OS. If you want to go on with your software, I suggest you
to search this forum's archive for reference to socket lingering.
Luciano
ps.: this explains why the bug is not reproduced in the simulator.
It does not have the 16 sockets limitation.
[EMAIL PROTECTED] wrote:
(For some reason I can't contribute to another thread I created, so I'll just
create a new one)
Hello,
I finished writing up my gSOAP app for Palm OS that connects to a .NET Web Service. I have been testing and debugging it using various Palm emulators and simulators and never had any problems.
Now, I'm testing the program on a real Treo 600 connecting to the internet via the phone service, and on a Tungsten 5 utilizing a Palm wifi card. The problem I'm having is that my calls to the web service seem to be failing randomly about 1/10 of the time and. In addition, after the failure, all internet traffic on the Palm is blocked until I reset the connection, or wait about 2-3 minutes.
Also, the sample Palm applications that come packaged with gSOAP have the same problem. They fail randomly and completely knock out the internet connection until you reset it.
Since I can't get these problems to occur on the emulators and simulators, I don't really have a way to debug the code. The only error information I am getting is gSOAP is returning the error text "HTTP/1.1 200 OK".
I have used a tool called SOAPScope to monitor all SOAP messages going across the connection to the server, and it picks up all of the SOAP messages until it fails. So the SOAP message at the failure doesn't actually make it to the server.
I've tried introducing time delays in between the soap calls, and creating new soap objects for every soap call, but the problem still exists.
I've also tried looping until failure on a single web method, and it will always fail at some point. However, if I run this looping code on the emulator/simulator it will go indefinately with no problems.
From my point of view, it looks like gSOAP just plain doesn't work for Palm OS, and this is quite frusterating seeing as how I've spent over a month working on an application that utilizes it.
It's too bad the simulators didn't pick up these issues.
Does anyone have any experience with gSOAP, or can anyone provide any insight
into what the problem may be?
Oh, and I'd appreciate it if someone could try running the sample gSOAP apps on
their Palm to see if they enounter the random failure bug. You can download
them here:
http://www.studentlogbook.com/gsoap_sample_apps.zip
Thanks.
--
For information on using the PalmSource Developer Forums, or to unsubscribe,
please see http://www.palmos.com/dev/support/forums/