My Life As A Blog

Archive for December 2007

The Concierge Antipattern

with one comment

A concierge can be invaluable in a hotel. Here’s an extract from the Wikipedia definition of concierge:

“In hotels, a concierge assists guests with various tasks like making restaurant reservations, arranging for spa services, procurement of tickets to special events and assisting with various travel arrangements and tours of interesting places to visit. In upscale establishments, a concierge is often expected to ‘achieve the impossible,’ dealing with any request a guest may have, no matter how apocryphal or strange, relying on an extensive list of personal contacts with various local merchants and service providers.”

What does this have to do with software design? Well, I’ve seen a similar solution applied in software design -and I thought I’d note my thoughts on what I’ve seen.

The Concierge Framework

The Concierge Framework will simplify your application development by providing you with all the services you need. Which sounds great. But there are some drawbacks. Firstly, remember how the hotel concierge relies on “an extensive list of personal contacts”? The Concierge Framework does, too. In the case of a framework, this usually means a load of dependencies. So, when you decide to use a newer version of your favourite logging framework, you can expect the Concierge Framework to get upset. Secondly, the Concierge will often have a particular way of accomplishing tasks – which will constrain what you can do. So, if you want to do things differently you’ll need to write it yourself or hack the framework.

How do you know you’re using a Concierge Framework? Often you’ll find that all the layers of your application need to be dependent on the Framework (and on all of its dependencies.) You’ll also find that some simple tasks become absurdly difficult. An occasional side effect of using a Concierge Framework is an obscene amount of configuration. Put simply, if you feel that the framework in question is being too helpful, it’s probably an instance of a Concierge Framework.

The Concierge Framework may be a misunderstanding of the Façade pattern. It goes beyond the scope of the Façade pattern by trying to provide a simplified interface to too much – and that’s clearly an (unstable) abstraction too far.

Does this antipattern resonate with your experience?

Written by remark

December 23, 2007 at 2:16 pm

ActiveMQ version 5 is released

leave a comment »

I’ve written a few articles about ActiveMQ over the last few months.  Version 5 has just been released.  There’s more info on James Strachan’s blog here.

Written by remark

December 17, 2007 at 11:11 pm

Posted in Development, Java, Open Source, Software, Tools

Tagged with

Reference Architecture

leave a comment »

A Reference Architecture can be a useful tool in communicating how a given business problem is solved.  This communication in turn helps to guard against wheel reinvention.  This article is a good overview of what constitutes a reference architecture.  The challenge once a reference architecture has been created is applying appropriate governance such that the reference architecture can evolve over time and does not stifle innovation whilst ensuring that the reference architecture is adopted in order to promote consistency, quality and rapid delivery (no cycles wasted solving a problem to which the solution is already known.)

Written by remark

December 16, 2007 at 8:20 pm

The next step for SOA?

leave a comment »

Here‘s an interesting post from Service Oriented Enterprise about what may be to come for Service Oriented Architecture.  Here’s how the nub of the problem is described:

"The real issue is designing a portfolio of services without creating redundancies or conflicts in the message model."

For SOA in the enterprise, this description is spot on.  The next logical step to gain expertise in modelling information and services across the enterprise.  Think of it as Domain Driven Design writ large – where the domain in question is the entire enterprise.

Written by remark

December 12, 2007 at 10:42 pm


leave a comment »

Last week, Microsoft Live Labs released a CTP of Volta.  Volta is:

“a developer toolset that allows you to build multi-tier web applications by applying familiar techniques and patterns.”

Here’s how it works.  You write your code in C# – let’s say for a web page.  Volta recompiles the MSIL as Javascript – so your page is fully functional even though you wrote in C#.  Then, if you decide that some of the code should run server-side, you can “tier-split” (via an automated refactoring that adds attributes to your classes) and bingo.  Job done.I downloaded the CTP and went through the Quickstart and a couple of the samples that come with it and it does what it says on the virtual tin.  Of course, when splitting, you’ll want to remember the Fallacies of Distributed Computing (especially “Latency is Zero”.)  And to help you, Volta comes with some profiling tooling.This is a technology that’s worth keeping an eye on.  Right now, it seems a little raw – performance will no doubt improve over future releases – but there’s no doubting the power that comes with the simple model it offers.

Written by remark

December 11, 2007 at 11:20 pm

Posted in .NET, Development, Software

Analyze That

leave a comment »

While tinkering in Visual Studio 2008 today, I saw a context menu item on a project I’d not seen before: Calculate Code Metrics.  And there’s another called Run Code Analysis just above it.  Pleasingly, if unsurprisingly, you get some metrics about your code.  That’s right – feedback on your code from within the IDE.  Ok, so it’s got a little way to go before it can compete with the code metrics tools you’re probably using now,  but this is a very encouraging start.  Somehow, this feature escaped my attention until now.  There’s more info in this post from Somasegar and this post from the Code Analysis Team.  One more reason to use Visual Studio 2008.

Written by remark

December 7, 2007 at 6:23 pm

Posted in .NET, c#, Development, Tools