Silverlight

Silverlight’s Broken Promise

14 commentsWritten on November 20th, 2011 by
Categories: Opinions, Silverlight

By now, I'm sure you've all read about the rumors that the upcoming Silverlight 5 might be the last release of Silverlight. Of course, people who've been paying attention to the Silverlight news coming out of Microsoft and the blogosphere in the past year shouldn't be surprised at this. But for those of you who are still in the "oh please, it's just a rumor" camp, you might want to keep in mind that every negative rumor about Silverlight of the past year has turned out to be true. As a result, I fully expect the upcoming Silverlight 5 release to indeed be the last stop along a troubled line.

Plenty of Silverlight developers were concerned that their investment in the technology would end up being worthless. I never really understood that since I've always believed that good developers focus on skills that are transferable to multiple technologies instead of betting it all on a single technology. Nevertheless, many Silverlight developers were up in arms, but their worries and fears seem to have been calmed by the news that Windows 8 will make extensive use of XAML. Silverlight developers will be able to transfer their XAML skills to building Metro apps and of course, WP7 apps. And there's no reason to assume that Microsoft intends to change its smartphone platform in a way that would diminish the importance of XAML. So, Silverlight developers who were worried that their skills will be worthless don't really have anything to worry about and I'm sure many of them are quite relieved by that. After all, many Silverlight projects will be able to run as native apps on Windows 8 with relatively minor modifications.

Of course, that doesn't quite offer a solution to the thorny little issue about all the Silverlight projects that have been developed because of some of the benefits that Silverlight promised: cross platform and browser-independent availability of the plugin. The promise was that you could develop projects that would be available to users no matter what platform or browser that they were using (believers of this promise would even mention Moonlight, which has never really offered a truly compatible version), and with no deployment-related issues. After all, users only needed to have the Silverlight plugin installed to run your software. And that promise has been broken. Yes, you can migrate your Silverlight projects to Windows 8. Yes, people will be able to keep running existing Silverlight projects as long as they have the upcoming Silverlight 5 runtime installed. But we also already know that the Metro version of IE10 will not run the Silverlight plugin and that running the plugin in the 'desktop' version of IE10 will require users to install it themselves. For enterprise software, that's not much of an issue but you do have to ask yourself: how long are you willing to hang on to a plugin that Microsoft itself is no longer interested in improving in the long run?

The reality of the matter is that your Silverlight products only have a future if you convert them to WinRT so they can run on Metro natively. Which means you've lost the ability to reach users on multiple platforms and devices. The very same technology you picked because of its cross-browser and cross-platform benefits has forced you on a path where in the future, you can only target users on the Windows platform meaning either Windows 8 or WP7. Sure, you can hang on to the fact that the plugin will be available for a few more years, but that also is a limiting choice since an ever increasing number of users will be running iOS and Android, and there's no reason whatsoever to expect the plugin to actually run on those platforms. Hell, WP7 doesn't even have the Silverlight plugin for its browser. My previous employer pretty much bet it all on Silverlight, mostly because they didn't want to deal with HTML/JavaScript, but also because they thought it would eventually be available on all devices. Which essentially means they're stuck with a couple of products that only really have a long-term future on Windows 8 or WP7, and its subsequent versions. Unless of course, current promises about said platforms are broken again. Yet another reason to start taking open standards and technologies that have multiple stakeholders seriously, I suppose.

Yet Another Nail In Silverlight’s Coffin?

18 commentsWritten on June 4th, 2011 by
Categories: Opinions, Silverlight

As i'm sure you know by now, Microsoft caused a bit of a stir in the .NET development community with their recent 10 minute demo of Windows 8. More specifically, the fact that they explicitly mentioned HTML5 and JavaScript as one of the ways to build these new-look Windows 8 applications while neglecting to mention Silverlight or WPF left a lot of developers wondering what the future holds for both Silverlight and WPF. An interesting thread showed up on the Silverlight forums where Silverlight developers expressed their fear for the future of their platform. I've been following that thread with a lot of interest, not only because the statements and behavior displayed in that thread are both hilarious and astounding, but because i wanted to see how Microsoft would react to it.

