Performance and the Visual Studio 2010 Release Candidate

I think you'll find the performance of the Visual Studio 2010 and .NET Framework 4 Release Candidate to be vastly improved over Beta 2.

Microsoft showed wisdom and courage when it chose to delay the release to make the product better - and faster.

BTW, the RC build expires on June 30, 2010.

 

Naughty Words at Azure’s cloudapp.net (NSFW in French)

I was configuring some Windows Azure sites today. When prompted for a globally unique public name for an account, I started playing with the Check Availability button.

Not surprisingly, there’s a filter that bans the use of the common English-language curse words - plus many words that might offend sensibilities in Anglophone cultures. For example, you can’t use the URL:

http://sex.cloudapp.net/

Porn, slut, and wanker are banned words as well.

However, lesser naughty words like horny, fart, crap, and puke are allowed.

Since Canada has two official languages, I wondered whether they filtered for common French-Canadian curse words. Well, the list is quite inconsistent. For example,  crisse and ostie are banned at Azure but I was able to register the highly naughty:

http://tabarnak.cloudapp.net/

Of course there are other ways to offend using allowed words. I created the following public storage account URL:

">http://fat.blob.core.windows.net/ <grin>

Visual Studio 2010 Launch Delayed “A Few Weeks”

Microsoft has pushed out the launch of VS 2010 from the original March 22, 2010 date. In announcing the delay of the release, Soma and Scottgu talk of “a few weeks” rather than giving a new fixed date.

This is good news in terms of product quality because the performance just isn’t there in Beta 2. I expressed the fear that Visual Studio 2010 would be the bloated, sluggish “Vista” of the development world if  the responsiveness wasn’t brought back to VS 2008 levels.

Microsoft is very conscious of the issues and reports many performance “wins” post-Beta 2. Unfortunately, very few people outside MS have had a chance to evaluate the progress. Well, we’ll get that chance in February with what they’re calling a ‘Release Candidate”.

Actually, I’d have opted for a January Beta 3 rather than an RC in February. To me, an RC is an announcement that ‘we intend to ship this thing unless there’s something so bad that nobody will buy it’. A ‘beta’ tag tells testers that it’s still okay to report issues and get them fixed.

Overall it’s very encouraging that the developer division is more wired to quality than to a ship date. Let’s hope that what comes out is worth the wait.

Graffiti CMS is Now Free Open Source

Our friends at Telligent have made the ASP.NET 3.5 source code for their Graffiti CMS (content management system) available on CodePlex.

This open source project is a huge gift to the community. Wow!

Here’s part of  Telligent’s news release:

“Graffiti has a strong developer following, and we encourage those involved with Graffiti to continue to provide peer-to-peer support for one another. Users and developers can continue collaborating together to enhance the product. We look forward to seeing the innovation the open source community will bring to Graffiti.  We are especially thankful for some of the community members that stepped up and offered to help shepherd the project.“

Using a Stored Procedure in Entity Framework 4

In my latest contract, the DBA has opted to use SQL Server stored procedures for all data access. Preventing direct table access may ensure maximum security and performance - but it sure reduces the fun for the front-end guy (me).

I’d been doing my screen prototypes with Entity Framework 1 and getting pretty good at manipulating the mapped objects. Arrrgh.

Just for fun, I decided to test out EF 4 against the first stored procedure I received – Inserting a contact. It’s not difficult but you want to watch for a couple of gotchas.

When you choose the database objects in EF, you can add stored procedures. No surprise about that. What’s strange is that you’re just making the designer aware of the SPs, not actually doing anything with them. (This is unlike tables where the OR mapping is automatic.)

includingsp

For stored procedures, you need to go into the Model Browser, drill down to the Function Imports area, right-click and select Add Function Import.

addfunctionimport

I got messed up when using the Function Import because I didn’t read the dialogue box text carefully enough. My stored procedure adds a contact to the database and returns the ContactID  and a returnCode. So, I selected Scalars and an Int32 type as the return. Oops. The label says “Returns a Collection Of”. After some trial and error, I learned that the correct choice was None.

EditFunctionImport

BTW, the preceding dialogue box would be better if the combo box were at the top so you choose the stored procedure name and then the Function Import Name could default to the name of the SP you just selected.

With the mapping of the stored procedure in place, the ASP.NET 4 code is straightforward to call the InsertContact stored procedure. The ContactID comes back inside the ObjectParameter object as its Value property:

Protected Sub Page_Load(ByVal sender As Object, _
                        ByVal e As System.EventArgs) _
                    Handles Me.Load
    Dim ent As New WebApplication1.DBEntities1
    Dim objparam As New System.Data.Objects.ObjectParameter _
                        ("contactID", DBNull.Value)
    Dim status As Integer = 0
    status = ent.InsertContact(objparam, "Billy Bob", _
                               "Thornton", "Goof", "These are notes")
    Label1.Text = "Status: " & status.ToString() & " , ContactID: " _
                             & objparam.Value.ToString()
