Sean’s Stuff

28 October, 2008

Session – Microsoft .NET Framework: Overview and Applications for Babies

PDC 2008, Day #1, Session #5, 1 hr 15 min.

Scott Hanselman

There’s no way that I was going to miss Hanselman’s talk.  I’m a big fan of his podcasts—Scott is one of the most knowledgeable tech podcasters out there and he can also be pretty entertaining.  I’m always amazed listening to Scott’s podcasts.  Some guest will be talking about the esoterics of some new platform or service and Scott will just “get it”, quickly grokking what the guy is talking about and end up summarizing it in a nice way.

Scott’s talk didn’t disappoint.  I got to the room early and got a front row seat.  Scott also wins the prize for speaking in the most comfy room at the convention center—the talk was in a cozy little theatre with cushy theatre chairs.

The goal of Scott’s talk was to take a spin around some of the newer (3.5 and 4.0) areas of the .NET Framework.  The vehicle was by extending his WPF BabySmash application to use as many features and services as possible.

BabySmash was the little application that Scott used to teach himself WPF.  He’s blogged about his adventures with BabySmash and learning WPF.

I didn’t take notes during Scott’s session, but let’s see if I can remember the different .NET technologies that Scott dabbled in with BabySmash:

  • Silverlight 2
  • Windows Mobile
  • Surface
  • ADO.NET Data Services
  • Entity Framework
  • New ASP.NET charts/graphs

Basically, Scott ported BabySmash to each of these platforms, or made use of the platform to add some new feature to BabySmash.  It was a great way, using a little app like BabySmash, to illustrate how these technologies fit together.

The grand finale was having all of Scott’s Twitter “minions” go to an online BabySmash web page, which collected metrics about which keys were being pressed.  Scott then displayed a live histogram on an ASP.NET page, showing the distribution of the keys pressed.  It’s a testament to Scott’s popularity that the graph grew quickly, with the frequency for some letters quickly moving into the thousands.

What’s even more amazing is that Scott said he hadn’t tested the Twitter app, at least in a broad/distributed way, until the talk.  Very cool.

I can’t really add much to what Scott writes himself.  So do yourself a favor and check him out at hanselman.com.

Session – Microsoft Silverlight, WPF and the Microsoft .NET Framework: Sharing Skills and Code

Filed under: PDC 2008,Silverlight,WPF — Sean @ 2:45 pm
Tags: , , , ,

PDC 2008, Day #1, Session #4, 1 hr 15 min.

Ian Ellison-Taylor

This session focused on sharing code between WPF and Silverlight applications.  How easy is it to take an existing WPF application and run it in the cloud by converting it to Silverlight 2?  Conversely, how easy is it to take a Silverlight 2 application and run it locally as a WPF application?

The bottom line is that it’s really quite easy to run the same application as either a local WPF application or a cloud-based Silverlight 2 app, with just a few modifications.

Ian started with a quick summary of when you’d want to use WPF vs. Silverlight 2:

  • WPF: best for desktop apps needing maximum performance and leveraging 3D graphics on the desktop
  • Silverlight 2: best for RIAs, smaller and lighter, able to run on various platforms and in various browsers

One of the more interesting parts of the talk was Ian’s description of the history of Silverlight 2.  We know that Silverlight 2 uses a smaller version (much smaller) of the .NET Framework, which it deploys via the browser, if a client needs it.

But Ian described how, in the first attempt at a Silverlight 2 framework (WPF/e at the time), they started with the full framework and started pulling stuff out.  They quickly found, however, that it made more sense to start with a clean slate and then only pull in the bits that they needed for Silverlight 2.

Applications written in WPF or Silverlight 2 can be moved to the other platform fairly easily, but Ian said that it was a bit easier to convert Silverlight 2 apps to run as WPF than the other way around.  This makes sense—WPF apps might be using parts of the full .NET framework that aren’t supported in the Silverlight 2 subset.

Also interesting, Ian suggested that developers start by learning Silverlight 2 and then moving to WPF, rather than the other way around.  Things are done in Silverlight 2 in a much simpler way, so the learning curve will likely be shorter.  As an example, he talked about the property system, which is far more complex in WPF.

