Patches for the new WebKit framework, dubbed "WebKit2," are due to be released shortly, according to Anders Carlsson, who works in Cupertino, Calif., on Apple's Safari browser as well as the open source WebKit engine. In addition to Safari, WebKit also powers the Google Chrome browser, the Android Web browser, and Palm's WebOS.
"WebKit2 is designed from the ground up to support a split process model, where the web content (JavaScript, HTML, layout, etc) lives in a separate process," wrote Carlsson. "This model is similar to what Google Chrome offers, with the major difference being that we have built the process split model directly into the framework, allowing other clients to use it."
In this method, each tab within a browser is "sandboxed," or existing in its own space. In essence, this means each tab is like its own separate browser. While Chrome currently does this in its own proprietary way in its WebKit-based browser, building the capability into the framework of WebKit2 would allow other WebKit-based browsers — including Apple's Safari — to employ this same technique.
Documentation accompanying the WebKit2 release noted that one goal for the new framework is to create a stable, non-blocking application programming interface. That would allow an unlimited number of threads to call an API at once, making the browser more flexible. This would be achieved, the documentation said, through a number of techniques listed below:
- Notification style client callbacks (e.g. didFinishLoadForFrame) These inform the embedder that something has happened, but do not give them the chance to do anything about it.
- Policy style clients callbacks (e.g. decidePolicyForNavigationAction) These allow the embedder to decide on an action at their leisure, notifying the page through a listener object.
- Policy settings (e.g. WKContextSetCacheModel, WKContextSetPopupPolicy) These allow the embedder to opt into a predefined policy without any callbacks into the UIProcess. These can either be an enumerated set of specific policies, or something more fine-grained, such as a list of strings with wildcards.
- Injected code (e.g. WebBundle) Code can be loaded into the WebProcess for cases where all the other options fail. This can useful when access to the DOM is required. [Planned, but not currently implemented]
26 Comments
Finally! This is great news for the safari users out there. Though, I do use Chrome on mac, and I am loving it. The more development for Webkit, the better for everyone (except Microsoft!).
I think it's great that Apple is makings split process WebKit2 open source to everyone even direct competitors like Google Chrome. Especially in light of the impression that Apple is a closed, protective company with the iPhone ecosystem and their patent claims. It's clear that Apple is focus on one, obviously making money, but two actually moving technology forward which sometimes requires keeping things close to the chest and other times requires giving it away for free for the benefit of all.
It'll be interesting to see how Apple does at next year's Pwn2Own contest with WebKit2.
Finally! This is great news for the safari users out there. Though, I do use Chrome on mac, and I am loving it. The more development for Webkit, the better for everyone (except Microsoft!).
I use Chrome more and more on Windows 7 as IE8, surprisingly, cannot handle rendering properly an ever growing number of websites. The site www.space.com blows in IE8 as an example.
Safari works fine on the Mac though. I do occasionally use Chrome when a site does not support Safari or Safari cannot rendor it properly. Can't stand Firefox though.
I use Chrome more and more on Windows 7 as IE8, surprisingly, cannot handle rendering properly an ever growing number of websites. .... Can't stand Firefox though.
It seems like Chrome on the Mac is the new Firefox (the "anti-Safari" web browser of choice), and that Firefox is on the way out unless it can change.
The sad part is that the things that Mozilla needs to change most (WebKit and support for codecs besides Ogg Theora), aren't going to happen any time soon. They will have to lose a lot more market share before they realise the stupidity of those moves.
Awesome! I love chrome for PC, but on the mac I always find Safari to be better (as in just as fast, but way more responsive). Add ons would be nice too. Kinda wish mobile safari's webkit gets a speed boost as well if possible.