Archive for the 'dotnet' Category

Guidance Automation going Gold

Sunday, February 17th, 2008

The Guidance Automation Extensions (GAX) and Guidance Automation Toolkit (GAT) are both going Gold. These packages are critical in creating software factories. These tools provide the base for tools like the Web Service Software Factory: Modeling Edition. I read the news from Tom Hollander. If you are not familiar with GAX/GAT think of these tools as Intellisense at the project level instead of the individual lines of code like normal Intellisense.

I have been experimenting with the software factories over the last year and have been anxious for the Gold release. As Visual Studio 2008 was released a stable version of WCSF for Visual Studio 2005 was released, but it was still built on a CTP release of GAX/GAT. A few weeks later a CTP of WCSF for Visual Studio 2008 was released. Now with a solid base I expect work on the software facotries to accelerate.

There has clearly been a lot of work put into getting these tools ready before the Microsoft launch events for .NET 3.5, Visual Studio 2008 and Windows Server 2008 that are starting at the end of this month. (see Heroes Happen Here for details on launch events) There are many projects on CodePlex for software factories and with a Gold release for GAX/GAT the projects should get a burst of activity.

I still think the UI for these tools need more work and there need to be many more training videos produced to improve adoption of these powerful tools, but the Gold release is the first step toward creating software in a new way.

You can read more details from Grigori Melnik, David Hayden and Jose Escrich. If you are interested in what happens next I suggest you subscribe to their blogs.

Code Generation, Software Factories and Visual Studio Extensibility - Madison

Monday, February 4th, 2008

[ Update: Due to the snow cancellations this presentation has been rescheduled for March 5th. ]

On Wednesday I will be presenting Code Generation, Software Factories and Visual Studio Extensibility in Madison. Back in October I gave this presentation to the .NET User Group in Milwaukee with a strong attendance. I really enjoy this topic because gaining an understanding of what sort of automation that you can do to not only reduce your manual workload but to also implement more features with higher quality on a regular basis is a killer combination. I am a big fan of using MSBuild to automate routine tasks but code generation and software factories go several steps past just saving time and effort.

The tools that are available to generate code are making dramatic improvements over the last couple of years. The Web Service Software Factory: Modeling Edition was released in November, just a month after my last presentation so I will now be able to cover what was not fully ready then. I expect this demonstration to be a lot more engaging than my last presentation on this topic. You will not want to miss this presentation.

Reviewing Software Design for Growing Applications

Sunday, January 20th, 2008

Applications that live for a long time tend to grow to the point that they become unmanageable. It is a common problem. Large projects grow by adding new features continually. And when critical bugs are discovered they are fixed as quickly as possible without fully considering the impact on the overall system. It is too bad because even the most basic check on the design is a process that can be as simple as a 10 minute review.

Reviewing the application can be as simple as drawing up a diagram to represent all of the parts of the application with lines drawn between the dependent pieces. This diagram does not have to be a detailed UML diagram but can instead be simple circles and lines. The diagram will quickly reveal some obvious problems. Once you have the diagram you can ask yourself a couple of questions:

  1. Are the dependencies always moving down, or are there circular dependencies?
  2. Are the components too big or too small?

(more...)

Restart a Bloated Application from Scatch?

Sunday, January 20th, 2008

In the work I do I have often have to work on large applications that have grown for a few years without effective controls in place to ensure the application remains manageable. Sometimes you just have to start from scratch, perhaps cannibalizing the old application wherever possible, and carefully assemble everything piece by piece while following a disciplined plan to make sure it all meets your current requirements.

As I have watched Microsoft for the past 10 years I have seen the progression from DOS to Windows 3.1 to WinXP and now to Vista. Along the way the OS pulled along a great deal of backward compatibility at the expense of agility. Back in 2001 Apple released MacOS X which was a completely different OS from MacOS 9. Apple bet the house on a fresh start after the popularity of the Internet forced the personal computer to account for new requirements that did not exist before. Meanwhile Microsoft chose to gradually upgrade their flagship product, Windows. Watching the consequences of these two choices unfold has been a good lesson in enterprise software design.

(more...)

Lotsa Blogs

Friday, January 4th, 2008

Kevin over and ScribeSonic is cleaning up the vast collection of feeds taking up space in his blog reader. You might say he has a plethora of feeds.

:)

He is using Google Reader, which I also use. An easy way to subscribe to a new feed is to use the little bookmarklet/favlet that you can find on the Settings tab. It is buried towards the bottom. As you come across a good blog entry via services like DotNetKicks.com or DZone you can click this link in your toolbar to send the feed to Google Reader to subscribe to it immediately. This link is copied below.

[ Subscribe... ]

Also keep in mind that RSS content can be more than just comments from some blithering blogger. One useful kind of feed is the latest activity on your source control system, such a project hosted in Subversion. I created a little RSS generator that uses the log and list commands from the Subversion command-line tool to generate an RSS feed for any URL you throw at it. There are a few query string parameters that you can use to customize the behavior. Just look at the sample links to see how they can be used. They are pretty self-explanatory. (url, title, username, password)

[ SvnTracker ]

It is a very tiny web application and the source for it is available via the link at the bottom of the page. It is a bit sluggish, but when it placed being an aggregator like Google Reader you should never notice the delay. If you want to use it, please host it on your own server as this is just a temporary location.

A Touching Christmas Story

Friday, December 21st, 2007

Back in the Christmas of 2005 I read a story by Sean McCormack about something that happened that is worth reading again.

Right before Christmas I was rushing around trying to get some last minute
shopping done. I was stressed out and not thinking very fondly of the
Christmas season right then. It was dark, cold, and wet in the parking lot
as I was loading my car up with gifts that I felt obligated to buy.