This was an excellent talk, with some nice demos.  Ian worked simultaneously on a WPF and a Silverlight 2 application, adding features to one and then moving them over to the other platform.  It was an excellent way to highlight some of the differences and the gotchas that developers will run into.  But it also showed off how similar the platforms are and how easy it is to migrate an app from one to the other.

Session – Microsoft Sync Framework Advances

Filed under: Mesh,PDC 2008 — Sean @ 2:39 pm
Tags: , , , ,

PDC 2008, Day #1, Session #3, 1 hr 15 min.

Lev Novik

My next session talked about the next version of something called the Microsoft Sync Framework.  I’d never heard of the framework, prior to the talk.  And I’m still not exactly sure where it fits into the full family of Microsoft’s cloud-based services and tools.

My best guess for now is that the Sync Framework basically lives in the Live Services arena, where it supports Live Mesh.

My understanding of where the Sync Framework fits in goes something like this.  You can write an application against the Mesh Framework, allowing you to take advantage of the support for feeds and synchronization that are part of that framework.  And if you wanted data synchronization between applications that run exclusively in this framework, you’d stop there.  But if you want to synchronize data between legacy applications that were not written to be Mesh apps, you’d use the Sync Framework to write a custom sync provider for that legacy application.  This would allow that application’s data to sync up with other Sync Framework providers, or with Mesh applications.

That’s my current take on where the Sync Framework fits in, but I’ll maybe learn a bit more in later sessions.  One thing that wasn’t clear from Lev’s talk was whether Mesh itself is using the Sync Framework under the covers, or whether it’s something entirely different.

Lev talked very fast and sounded just a little bit like Carl Sagan.  But once I got past that, he did a decent job of showing how sync providers work to synch up various types of data.

The basic takeaway here goes something like this:

  • Data synchronization done properly is tough
  • The Sync Framework gives you all the hooks for handling the complexity

Lev pointed out that getting the first 80% of data synchronization working is fairly easy.  It’s the remaining 20%, when you start dealing with various conflicts, that can get tricky.

V1 of the Sync Framework has built-in providers for File Systems and Relational Databases.  Version 2 adds support for SQL Data Services and for Live Mesh.

The bulk of Lev’s talk was a demo where he showed the underlying code in a simple sync provider, synching data between his local file system, his Live Mesh data store, and a SmugMug account.

The synchronization was pretty cool and worked just like you’d expect it to.  Throughout the demo, Lev was doing a 3-way synchronization and files added, updated, or deleted in one of the endpoints would be replicated at the other two.

Lev also talked a fair bit about how you deal with conflicts in the sync framework.  Conflicts are things like concurrent updates—what do you do when two endpoints change the same file at the same time?  Lev demonstrated how conflicts are resolved in the sync providers that you write, using whatever logic the provider wants to use.

Takeaways

The Sync Framework seems a very powerful framework for supporting data synchronization across various data stores.  Out of the box, the framework supports synching between a number of popular stores, like relational databases, file systems, and Mesh applications.  And the ability to write your own sync providers is huge.  It means that you can implement synchronization across the web between almost any type of application or data store that you can imagine.

Session – Microsoft Blend: Tips & Tricks

Filed under: Blend,PDC 2008 — Sean @ 2:34 pm
Tags: , , ,

PDC 2008, Day #1, Session #2, 45 min.

Doug Olson & Peter Blois

My next session was run by a couple of the key guys on the Expression Blend team.  (Which is located in Minneapolis, if I remember correctly).  They did a quick intro to Blend and then showed various techniques for using Blend to develop WPF applications.

This was my first real view of Blend in action and it was fairly impressive.

As everyone explains, the basic idea of Blend is that it is a tool to be used primarily by designers.  Developers are expected to work primarily in Visual Studio, and designers in Blend.  The beauty of the architecture is that both tools work directly with the XAML file(s) used by the application.  So there is no converting of designer-supplied UIs into Visual Studio.

The slightly shocking thing was Peter’s main demo—he opened a sample project in Blend.  And the sample project was Blend itself.  It got a little surreal to see bits and pieces of Blend loaded inside its own designer.  But Peter proved the point that it was straightforward to work with large WPF projects in Blend.