Surely, if the core audience of one of their most-touted technologies of the past years started to doubt the future of their platform so openly, a response to calm down the fears would have to be forthcoming, no? The only Microsoft employee to respond was Pete Brown, and i thought it was quite telling:

You all saw a very small technology demo of Windows 8, and a brief press release. We're all being quiet right now because we can't comment on this. It's not because we don't care, aren't listening, have given up, or are agreeing or disagreeing with you on something. All I can say for now is to please wait until September. If we say more before then, that will be great, but there are no promises (and I'm not aware of any plans) to say more right now. I'm very sorry that there's nothing else to share at the moment. I know that answer is terrible, but it's all that we can say right now. Seriously.

Followed by:

Guys, I've been pretty clear that my hands are tied here, so don't read anything more into my lack of comments than that. We simply aren't allowed to say anything about this. It's not that we have nothing to say. It's not that we don't care. It's not that I personally don't care, because I do, a lot.

And finally:

This whole thing has blown way out of proportion. Base your information on our primary sources (like our press release), not on third party speculation. That's not to minimize how everyone feels, but keep in mind that Windows 8 itself is still a ways off from retail, and even much further away from internal IT adoption. The 8 weeks until //build/ is a pretty small amount of time to wait in comparison. Take some vacation time this summer, and look forward to the //build/ conference. Stop speculating based on just a small demo of some very cool new technology. Tell your management to do the same: if they're basing your project work for the next X years on the results of a quick demo for an unreleased operating system, then they are doing you and your company a real disservice.

If i were still a Silverlight developer, i'd find the final sentence quite insulting. If anything, Microsoft is doing a sizable portion of their customers a disservice by being so unclear about the future of one of their technologies. This certainly isn't the first storm to come up about Silverlight's future, and every time people have openly questioned the future of the platform Microsoft has responded rather softly. There's never been a convincing and strong "we are fully committed to making Silverlight a smart choice for the future" kind of response. And this time, no response at all. Just silence. Deafening silence even, because of Pete's remark that they are not even allowed to talk about it. Once again, the Silverlight community is screaming for a real response and they're being ignored. They're being told to wait until September.

Obviously, i don't know what Microsoft is planning for Silverlight, but i really have difficulties understanding how any company could still trust it as a viable technological choice. First the mixed messages, then the clear favoritism Microsoft is showing towards HTML5 and JavaScript (which, IMO, is justified but that's another topic), and now the unwillingness to stand up for one of their products that is being doubted so openly, for the first time by its very users who only want assurance of Microsoft that their investments in the technology haven't been a total waste. I took a lot of flack from the Silverlight community when i scored Silverlight so low in the 'strategic' department in my post where i detailed how we came to the conclusion to go with HTML(5) instead of Silverlight but this recent PR fiasco kind of validates that score IMO.

However, Microsoft certainly isn't the only one to blame here. If you read the thread i linked to, you'll see some reactions from people who've pretty much put all of their eggs in the Silverlight basket and are now reacting angrily towards Microsoft. If any of those people are reading this, allow me to quote myself from 2 posts that i wrote over 6 months ago:

If however, your product is supposed to become the basis of your long-term success, then the choice of Silverlight over HTML/CSS/JavaScript is short-sighted and ultimately flawed for a number of reasons. The first of which is that Silverlight is a proprietary technology in the worst possible way. Its future will be determined by a single company who naturally hold their own best interest at heart, and not yours. As long as it makes sense for them to keep improving Silverlight, they will and you can benefit from that. As soon as it no longer makes sense for them, the technology will become increasingly irrelevant. Obviously, that is a risk that you face with any kind of technology. Sticking with open standards and open source software might very well result in the same outcome but there is one tremendously important difference here: with Silverlight, you have no migration path.

That quote was from 'Keep Your Eyes On The Road', written in September 2010. And the next quote is from 'Developers Shouldn't Specialize', written in October 2010:

There's also another factor to keep in mind, which is more important than you might realize. If you specialize in technology from commercial vendors, you need to keep the market forces in mind that could influence the vendor. Those market forces might be (or seem) irrelevant to you, but the vendor will not let that influence its decisions and strategies if the vendor itself is competing with other companies on a much larger level than your company or your clients are. And when a vendor changes tactics due to market forces, the technology you've chosen to specialize in might be on the way out, or it might no longer be the hot new thing that you can capitalize on. And that is where one of the biggest dangers in specialization lies. If you're specialized in a specific technology, you're personally invested in it. Your current standard of life, your livelihood, depends largely on that specific technology. Sure, you can move on to something else but you will have to get used to less than you're used to, probably both in money and stature for a while. Realistically speaking, odds are high that you are emotionally attached to this technology because of this. When you are confronted with bad news regarding the technology's future, you're likely to exhibit classic denial symptoms. The recent news about the Silverlight strategy shift and specifically the reactions to it, is a beautiful example of this.

Anyone who's upset at Microsoft about this has only himself to blame. You've put yourself in this position, because the writing has been on the wall for a while now.

Why We’re Going With HTML(5) Instead Of Silverlight

140 commentsWritten on March 6th, 2011 by
Categories: ASP.NET MVC, Silverlight

I recently had to research which UI technology would be the best choice for the applications that my client is going to build in the next couple of years. This is a .NET shop, so there are 2 major directions you could move into: standards-based web development, or Silverlight. When you have to recommend one over the other, you ideally want to be able to back up your choice with more than just some opinions. So we made a list of candidates and did a POC for each one. Then we came up with a list of criteria, grouped in a bunch of categories. The criteria were all assigned a weight, and we scored each of them for all candidates.

In this post, i want to go over the categories of criteria, and discuss our findings. I'm also going to share the spreadsheet so you can go through the numbers yourself. Depending on your needs or your opinions, you can change the weights and the scores and see how that affects the outcome. I removed some of the criteria that were specific to my client, but it didn't have a significant impact on the outcome. For this post, I also limited the candidates to ASP.NET MVC 3 in combination with the jQuery family (jQuery Core, jQuery UI and jQuery Mobile) and Silverlight.

