Thankfully, however, the HTTP cache accepts data using nsIOutputStream and serves it using nsIInputStream. The HTTP cache lives in the parent process, and so any read and write operations need to be initiated in the parent process. The “privileged about content process” exists for this purpose, and is also used for about:logins and about:certificate. In order to avoid potential security issues, this requires that we sequester about:home / about:newtab in their own special content process. This means giving about:home special capabilities for populating and reading from the HTTP cache. The HTTP cache is, however, not typically queried when accessing chrome:// or resource:// URLs, so we have to do it ourselves, manually for the about:home case. The HTTP cache is usually queried by the networking stack when browsing the web. The HTTP cache is normally used for caching webpages retrieved over the network, but seemed like the right fit for storage of the about:home cache as well. There are 3 primary components to the cache mechanism: The HTTP Cache ¶ Components of the about:home startup cache mechanism ¶ It works by assuming that between browser sessions, about:home usually doesn’t need to change. The about:home startup cache is an attempt to address this expense. This is problematic during the startup sequence, as calculating that initial state can be computationally expensive, and requires multiple reads from the disk. This means that it’s important to ensure that about:home loads as quickly as possible to provide a fast overall startup experience.Ībout:home, which is functionally identical to about:newtab, is generated dynamically by calculating an appropriate state object in the parent process, and passing it down to a content process into the React library in order to render the final interactive page. Turning on Firefox tests for a new configurationīy default, a user’s browser session starts with a single window and a single tab, pointed at about:home.Custom geo, locale, and update channels.Getting Set Up To Work On The Firefox Codebase.
0 Comments
Leave a Reply. |