Category Archives: web authoring

Is Safari the world’s fastest browser? You need to test more than just JavaScript

Apple says its new Safari 4 is the world’s fastest browser:

Still the world’s fastest web browser, Safari outraces Firefox, Internet Explorer, and Chrome. On even the most demanding Web 2.0 applications, Safari delivers blazingly fast performance thanks to the industry’s most advanced rendering technologies.

Using the new Nitro Engine, for example, Safari executes JavaScript nearly 8 times faster than Internet Explorer 8 and more than 4 times faster than Firefox 3 based on performance in leading industry benchmark tests: iBench and SunSpider.

In addition to superior JavaScript performance, Safari offers top-flight HTML performance — the best on any platform — loading pages 3 times faster than Internet Explorer 8 and Firefox 3.

Adrian Kingsley-Hughes at zdnet has tested Safari vs Chrome and IE8, and says Apple’s claims do not stand up to scrutiny. In his tests, Chrome is faster. Unfortunately, he used a different build of Chrome than Apple – 2.0.172.30 vs 2.0.172.28. In addition, he is using a quad core processor, Intel’s QX9770, whereas Apple is using an iMac with a Core 2 Duo processor. Chrome is still work in progress on the Mac, so the results for this are on Vista.

ZDNet’s results certainly cast doubt on Apple’s figures. On the SunSpider JavaScript test, used by both, Apple quotes 609.07ms for Safari vs 870.00ms for Chrome, whereas zdnet has 808.8ms for Chrome and 846.2ms for Safari.

That said, JavaScript performance is not the same as browser performance. If you read Apple’s claim carefully, it talks about rendering technologies and HTML performance as well as the JavaScript engine. Focusing exclusively on JavaScript would be like assessing the performance of Windows vs Mac, for example, simply by timing some number-crunching operations.

In practice, what users care about is the time it takes to load a page and its responsiveness thereafter. Apple claims its best advantage over Chrome in i-Bench HTML, claiming that Chrome takes 40% longer. Unfortunately I cannot currently find the test which Apple used, but I’m presuming it tests DOM rendering speed rather than just non-visual JavaScript performance; an earlier i-Bench HTML used actual web sites.

Bottom line: I don’t trust Apple’s figures either, but I’m retaining an open mind. You need to compare like with like, and not focus exclusively on JavaScript, to test browser performance.

Update: Blogger Luca Filigheddu backs up Apple’s claims with some real-world tests.

Adobe’s Flex Builder to Flash Builder name change does not go far enough

As expected, Adobe is strengthening its “Flash Platform” strategy by renaming the forthcoming Flex Builder 4 (codename Gumbo) to Flash Builder 4:

This change will provide better naming consistency for the Flash family of tools and position Flash Builder as the development tool for the Flash Platform.

This is only a name change, nothing more. Flash Builder will still be based on Eclipse, and the original Flash Professional IDE, also part of Creative Suite, will continue as before.

My question: why doesn’t Adobe go further in clarifying and promoting its Flash brand? The current situation is still confusing:

Flash Builder vs Flash Professional: the names give you no clue about the difference. Why not Flash Developer and Flash Designer?

Adobe AIR (Adobe Integrated Runtime): non-techie people do not realise this has anything to do with Flash. Flash Desktop Runtime would be better, though I guess that would not reflect the option for HTML applications. It would do a lot to promote Flash as more than just a browser plug-in.

Flex SDK: why retain the Flex brand at all? I presume the name was originally a contraction of Flash and XML, but since it is a language that compiles to Flash, this could just be called the Flash SDK.

Name changes themselves are confusing of course, so I’m surprised that Adobe is not being more thorough now rather than risking more piecemeal changes later.

New York Times switches from WPF/Silverlight to Flash and AIR for Reader 2

The New York Times has released Version 2 of its Times Reader, for seamless online/offline viewing of its content. It’s interesting from a media perspective, but hardly a breakthrough, since it is not new. What’s more interesting to me is that the Times switched from a hybrid approach using WPF (Windows Presentation Framework) on Windows and Silverlight on the Mac, to Adobe AIR. Switches like this are bad PR for Microsoft, since it gives the impression that the developers were sufficiently unhappy with WPF/Silverlight, or so strongly attracted to AIR, that they were willing to throw away much of their previous development effort.

I’ve been tracking Times Reader for some years. It was presented at Microsoft Mix07 and I wrote up a panel discussion on the subject:

I asked about the cross-platform issue. According to Bodkin a Silverlight implementation is on the way, which includes most of the features in the full version, in “a matter of months.”

That was optimistic; but a Silverlight version was delivered and I used it successfully on the Mac; though it lacked some features of the WPF edition. It also attracted hostility from Mac users who are Microsoft-averse, as I reported here, and apparently ran into further problems because of incompatibility with Safari 4.

I tried the new AIR edition and it seems pretty good, though my impression is that it is not quite as smooth as the old WPF version. I might be wrong, since I could not install both on the same machine. The new version does add video support. Here’s the old one:

and this is the new effort:

I think this is a fascinating case study which demonstrates a number of things.

First, that cross-platform support is not an optional feature any more (if it ever was) for this kind of public application. Let’s assume here that the WPF version was just fine for Windows users, but was not viable long-term for lack of cross-platform support. It was inevitable that the Times would eventually either use Silverlight on both Windows and Mac, or abandon both WPF and Silverlight for a cross-platform alternative.

Second, that Silverlight is not yet mature enough for this kind of application. Although the Times developers were able to deliver a Silverlight version, it required a bit of hackery for offline support (embedded Safari on the Mac) and apparently ran into version problems when Apple upgraded Safari. Silverlight is also known to be poor for text rendering – a Google search for “blurry text Silverlight” brings back plenty of hits. Adobe also made a big improvement to text handling in Flash player 10, with the new flash.text.engine.

Third, that offline support really is a big deal. Would Silverlight 3.0 have been good enough? Possibly, though I haven’t seen any suggestion that Silverlight 3.0 offline apps will be able to run in the background while showing just an icon in the notification area, to support continuous synchronization.

It is possibel that these problems may be fixed in Silverlight 4.0. That’s a long time to wait though, when you need your application out now (and your industry is in crisis).

It would be silly to extrapolate this case study into a broader statement about the superiority of Flash over Silverlight. For the specific needs of the New York Times though, it is easy to see why Adobe AIR appeals.

Is Zend really the PHP company?

I’m at Yahoo! Hack day in London – not hacking, but here for sessions on topics such as YUI (Yahoo! User Interface Library) and PHP.

I had a brief chat with Rasmus Lerdorf who is speaking later. I asked him about Zend, which presents itself as the PHP company (that is actually the slogan on its web site). Is it really?

Lerdorf says Zend has no special status. While acknowledging its contribution, he says there are 1300 PHP committers, and only 6 work for Zend. He emphasises that PHP is a community project and that decisions are made by consensus, influenced by who is actually willing to write the code, not by Zend or any company.

I also asked about PDT (PHP Development Tools), the Eclipse-based open source IDE. Lerdorf says there are lots of PHP IDEs, and people who use generic editors for PHP, and none has any more status than any other; he doesn’t use PDT.

From my perspective as press, there are only two organizations who ever encourage me to write about PHP. One is Zend; the other is Microsoft, keen to establish Windows as a credible PHP platform (Lerdorf says PHP on Windows has made enormous progress in the last couple of years). Zend does seem to do more than any other company to promote PHP for commercial and corporate development.

Lerdorf is not surprised. We’re developers, he says, we don’t do PR.

Zend’s effort is broadly beneficial to the PHP community – provided that it does not give a false impression of who owns PHP.

Silverlight: developer win, designer fail?

I posed this question in a post over on itjoblog. There are several reasons why Silverlight struggles to get designer attention, including:

1. Designers are pragmatic and target the runtime that is already deployed most broadly, ie. Flash.

2. Flash is already good enough so why bother?

3. The tools: Adobe’s designer tools are a de facto standard, target Flash, and run on the Mac.

Developer is another matter. The cross-platform .NET runtime is Silverlight’s big advantage; and this time the tools tip the balance towards Microsoft (Visual Studio) – not for everyone, but for the substantial Microsoft platform community. That’s going to be further reinforced by Visual Studio 2010 which gets full visual designer support, plus of course Silverlight 3.0.

Microsoft does have a problem with Silverlight out of the browser. Developers need a way to have these run with more local permissions, subject to user consent, otherwise they will turn to Adobe AIR. Actually the whole Silverlight on the desktop story is confused, since you can also do Silverlight Mesh-Enabled Web Applications, or stick Silverlight content in a desktop gadget or other embedded browser. No, not the one in AIR (nice idea though): Adobe only includes Flash support and the PDF plug-in.

The tension behind this is that ultimately developers and designers need to work on the same applications, so this remains a fascinating contest.