End Sub

Maybe tomorrow night the DBA will have progressed far enough so I’ll have an SP that returns a bunch of data to EF 4.

Ken

Make Parallel APIs Seamless and Almost Invisible

Microsoft Canada’s Adam Gallant gave an excellent presentation today on ‘What’s New with Visual Studio Team System and MSDN’. Among Adam’s demonstrations were the new APIs to support so-called manycore architectures. Most of us are still writing code as if we only have one processor when it fact newer machines are likely to have four of them.

The .NET Parallel Extensions supported in VS 2010 lead us into adopting these new technologies, which is fine. However, some of us at the session were wondering why this couldn’t be seamless to the developer and end user. Why not just detect if the machine has more that one processor, and if so, distribute the computational tasks automatically to the available resources?

Apps don’t generally decide how much memory they’ll use – that’s left up to the system to allocate as much as is appropriate, usually a lot.

The same should apply to parallelism commands: If the Parallel Extensions are referenced, give the running code all the power you’ve got - unless instructed otherwise. It should be seamless and almost invisible.

To borrow a joke from Jerry Seinfeld,

"Give my app the maximum allowable computing power."

"Figure out what will make it run too fast and then back it off a little bit."

Ken

On Being Blow Away by Technology

While watching Scott Guthrie, Scott Hanselman, and Brian Goldfarb demonstrate Silverlight 4, I had a range of reactions:

  • Wow! I’ve got to play with this stuff!
  • I’m feeling overwhelmed by the avalanche of technology
  • How will I find the time to do billable work and stay current with this great stuff?
  • Maybe I can convince my client to switch the app in development from ASP.NET 3.5 to Silverlight 4?

It’s all so exciting, unnerving, and, in a certain way, upsetting to be so blown away by technology.

Ken

New Machine? Nope, Just a Defrag

I run Windows Server 2008 Enterprise on my quad core development workstation to take advantage of the OS’ Hyper-V support. (More info on setting this up at http://www.win2008workstation.com/)

Anyway, Derek at Diskeeper corporation sent along an MVP freebie preview of Diskeeper 2010 so I thought I’d run a defrag overnight. This morning, it feels like I have a new machine! I know this sounds like a commercial, but I hadn’t realized how badly my system’s performance had been deteriorating over the last few months since I repaved the drive. I won’t go into all the marketing terms surrounding this technology. Suffice to say that this product really worked for me.

Derek also sent along a copy of Diskeeper’s performance optimizer for virtual environments. I’ll report back once I give it a whirl.

BTW, I sure wish Microsoft would get on the ball and offer a workstation SKU of Windows Server 2008 R2 for developers. Right now, there are messy technical and licensing issues when you want to install consumer products on what is (technically) a server OS.  Selling a relabelled version of Windows Server 2008 R2 as “Windows 7 Hyper-V Developer Workstation Edition” would solve most of them.

Ken

It Works On My Virtual Machine - So Ship My VHD!

With advances in virtualization technology, it seems like the old quip, “It works on my machine - so let’s ship my machine!” is becoming reality.

In the old days, people would configure a physical box in their shop and send it out to the client or host to plug and play. With virtualization, you could configure a virtual machine – even a development machine – and upload the virtual hard drive to a data center.

Taking it further, the folks running Azure could run multiple copies of the identical VHD when it's time to scale out. Maybe this is something they’ll announce at PDC 2009?

Our Windows 7 Launch Party’s Over

The Windows 7 launch celebration went well at our place. I installed the “Windows 7 Signature Edition” on an older (Win 95 era) Dell machine and discovered that the new OS ran quite well. Even more surprising, Dell’s audio and video drivers for Windows 2000 worked great.

Because I set English (Canada) as the system language, we got the Canada background themes. I used the HD TV as a monitor and had the beautiful backgrounds rotating throughout. Does anyone know how to find the location those pictures were taken? Some are in the Rockies, but from which pass?

A couple guests put together the Windows 7 Party Pack puzzle  - with able assistance from my great-nephew Noah, as shown in the following picture.

Noah completes the Windows 7 Party pack puzzle

Even the dogs (Goldie and Riley) had a good time at the party. Here’s my dog Goldie getting an ear scratch from our neighbour.

goldiescratched

My wife bought the balloons and wrote “Windows 7” on them – strangely, the Party Pack didn’t include balloons.

The guests left our afternoon tea party with Windows 7 bags. Brenda won the deck of playing cards.

All-in-all a successful launch party!

More Posts Next page »

Search

Go

This Blog

Web Links

Syndication