Also notable was Peter’s quick demo of a little tool called “WPF Snoop” that he wrote.  It inspects a running WPF application and breaks it apart into its constituent visual elements.  Then came the big applause-inducing moment of the day.  Peter flipped a 2D/3D switch, and WPF Snoop rotated the 2D view of the Blend GUI into three dimensions, showing an exploded view of all visual elements in the application.  Gorgeous.

Doug and Peter’s other main theme was how easy it is for a designer to take an existing project and just restyle the various elements.  As an example, Peter demo’d a little Twitter application that he wrote and then showed the version produced by a designer that he worked with.  The impressive thing is how different the designer could make the application look, and even behave, just by changing the GUI from Blend.  This really serves to prove the point of separation of GUI and behavior through the use of two different tools.

Takeaways

  • Blend is a powerful tool and can even handle very large projects
  • It’s true that designers can significantly modify look/feel of an app without the developer being involved
  • WPF Snoop is a must-have tool

Session – A Lap Around Windows Azure, part 1

Filed under: Azure,PDC 2008 — Sean @ 2:29 pm
Tags: , , , , ,

PDC 2008, Day #1, Session #1, 1 hr 15 min.

Manuvir Das

In my first PDC session, Manuvir Das gave us some more information about the Azure platform.

He started talking about the platform for traditional desktop clients as being the operating system.  It provides a variety of services that all applications need, to run on the platform.

Windows Azure serves as a similar platform for web-based applications.  In other words, Azure is the operating system for the cloud.  It provides the “glue” required for cloud-based services.

According to Manuvir, the four main features of Azure as a platform are:

  • Automated service management
  • Power service hosting environment
  • Scalable, available cloud storage
  • Rich, familiar developer experience

Manuvir demonstrated how an Azure-based service is defined.  The developer describes the service topology and health constraints.  And Azure automatically deploys the service in the cloud.  This means that your service runs on Microsoft’s servers and is scaled out (run on more than one server) as necessary.

As a sample topology, Manuvir showed a service application consisting of a web-facing “role” and a worker “role”.  The web-facing part of the application accepted requests from the web UI and the worker role processed the requests.  When the author configures the service, he specifies the desired number of instances for each of these roles.  Azure seamlessly creates a separate VM for each instance of each role.

A developer can create and test all of this infrastructure entirely on a local desktop by using the Azure SDK.  The SDK simulates the cloud environment on the developer’s PC.  This is valuable for uncovering concurrency and other issues prior to deployment.

Manuvir also talked about Azure providing scalable and available cloud-based storage.  The data elements used for storage are things like Blobs, Tables, and Queues.  Future revs of the platform will support other data objects, including File Streams, Caches, and Locks.  Note that these data structures are simpler than a true relational data source.  If a relational data store is required, the service should use something like SQL Services—Microsoft’s “SQL Server in the cloud” solution.

Rollout

Windows Azure goes “live” this week, for a limited number of users.  It will likely release as a commercial service sometime in 2009.

The business model that Azure will follow will be some sort of pay-for-use model.  Manuvir said that it would be competitive with other similar services.

At some point, Azure will better support geo-distribution of Azure-based services.  It’s also expected to eventually support the ability to run native (x86) code on the virtual servers.

Demo

The obligatory demo by a partner featured Danny Kim, from Full Armor.  Danny described an application that they had created for the government of Ethiopia, that allowed them to track thousands of teachers throughout the country and push out data/documents to the teachers’ laptops.

This demo was again a bit more interesting as a RIA demo than a demo of Azure’s capabilities.  The only Azure-related portion of the demo involved Danny explaining that they were currently supporting 150 teachers, but would soon scale up to several hundred thousand teachers.  But they hadn’t yet scaled out, so Danny’s application didn’t really highlight Azure’s capabilities.

PDC Keynote – Windows Azure Arrives

Filed under: Azure,PDC 2008 — Sean @ 2:39 am
Tags: , , ,

I love the Terminator movies.  That’s why I need to share this fact—Skynet has finally arrived, and it’s called Windows Azure.