First baby steps for Moonlight 2.0: Silverlight for Linux

Miguel de Icaza has announced the first preview release of Moonlight 2.0. This is the one that counts, in that it brings the .NET runtime to Silverlight applets running on Linux:

This is the ECMA VM running inside the browser and powering C# and any other CIL-compatible languages like Ruby, Python, Boo and others. You can use Moonlight/Silverlight as a GUI (this is what most folks do) or you can use it as the engine to power your Python/Ruby scripting in the browser.

The download page has plenty of health warnings:

Keep in mind this preview release is not feature complete. Most importantly not all security features are present or fully enabled in this release. Even existing security features have, at this stage, received only minimal testing and no security audit of the source code (mono or moonlight) has yet been done.

Undeterred, I installed it into FireFox 3.0, running on Ubuntu Linux. The download is under 9 MB. My first effort was unsuccessful; the plug-in appeared to load OK, but no Silverlight apps displayed. My second attempt in a VM worked. Naturally I went along to my Silverlight database example which as it happens runs on Mono. Here it is:

This is what it should look like (Silverlight on Windows):

Well, it is only an alpha preview, and it shows. On the plus side, the data is displayed, the search works, and the buttons operate. It is a considerable achievement. But don’t plan to move your users onto Moonlight applications just yet.

Flex Builder for Linux on hold: another sign of financial stress at Adobe?

On 21st April Adobe’s Ben Forta told a user group that Flex Builder 3 for Linux is on hold, citing lack of requisition, which is corp-speak for lack of demand.

Note that the Flex SDK does run on Linux. It is just the official IDE that is in question.

Linux is a free operating system, and this could be evidence that users of a free OS are less likely to purchase software than users of a paid-for OS. Or it could simply reflect poor market share for Linux outside servers. Even if it has just hit 1%, as hitslink reports, it is still barely more than 10% of the Mac share and a little over 1% of the Windows share. Some of those Linux machines will also be netbooks – secondary systems for users with a Windows or Mac for serious work such as design and development.

Nevertheless, I suspect there is more to it than that. I suspect Adobe would like to support Linux, because it wants to portray Flex as an open platform – the SDK is open source, though managed by Adobe, but the runtime engine is closed-source and proprietary. This may be another sign of Adobe’s financial stress. The company reported reduced quarter-on-quarter revenue for the the 3 months ending February 2009, and has been cutting staff numbers.

The backdrop to this, in contrast, is that Adobe is having great success with its Flash platform. There is no sign of Microsoft’s Silverlight denting the popularity of Flash on web sites, either for applets or media streaming.

The recession then? Partly; but this is also about Adobe’s business model. Adobe does not break out its figures in detail as far as I know: the last financial statement merely shows that its revenue is nearly 95% from product sales, the rest being services and support. Still, I’d guess that the largest component of its product sales must be Creative Suite. In other words, its business model is based on selling tools and giving away runtimes. When 47 million people watch Susan Boyle on YouTube, Adobe doesn’t make a penny, even though they are almost all using Flash to do so.

The tools market is a difficult one for various reasons, including competition from free products and the fact that the number of people needing development or design tools is always much smaller than the number needing runtimes. In a recession, deferring a tools upgrade is a obvious way for businesses to save money. Remaining primarily a tools company is a limit to Adobe’s growth and ultimately its profitability.

This is of concern to all Flash platform users. Adobe has proved to date a good steward of the technology. Some of us would like the balance of proprietary vs open tilted further towards open, but I doubt many would welcome a takeover or merger such as we have seen with Sun and Oracle (and there are a few parallels there).

There would also be many cries of “foul” if Adobe sought to further monetize Flash by starting to sell, say, a premium version of the Flash runtime.

Adobe is still a profitable company, and maybe when the economy recovers all this stress will be forgotten. Still, I’d guess that long-term Adobe will want to shift away from its dependency on sales of tools; and how and what it does to achieve that will have a big influence on the future of its RIA (Rich Internet Application) platform.

Faking synchronous web service calls in Silverlight

I ran into a small but thought-provoking problem in my sample Silverlight database application. I wanted to call a web service, and only call a second web service if the first was successful. The problem is that all web service calls are asynchronous, so you cannot do this with a simple if statement. The quick fix I used was to store my intended operation in a PendingOperation variable. When the first web service completes, it checks for a pending operation. If the first call succeeds and finds a pending operation, it calls the second web service to complete it.

