Tuesday, August 23, 2005

What every developer must know about multithreaded applications

As a developer with long-time C++ experience I always felt quite comfortable with multi-threaded development. However, very often I discover that this comfortness is not shared by all developers. I lost count on how often I had to investigate some strange deadlock or race condition.
Fortunately, Vance Morrison of the MSDN Magazine published an interesting article named "What every dev must know about multithreaded apps". It is rather lenghty, but gives a nice indepth look of the advantages and disadvantages of multithreading.

Friday, August 19, 2005

Collapse the Solution Explorer in Visual Studio

Get this nifty little macro to collapse the tree-view of Visual Studio's Solution Explorer. Why didn't Microsoft think of this in the first place?

Use WS-Security with .NET Remoting

A while ago, Microsoft published an interesting article that explains how to add WS-Security support to a .NET Remoting channel. It relies on custom Remoting sinks (both client and server) that use the out-of-the-box services provided by Web Service Enhancements 1.0. By injecting those sinks into the channel configuration of your Remoting infrastructure, they will wrap the Remoting messages into SOAP envelopes and vice versa. Quite a nice idea, I must say.

Wednesday, August 17, 2005

Free Visual Studio 2005 online training

Through Alex Thissen's site, I ran into the Visual Studio 2005 E-Learning section. Apparently, Microsoft is offering its interactive learning programs for free for the time being. I've run two of the sessions (Team System introduction and new VS features), and I must admit, they are quite informative. Try it....

Tuesday, August 16, 2005

Estimation based on Use Case Metrics

At my current project, we've started to initiate a workload estimation based on Use Case Metrics. Apparently several methods exists, but we chose the Gustav Karner methodology. I'm quite impressed with how environmental and technical risks are translated into a factor that can be applied on an initial manhour estimation. Shivprasad koirala wrote a great article that clearly explains the fundamentals of this technique, and Roy Clem provided a summary. As soon as we have real-life metrics I'll update this post. Notice that Sparx System's Enterprise Architect provides full support for Use Case Metrics (including the above mentioned factors).

Friday, August 12, 2005

Asynchronous callbacks for web applications.

One of the issues that web developers are often faced with these days is dynamic behaviour on web pages. Often, falling back on Javascript is the only viable option. However, this article explains how you can support asynchronous client script callbacks that execute code-behind code without the user noticing any activity. ASP.NET 2.0 seems to support this out-of-the box. Look at the Google beta site to get a demonstration (although I doubt it is created in ASP.NET).

Wednesday, August 10, 2005

Easy searching in the Microsoft newsgroups

I've been using this shortcut for googling in the Microsoft newsgroups for ages now.

Aborting a .NET Remoting call

Today I ran into quite a frustrating .NET Remoting shortcoming. It seems to be impossible to abort a long-running .NET Remoting call. I've checked on Google to see if anybody came up with a proper solution, and I have even tried to gain access to the TCP Sink that is being used, but all failed. Eventually I decided to use an asynchronous delegate to perform the call on the ThreadPool and abandon it when a certain timeout occures. Hopefully the threads are released in time, otherwise we may have a potential memory leak.

Unit testing in .NET

As a professional software developer, you may have heard of NUnit. Or even better, like me, you may have already used it in a couple of projects. One of the things NUnit is missing is a possibility to have more flexibility on the test environment or the conditions under which a test is running. The article Unit testing with .NET provides a comprehensive overview on NUnit, MBUnit, and Visual Studio's upcoming Team System. Apparently, MBUnit is a kind of NUnit on steroids which provides a lot of the things NUnit is missing. Beware though, I haven't tried it myself yet, but I'm sure gonna...
Some more examples at The Code Project.

Monday, August 08, 2005

Alex Thissen is alive

Four years ago I took a .NET training given bij Twice IT (http://www.twice.nl). Together with my best collegue Rinie Egas, we kept in contact. The last time we met him was at the Microsoft DevDays in The Hague. Since then I never heard anything anymore, until today. It seems he left Twice and is quite active in the .NET community. Make sure you checkout his weblog at http://www.alexthissen.nl.

Architecture training

Today I had a great training on application design patterns with a focus on .NET. Tomorrow, this training will have a follow up focussing on enterprise patterns (messaging, etc). The training is provided by http://www.cibit.nl and I was quite impressed by the knowledge the trainer has.
One of the interesting new things I learned was Domain Modelling. An important aspect compared to table-oriented designs is the separation between the persistance logic and the domain model. The latter only deals with trying to get the best representation of a domain in an OO view, while the former deals with how the model must be persisted, loaded, etc. A great article on this can be found on Paul Giellens weblog: http://weblogs.asp.net/pgielens/archive/2005/07/29/420995.aspx

Friday, August 05, 2005

Voila! Automatic XML comment generation

Did you ever get bored with those obvious XML comments? Did you ever omit a comment because you were too lazy? Well, here comes GhostDoc...
I've already used NDoc (http://ndoc.sourceforge.net) for a few years, so I'm always eager to fill in the comments properly. But it is quite annoying that I have to type the documentation of an override again and again. GhostDoc adds a context-sensitive menu entry and a shortcut-key, and uses a intelligent configurable rule dictionairy to generate the comments from the definition, base-class member, etc. It even copies the documentation from the MSDN.
Check it out at http://www.roland-weigelt.de/ghostdoc.