Webservice delay

S

S.Berwanger

Hallo NG,

I use a Webservice to exchange data between a server and Wince 5.0 devices.
When the first call is making from a mobile device or after some times
without calling WS function then there is a big delay (15-20s).


Has anyone a solution to reduce or better to eliminate this delay?
I am using VS 2008 / SP1 and CF 3.5.

Thank you for your answer,

sb
 
C

Chris Tacke, eMVP

Yes, this is well known to occur. The CF has to generate hte proxy on the
first call. The typical recommendation is to make a call on a worker thread
as soon as your app starts, which will generate it. Even if you just throw
away any result from it. That way when you need to make the call in a
timely fashion, it's all set up.


--

Chris Tacke, Embedded MVP
OpenNETCF Consulting
Giving back to the embedded community
http://community.OpenNETCF.com
 
S

Simon Hart [MVP]

As Chris says also if the Web Service is managed code, then it will need to
be jitted for the first time. Search for async processing.
 
S

S.Berwanger

Hallo Chris and Simon,


Thanks for your answers,

but I am not sure if this is a solution for my application.
The mobile device is a scanner and the location is always changing. As a
result the device has not permanently a connection.
So each time the device has lost the connection i have this delay befor the
exchange starts.
Is there no way to eliminate this delay?
If I use a desktop client then there is no delay.

Thank you for your answer,
sb
 
P

Paul G. Tobey [eMVP]

And you move your desktop client around to match what the scanner is doing,
losing connection, etc? It's not fair to say that "Here on this machine
that's connected to a wired Ethernet switch on my desktop I don't see that,
but on this wireless scanner device that is constantly roaming from one
wireless network to another, it doesn't work as well". Of course it
doesn't. You need to architect around that. If you're doing some operation
with the Web service in the user interface thread (when a button is pushed
or something), don't do that. Do the Web service operation in a background
thread and, when a new transaction should be done, notify that thread in
some way. This keeps your user interface responsive, but allows for the
case where you're out of contact with the network.

Paul T.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top