My workaround is OK, but it got me thinking about the best way of doing this. What if you had a sequence of web services to call, and wanted to check for the success of each one before proceeding to the next? I discussed this on the Silverlight forums and was directed to this article by Daniel Vaughan which describes how to do this in a background thread. I haven’t tried his code yet; but it strikes me that this could be useful; I’d like to see Microsoft build something like it into the core framework. Since all the calls take place on a background thread, there is no danger of locking up the user interface.

If RIA programming is as important as some suggest we will have to get used to this kind of problem.

A Silverlight database application with image upload

I’ve been amusing myself creating a simple online database application using Silverlight. I had this mostly working a while back, but needed to finish off some pieces in order to get it fully functional.

This is created using Silverlight 2.0 and demonstrates the following:

  • A bound DataGrid (as you can see, work is still needed to get the dates formatted sensibly).
  • Integration with ASP.NET authentication. You have to log in to see the data, and you have to log in with admin rights to be able to update it.
  • Create,Retrieve,Update,Delete using ASP.NET web services.
  • Image upload using Silverlight and an ASP.NET handler.
  • Filter a DataGrid (idea taken from here).
  • Written in Visual Studio 2008, and hosted on this site, which runs Debian Linux, hence Mono and MySQL. Would you have known if I had not told you?

You can try it here. I’ll post the code eventually, but it will be a couple of months as it links in with another article.

MVP Ken Cox notes in a comment to Jesse Liberty’s blog:

Hundreds of us are scouring the Internet for a realistic (but manageable and not over-engineered) sample of manipulating data (CRUD operations) in a Silverlight 2 application. There are promising pieces of the puzzle scattered all over the place. Unfortunately, after investing time in a sample, we discover it lacks a key element – like actually saving changed data back to the database.

I can safely say that mine is not over-engineered, and that yes, it does write data.

Microsoft’s quarterly results: will it ever make sense of the cloud?

Most comments on Microsoft’s quarterly results are understandably focused on the overall picture: a quarterly revenue decline for the first time ever.

Revenue decline can be forgiven during a recession, but it’s more interesting to look at the breakdown. I made a simple quarter-on-quarter table to look at the pattern:

Quarter ending Mar 31st 2009 vs quarter ending March 31st 2008, $millions

Client Revenue % change Profit % change
Client (Windows) 3404 -15.6 2514 -19.29
Server and Tools 3467 7.07 1344 24.44
Online 721 14.47 -575 -154.42
Business (Office) 4505 -4.78 2877 -7.99
Entertainment and devices 1567 -1.57 -31 -129.25%

The weak Windows client figures are unsurprising. The poorly-received Windows Vista is out in the market, and the highly-praised Windows 7 is being prepared for release. When anyone asks me, I suggest that they should wait for Windows 7 before buying a new PC or laptop, if they are in a position to delay.

The Business division (Office) remains massively profitable, even though it too has declined a little. Office may be ludicrously expensive, but there’s little evidence of a significant shift to cheaper or free alternatives.

It’s also notable that the server and tools business continues to perform well. Again, I’m not surprised: Server 2008 strikes me as a solid product, and there’s not much wrong with products like SQL Server 2008 and Visual Studio.

Not much to say about entertainment and devices. Xbox is doing so-so; Windows Mobile is rather a mess.

The real shocker here is the online business. Revenue is down and losses have grown. It is no use just blaming the recession: this is a sector that is growing in importance. Should Microsoft back out and leave it to Google? That would be as if Kodak had refused to invest in digital photography. But something is badly wrong here.

That said, I’m guessing that the figures mostly represent the failure of the various Windows Live properties to attract advertising income; the small market share of Live Search must be an important factor. The newer cloud computing business model, where Microsoft sells subscriptions to its online platform and services, is largely still in beta – I’m thinking of things like Windows Azure and Live Mesh. Further, I’m not sure where Microsoft puts revenue from things like hosted Exchange or hosted Dynamics CRM, which straddle server and online. There is still time for the company to get this right.

I’m not convinced though that Microsoft yet has the will or the direction to make sense of its online business. Evidence: the way the company blows hot and cold about Live Mesh; the way SQL Server Data Services was scrapped and replaced by full online SQL Server at short notice; and the ugly and confusing web site devoted to Windows Azure.

When I looked at Virtual Earth recently I was impressed by its high quality and ease of development. It illustrates the point that within Microsoft there are teams which are creating excellent online services. Others are less strong; but what is really lacking is the ability to meld everything together into a compelling online platform.

That could change at any time; but we’ve been waiting a long while already.