The Bulimic Domain Model

For a number of years there’s been discussions about patterns and anti-patterns in the domain model space. From people like Martin Fowler we have Anaemic Domain Model, a Rich Domain Model, Layered Architectures, Service Layers .
I’d like to add a new pattern which I’d like to call the Bulimic Domain Model. The single defining characteristic of this is when you’ve finished working with it, you need to go and throw up.
The Bulimic Domain Model is so anaemic that rather than having convenience methods, it has inconvenience methods. Rather than the principle of “once-and-only-once”, we have the Casablanca principle “write it again, Sam”. Combining this with Transaction Scripts that have grown to the size of a Novel providing no possible opportunity of reuse with considerable refactoring.
Finally, the much vaunted Tell, don’t Ask is replaced with the Mother-in-law principle “Ask, and ask, and ask again”.
My advice when you come across one of these is to run, not walk to the nearest exit. Oh, and don’t eat too much for lunch.

Advertisements

Complexity derives from “infrastructure-oriented architecture”

From the “I don’t have much new to say, but I found this neat article” dept:
JD Tangney on Complexity
I particularly liked the quote : “It’s what you get when you give people the job title Architect”
Ignoring the XP-oriented slant, it’s damn good advice. Eric Evans in Domain Driven Design talks about how you can tell if you understand the domain, because your design will be simple. There’s a big lesson in that for everybody. If the code or design is hard, complicated and just down-right messy, then you probably don’t understand what you’re doing.
Oh, and for the record, “Streamlined Object Modelling” was not a book that I liked. If you like being told exactly what to do, and given a recipe for doing your job rather than thinking, then I suppose it’s a great book, but I really disliked it. Comparing it to Domain Driven Design does a major disservice to Eric.

MT-Blacklist is dead, long live SCode

The blog spammers have finally got too much. And with MT-Blacklist 2.0 falling into disrepair and no longer updating the blacklist (which kinda defeats the purpose), after Simon enthused about SCode, I decided to install it.
Well, it was pretty easy to install, and after only 2 false starts (make sure the SCode temp directory ends with a trailing /, and make sure you update the correct part of MTBlpost.pm if you keep running MTBlacklist) it is working.
Now, all 3 blogs that I administer are well and truly spam protected as much as I can be. I was getting about 10-20 blog spams getting through the blacklist each day which required manual intervention. Now, hopefully that will fix things.
The downside is that you have to read an image and type in the number if you want to enter comments. This will adversely impact all the blind, low bandwidth and non graphical browser users who wish to comment on my site. If you are feeling disadvantaged, then send the comment to me, and I will personally post it under your name.
I’m keeping MT-Blacklist around just to see how it goes. I reckon two levels of anti-spamming can only help.

Richie 0.3 now available – With User Defined word pronunciation

A whole bunch of new features with Richie 0.3. The most significant is the User Defined word pronunciation. Now any words can be substituted with a phonetic helper for FreeTTS. So, instead of Kumble being pronounced “koombel” with the addition of “Kumble=koomblay”, Anil can have his name sounding somewhat better.
Of course, that also allows the subsitution of “Gillespie with Dizzy” which makes for somewhat more entertaining listening and of course can be happily personalised to your hearts content.
With this version there are some slightly better regular expressions for working with the IRC commentary lines, but as always I will have missed a bunch of corner cases. If you find something that doesn’t work well for you, then send me the line that doesn’t get spoken correctly.
The source is quite a bit more ugly this time around, as I’ve tried to get this done quickly rather than well. As before, have a look and laugh.
Download richie-0.3.zip
Download richie-src-0.3.zip