We are rewriting the network stack to to make it portable and eliminate its dependency on WinInet and WinHTTP. We have completed a significant portion of that work. This document describes the remaining work in the rewrite as well as the new features we are planning to add. We support the Basic, Digest, and NTLM authentication schemes. The remaining work is:
We also need to review the interaction between HTTP authentication and disk cache. For example, cached pages that were downloaded with authentication should not be retrieved without authentication. HTTP cache performance improvementsMake the HTTP cache and disk cache fully asynchronous so that they will never block the IO thread. Right now the HTTP cache is serving the metadata synchronously. Throttle the requests. The remaining work is:
Web SocketsBackend support for HTML 5 Web Sockets is being implemented. New unit tests and performance testsSome parts of the network stack, such as SSL, need more unit tests. Good test coverage helps bring up the Mac and Linux ports. In addition, any bugs that get fixed should get unit tests to prevent regression.We should add performance tests to measure the performance of the network stack and track it over time. Better histogramsWe need better histograms for networking. We should be able to detect and respond to network changes, such as from wired to wireless networks, across wireless networks, and getting on or off a VPN. Integrate loader-specific parts of WebKit into the network stackParts of WebKit that throttle and prioritize resource load requests could be moved into the network stack. We can disable WebCore's queuing, and get more context about requests (flesh out the ResourceType enum). When the maximum number of connections to a server is exceeded, pending transactions need to wait for their turn in a queue in ClientSocketPool. We give main frames and sub-frames a higher priority than sub-resources to speed up page layout. The remaining work is to give images a lower priority than other sub-resources (css, js, etc.). We should support loading resources in the background (for example, for updating the thumbnails in the New Tab Page) without impacting real-time performance if the user is doing something else. We should support dynamically adjusting priorities. If the user switches tabs, the newly focused tab should get a priority boost for its network requests. We should implement an optional pipelining mode. Late binding of socketsDo not bind a new socket to an HTTP transaction until the socket is connected to the server, so we can use a keep-alive socket if it becomes available sooner. ProxiesMove the evaluation of proxy auto-config scripts out of the browser process for better security. The new cross-platform FTP implementation is used on Linux and Mac, and starting in Dev channel release 4.0.203.2, it is used by default on Windows. The remaining work includes rewriting the directory listing parser, reusing control connections, and caching directory listings. We need to be able to request FTP URLs through a proxy. Preference service for network settingsWe strive to use the system network settings so that users can control the network settings of all applications easily. However, there will be some configuration settings specific to our network stack, so we need to have our own preference service for those settings. See also issue 266, in which some Firefox users demand that we not use the WinInet proxy settings (the de facto system proxy settings) on Windows. We should investigate what it takes to make our network stack reusable by other projects. We need to implement IPv6 extensions to FTP and proxy auto-configuration scripts. |