Hi-

We've built an Android application that accesses data services using
HTTP requests and we have noticed that the initial HTTP requests over
a WiFi connection usually take much longer (up to 1000 times longer)
than subsequent requests. This doesn't happen on 3G.

We have spent a fair bit of time collecting data and so far we seem to
have identified a fairly specific set of circumstances where this
occurs.

Here are some observations:

1) When we create a new HTTP client, the first request takes anywhere
from 20 milliseconds to 20000 milliseconds (yes 20 seconds!),
subsequent requests with the same client usually take about 20
milliseconds. The average for the first request is 5500 milliseconds
or so.

2) Occurs only on some WiFi access points, not all of them and not on
3G. We have a relatively new access point in the office (linksys
WAP4011N) that is the worst offender, the problem does not occur with
my older access point (belkin F5D7230) at home.

3) We've  observed the problem with three different Motorola Droid
Sholes phones all running 2.2. We've looked at Droid X, Droid Eris,
Samsung Galaxy Tab and have not seen this issue in any of them.

4) It's not DNS, we've snooped the traffic and the DNS requests come
back right away. If we use the IP number instead of the DNS name for
the server, we still see the problem and snooping shows no DNS
requests are made.

5) It's not the server, we've tried using 5 different servers
including www.google.com and we see the issue on all of them.
Interestingly, the longest delays seem to occur on the servers that
respond the quickest.

So my questions:

1) Anyone else noticed this behavior?

2) Anyone have any ideas what is going on?

3) Anyone have a fix? :-)


I've poked around a little in the API hoping to find something to tune
in the WiFi hardware, but I haven't found anything there.


I have a small test app that illustrates the problem and if anyone is
interested, I'll post it.

Bill

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to