In short, Windows Azure is Microsoft’s platform for cloud-based services and applications. It’s a platform on which you can deploy your own applications, leveraging Microsoft-supplied hosting, service management, data services, and scalability.  It’s also the platform that Microsoft is using to host all of their subscription-based enterprise services, like Live Services and SQL Services.  (Umm, eventually, I think).

Or maybe it’s Skynet—the network that allows the machines to finally take over.  It’s hard to tell.  Maybe not—Steve Ballmer looks not a bit like the Terminator.

Because I’m not an enterprise software sort of guy, some of the stuff in the keynote made my eyes glaze over.  When Dave Thompson started demoing Sharepoint and Microsoft Dynamics CRM Services, I found myself having a truly deep I-don’t-really-give-a-crap reaction.  It’s just hard to get pumped up about timesheets and status reports.

On the other hand, there are things Ray mentioned that hint at being fairly interesting.  If the Azure platform really makes it simple to scale out a web app, that would be cool.  Or if they can provide SQL Server data services to web-based apps in a simple way, that would also be cool.

Ray was talking about two basic things today:

  • Windows Azure — the underlying platform for cloud-based services
  • Microsoft’s services that are based on Azure

For Azure as a platform, the mom-and-apple-pie speaking points are attractive:

  • Move Microsoft’s expertise for scaling web-based apps into a platform
  • Easy to scale up/out
  • Easy to deploy globally  (i.e. not just to server sitting in some city)
  • Federated identity, allowing enterprise identities to move into cloud

Ray also showed the various Microsoft services that will be available to applications/organizations, and which run on Azure:

  • Live Services
  • .NET Services
  • SQL Services
  • SharePoint Services
  • Microsoft Dynamics CRM Services

Live Services—seems to be the “kitchen sink” category.  Possible pieces include Live Mesh for synchronized storage, and interop with other Windows Live bits, like Messenger and Photo Gallery.  Maybe I missed something, but I don’t think that Muglia really talked about this box.  More info on Live Services here.

.NET Services—Muglia touched briefly on these higher-level application services that are built on top of Azure.  They include: Service Bus (connect applications over the Internet), Access Control (federated identity based on claims), and Workflow Service (running Workflow in the cloud).  More info on .NET Services here.

SQL Services—SQL Server “in the cloud”, available to your web apps.  This is basically just a subscription model for SQL Server, where you “pay as you go” and get access to SQL Server data stores in a scalable fashion.  For more info, go here.

SharePoint Services—blah blah blah enterprise blah blah

Microsoft Dynamics CRM Services—see SharePoint Services

Oslo

I forget who was talking at the time, maybe Muglia or maybe Ozzie.  But on one of the high-level slides included Oslo as a little blurb.  Oslo is a new platform for modeling applications and creating domain-specific languages.  Promises to be very interesting, especially given that Don Box and Chris Sells are on this team.

Demos

What would a keynote be without cool demos by Microsoft partners, who have put their gonads on the line by using the new Microsoft technologies in some production environment.  Microsofties at the keynote (Amitabh?) alluded to the need for demos by admitting that a new platform wasn’t that sexy—you really need a cool demo to see what it’s capable of.

I’m sorry to say that the main example of an application built on Azure was a British startup, bluehoo.com, whose purpose in life is for mobile users to discover other mobile users sitting near them by using a little animated blue avatar.  WTF?!  We already have that application.  It goes like this: a) stand up; b) turn to your right; c) extend hand; d) introduce yourself.

Bluehoo.com seems a major fail.  The demo didn’t really show off any of the true Azure goodness that was being touted.  The closest it came was their CEO saying that he’d have to go tweak his Azure configuration to bring more servers online.  Maybe they might have done some sort of animated load testing to prove their point?  Worse yet, the bluehoo.com site is DOA—nothing more than a linkback to a twitter feed.  Ugh.  Bluehoo would have made a fine Silverlight 2 demo, but as an Azure demo it was pretty thin.

Takeaways

As lackluster as the demos were, the rollout of Azure really is a big deal.  Azure demos aren’t as flashy as the NBC Olympics site that was demoed with the rollout of Silverlight 2.  But Azure really is more about the back-end anyway—it’s truly a platform for developing scalable web applications.  The man on the street won’t know (or care) about it.  But for web developers, Skynet truly is here.

Blog at WordPress.com.