I am developing a Windows Phone application that communicates with a server on a home LAN via Wi-Fi, and I encountered a traffic jam: the average travel time for a tiny HTTP request inside the LAN is 600-800 ms.
This only happens with a standalone phone. If the phone is connected to a PC running Zune, the phone starts talking through Zune, and the response time drops from 600 ms to 20 ms (!).
I wrote a small replay program that sends an HTTP request every 100ms and starts a Wireshark trace. A trace indicates that the server is immediately responding. This is a telephone that delays requests and sends from three to five requests at the same time as a packet approximately once per second.
Additional Information:
My program uses HttpWebRequest, not WebClient. I tried to create threads for each request, no luck. This happens in the WP7 release and on Mango. The same thing, regardless of whether I am running away from work or at home Wifi. The low-level implementation using the socket API in Mango demonstrates the same behavior.
I saw other posts in the App Hub with the same problem. Please help clarify why this is happening.
source share