Here's a quick listing of the categories and some of their criteria (for the actual list, check the spreadsheet... the link is at the end of the post):

  • User experience (compelling UI, accessibility, intuitive/ease-of-use, accessible from multiple devices, accessable from multiple platforms)
  • Infrastructure (easy/flexible deployment, monitorability)
  • Security (safe from XSS, CSRF)
  • Performance (server footprint, client-side resource usage, asynchronicity, UI responsiveness, initial load times)
  • Code/Architecture (maturity, reusability of validation logic, simplicity, maintainability, flexibility, power, testability, i18n, feedback cycle, learning curve, potential efficiency, rapid application prototyping, readable URLs, extensibility)
  • People (limits the number of required skills, mindshare, documentation, community support, commercial support)
  • Strategic (future-proof, standards-compliant, differentiator, backing, vision)
  • License (do we have access to the code?)
  • Cost
  • Tools (IDE support, availability of extra tools, free 3rd party component availability, commercial 3rd party component availability

Depending on what you or your organization requires, some of these might not apply to you. Perhaps there are other criteria that you find important and that we missed. Nevertheless, i think this is a pretty comprehensive list which covers most of the factors that you need to think about when making this kind of decision.

This graph visualizes how both technologies scored, grouped by category:

I'm sure there are quite a few things about that image that surprise you. The first thing you might be thinking is "how can Silverlight score so badly when it comes to User Experience?". The answer to that is quite simple: if your users aren't using a desktop/laptop with Windows or OS X on it, there is no experience to be had at all. Users that require assistive technology are out of luck as well since accessibility support in Silverlight is still very poor. If you hold those factors into account, it really doesn't matter much that you can easily make Silverlight applications incredibly flashy (pardon the pun). Besides, most people get bored and annoyed with excessive animations rather quickly, so you're often better off not to overdo it. With that in mind, jQuery UI and HTML5 will easily meet your needs for that kind of stuff.

Another area where Silverlight scores very poorly is the strategic department. The fact that it's not standards-compliant obviously hurts a lot here, but there's more to it than that. First of all, the mobile story (again) pretty much kills it. Android and iOS don't support it. We already know it's never going to work on iOS and as long as it doesn't work on iOS, Android has no reason whatsoever to provide support because Silverlight simply isn't important in the grand scheme of things to any of the important players. Microsoft hasn't even announced a Silverlight browser plugin for WP7 yet and who knows if it will? That means that Silverlight web applications aren't usable on any mobile device right now, except for slates running a full Windows OS which looks like its only a tiny portion of the market. Secondly, despite its original tagline of "Lighting up the web", it appears that Microsoft only has about 3 scenario's in mind where it still actively pushes Silverlight: internal business applications, video streaming and native WP7 development. While internal business applications are certainly a large part of what we're going to do in the next couple of years, we're also going to build things that are available publicly and to a large variety of people. Going with Silverlight for the internal applications and HTML(5) for the public-facing applications wouldn't be very cost-efficient either since that means we have to train our developers for both cases. And it wouldn't make much sense anyway since HTML(5) is a great fit for internal business apps as well.

But, as you can see, there are areas where Silverlight scores better than ASP.NET MVC 3 with jQuery. For instance, when it comes to Tools, you can't deny the fact that Visual Studio and Blend cover a lot of ground when it comes to the whole Silverlight developer experience. At the very least, you can mostly stick to your familiar integrated environment, whereas with standards-based web development, you're likely to spend some time in Firebug or Google Chrome's developer tools instead of sticking almost entirely with Visual Studio. I personally don't mind (at all actually) to use other tools than Visual Studio, but there are quite a few .NET developers who do prefer to stick with Visual Studio. Which brings me to the People category. The biggest benefit that Silverlight has over standards-based web development is that you only need to know C# and XAML. With standards-based web development, you have to know HTML, CSS, JavaScript and the language of your server-side technology, in this case also C#. This might impact your ability to find new developers so Silverlight does have sort of an advantage there. Though i'd argue that you're better off in the long term with people who are willing to step out of their comfort zone instead of clinging to what they know. From a security point of view, Silverlight also scores better because you don't really have to worry about common issues such as XSS, CSRF and other vulnerabilities that are common in web-development.

So we have 3 categories where Silverlight scores better than ASP.NET MVC3/jQuery but that's far from sufficient to close the gap. Based on the weights we assigned to the criteria, the maximum possible score is 732. ASP.NET MVC3 with jQuery scored 568. Silverlight scored 304. Obviously, the results will vary depending on what you find important. Which is why we asked an analyst from one of those large IT research & advisory companies to give us some feedback on this. The analyst agreed entirely with our findings and our data, and confirmed that his company is recommending moving towards HTML5 to all of their customers. He even went as far as to say that Silverlight is hard to recommend, unless you're not targeting any mobile users and the applications are internal-only and you've already invested in the technology. I can't provide a link for any of this yet, but a paper about this will be published soon so i'll either link to it when it's out (if it's publicly available) or at least reference it.

I encourage anyone who is faced with the same decision to use the spreadsheet and modify it to your needs (adding more criteria, changing weights and/or scores, whatever) to see which one is the best fit for your situation. You can download the spreadsheet here.

Do You Still Believe In Silverlight?

16 commentsWritten on October 30th, 2010 by
Categories: Silverlight

Unless you're not really paying attention to what's going on in the Silverlight world, you probably already heard that Microsoft has confirmed a shift in strategy for Silverlight:

I asked Bob Muglia, the Microsoft President in charge of the company’s server and tools business, that very question and got what I consider to be the clearest answer yet about how Microsoft is evolving its Silverlight strategy. “Silverlight is our development platform for Windows Phone,” he said. Silverlight also has some “sweet spots” in media and line-of-business applications, he said.

It's the development platform for Windows Phone (more on that in a minute). It has some sweet spots in media and business apps. Things sure can change a lot in a short time. Silverlight was at first positioned as an ideal technology for media. After that, it was increasingly being marketed as a great platform to develop business applications, cross-platform ones even. Now, despite the fact that nothing has been taken away from the platform's capabilities, it has some "sweet spots" in both areas where it was supposed to be a great technological choice. Every single feature or capability that once formed Microsoft's message that it was great for business applications is still there. And they won't take that away either. The mere fact that their message about Silverlight has transformed so much now, is incredibly telling. If you're a Microsoft customer who's invested a lot in Silverlight for business applications, you have some pretty good reasons to be upset about this.

After all, given how the stated goals of Silverlight have evolved in the past 3 years, who's to say those "sweet spots" will remain interesting enough for Microsoft? I have no doubt that they're going to heavily invest in making Silverlight a great development platform for Windows Phone (whether they will succeed at it is an entirely different matter though), but what you need to develop great mobile applications differs a lot from the needs you have when building great business applications. Will the needs of developers using Silverlight to create business applications be met by Microsoft? Let me rephrase that: keeping the manner in which they're now promoting HTML5 in mind, will they also keep putting additional resources into improving some niche areas of a technology who's primary purpose is to facilitate mobile development? Maybe they will. Maybe they won't. I sure as hell wouldn't bet on it.

Now, unlike a lot of people, i don't think that Silverlight is dead. Far from it even. Silverlight has a future as long as Windows Phone has one. Its real future lies in the mobile world now, and no longer in the browser or on the desktop. It's going to keep working in your browsers, and its going to keep working on your desktops. But you really need to wonder how many of the needed improvements for those 2 environments you'll see being introduced to Silverlight, and how long it'll take. It's quite reasonable to assume that improvements in Silverlight which target the mobile development story will be receiving higher priorities than those which target the browser or desktop development model. After all, that is what the new Silverlight strategy implies. And given Microsoft's need to conquer a respectable position in the mobile world, and their ever increasing support of HTML5, it only makes sense for them to do so.

As for Silverlight being a suitable platform for mobile development, i can't help but wonder whether it really can live up to the high expectations that people will set on it. Anyone who's done any serious Silverlight development knows that it is a technology which suffers from a lot of memory usage problems. Partly because there are quite a few memory leaks in Silverlight's own controls, but also because the Silverlight programming model easily leads to a lot of dangling references which will lead to serious memory problems in a memory constrained device such as a mobile phone. Unless they get rid of the memory problems very quickly, i can easily see Windows Phones suffering from a lot of problems as people start using more and more 3rd party applications on their phones simultaneously. Well, it would have to support running multiple applications simultaneously before it'll be a real problem, but you know that's only a matter of time.

So, as for me personally, i don't really have a lot of belief left in Silverlight as a technology. I don't see it advancing much more in the browser or on the desktop, and i think it's got some real, difficult challenges ahead in the mobile world. What do you think?

Silverlight Getting Worse When It Comes To Memory Leaks

15 commentsWritten on August 19th, 2010 by
Categories: Memory Management, Silverlight

A coworker of mine spent some hours yesterday hunting down memory leaks in an app that he'd already gotten 'leak-free' back when it was in Silverlight 3. Turns out that the leaks are caused by changes in Silverlight 4 and not in our code. As you surely know, Microsoft releases major Silverlight versions pretty frequently (there's at least one major new version each year). That's great and all when it comes to introducing new features and capabilities, but it truly sucks if you keep introducing new problems as well. The total amount of time (and thus, money) that we've lost hunting down leaks that are located in either the core Silverlight code or the Control Toolkit (also Microsoft code) is just starting to become embarrassingly high.

To give you an idea of what kind of leaks that keep popping up, be sure to check out these links: http://forums.silverlight.net/forums/t/179177.aspx http://forums.silverlight.net/forums/t/179358.aspx http://forums.silverlight.net/forums/t/180702.aspx http://forums.silverlight.net/forums/t/181257.aspx http://forums.silverlight.net/forums/t/171739.aspx

If anyone from Microsoft reads this: please, pretty please, pretty please with sugar on top: can we get a little bit more QA from you guys? If you can put out products like WebMatrix and LightSwitch, than surely you must have enough resources available to make sure that your real development platforms do not become a cost-sink for your customers due to your own lack of quality control, no?

Update: it's also quite telling that the search phrase "silverlight memory leak" is the number one search phrase through which people get to this site. #justsaying