I noticed that I was missing a receipt that I might need later. So mumbling
under my breath, I retraced my steps to the mall entrance. As I was
searching the wet pavement for the lost receipt, I heard a quiet sobbing.

The crying was coming from a poorly dressed boy of about 12 years old. He
was short and thin. He had no coat. He was just wearing a ragged flannel
shirt to protect him from the cold night's chill.

Oddly enough, he was holding a hundred dollar bill in his hand. Thinking
that he had gotten lost from his parents, I asked him what was wrong. He
told me his sad story. He said that he came from a large family. He had
three brothers and four sisters. His father had died when he was nine years
old. His mother was poorly educated and worked two full time jobs. She made
very little to support her large family. Nevertheless, she had managed to
skimp and save two hundred dollars to buy her children Christmas presents.

His Mother, on the way to her second job, had dropped off the boy. He was to
use the money to buy presents for all his siblings and save just enough to
take the bus home. He had not even entered the mall, when an older boy
grabbed one of the hundred dollar bills and disappeared into the night.

"Why didn't you scream for help?" I asked.

The boy said, "I did."

"And nobody came to help you?" I queried.

The boy stared at the sidewalk and sadly shook his head.

"How loud did you scream?" I inquired.

The soft-spoken boy looked up and meekly whispered, "Help me!"

I realized that absolutely no one could have heard that poor boy cry for
help.

So I grabbed his other hundred and ran to my car.

Holiday Installfest Recap

Friday, December 21st, 2007

On Tuesday we had our local installfest holiday part of the new release of Visual Studio 2008 and .NET 3.5. This was a big one. I feel like I have been hearing about multi-targeting and LINQ for years now. A few weeks back I wrote a summary of my favorite new features. In that post I forgot to mention the new code metrics, so I followed up with a summary of that great set of features.

Since I had a copy of Visual Studio 2008 prior to the installfest I was able to dig in and build a little application that I showed during my mini demo. I call it Kvetch Reborn because it is a recreation of the original Kvetch.com which is no more. I made use of LINQ to get it up and running faster than writing the stored procedures I have typically used with .NET 2.0.

I also made use of the ASP.NET AJAX features to convert a web service into a JavaScript proxy so the methods provided by the service could be used directly from the client-side. The service callbacks are extremely lightweight. Most communications are measured in bytes while your average ViewState is multiple kilobytes. I have been leveraging this functionality for several months now since it was released with ASP.NET AJAX release last year. But now it is a bit easier with intellisense support for JavaScript. You can try it and download all of the source with the following links. In later blog entries I will detail exactly how it was all built. Check back for those details.

It was a great event. We nearly filled the seats with an expected attendance around 200 people. There were lots of prizes thanks sponsors like KForce, Fullhouse Interactive and Apress. All of the tasty food was sponsored by Centare. And Microsoft also threw in some big prizes like the Xbox Elite, Zunes and lots of other great prizes.

I especially want to thank Matt and Kerrie at Direct Supply and Patrick at Northwood Software for helping out the .NET User Group this past year by hosting events at their facilities. I look forward to more meetings with them.

Lastly I want to thank our organizers and hosts: Scott Isaacs, Gerry Heidenreich, Larry Clarkin and Dave Bost. Without them these events would not happen. Thanks guys!

Web Deployment Projects in Visual Studio 2008

Friday, November 30th, 2007

The new release for Visual Studio has been out for MSDN subscribers for a couple of weeks now and if you have tried it out you may have discovered that the Web Deployment Projects are only registered to work with Visual Studio 2005 despite interest in having this capability added directly to the IDE. Instead the add-in will be updated and released for Visual Studio 2008. Today as I upgraded a set or projects from .NET 2.0 to .NET 3.5 I found that the Web Deployment project that I have set up for the website was not loaded, however, I am still able to make use of the project even if Visual Studio does not know what to do with it.

I am a big fan of automation and what MSBuild can do for you. There are bits and pieces of MSBuild sprinkled all over .NET projects. Most project files are actually MSBuild scripts that you can use like any other MSBuild script. What I like to do is place an MSBuild script called build.proj in the root folder of a Solution that I use to carry out common tasks such as building and packaging the Solution. One of these tasks has been to run the Build target in the Web Deployment project for a website and then package the contents of the output folder in a zip file. I prefer doing deployments this way instead of using the publishing feature in Visual Studio which seems to take longer most of the time. Using the MSBuild script also allows me to run the build without using Visual Studio, such as when the code is on a server and not on a development machine. Once the zip file is created I can simply upload it to the server, unzip it and place the files in the directory where IIS is configured to serve up the website. For important websites I make sure to keep an older zip file around in case I need to roll back the changes.

(more...)

Additional Preparations to Install Visual Studio 2008

Wednesday, November 28th, 2007

There are many events coming up where you can get a free Visual Studio 2008 installation. These events have filled up quickly, as Dave Bost explains. You can get a 90 day trial for Visual Studio 2008 from MSDN right now but when you get the fully licensed version you will need to uninstall the trial. The special installations for these events, however, do not require the uninstall which is a good reason to get into one of these events. But before you attend one of these "installfest" events you will want to prepare your computer with the following tips.

(more...)

Another Reason to Upgrade to Visual Studio 2008

Wednesday, November 21st, 2007

I cannot believe I neglected to mention the new code metrics features in Visual Studio 2008 along with previous list of worthwhile features. Code metrics will scan your project and show you a Maintainability Index at the class and method level based on Cyclomatic Complexity, Depth of Inheritance, Lines of Code and other values. Knowing how your code looks from this perspective should help you in refactoring it into a more simple form that should save you many headaches in the future. The details are presented to you with an easy to read grid that is ideal for quick code reviews.

You can read more at the Visual Studio Code Analysis Blog.

(more...)