Saturday, January 17, 2009

What makes a good software architecture?

I remember reading dozens of 'must have' attributes for a good software architecture in several design books. Sometime back I even made a blog post with a list of such attributes. Last Friday I got to rethink when I was in a argument with two of my friendly techies Sanjaya and Samudra. When asked what makes a good architecture, I stated that an architecture is good if it has two simple qualities:
You shouldn't need an architect to understand it: Just because you are an architect, you don't need to use all complex design patterns in the books. Developing a simple workable architecture is always harder than building a complex one. When a developer reads your specification, if he asks "why the hell we needed an architect to design this?", the mission accoumplished! I love these two quotes taken from Kala's blog!
- Simplicity before generality, use before reuse
- If you design it, you should be able to code it

It solves the problem in hand but nothing more: As an architect what is expected from you is to solve the problem in hand but not to build a crystal ball that solves any other problem in the world. For example, if you are asked to build a custom LOB application, you are not expected to build a 'highly extensible framework for LOB products' from you. When expected if the former and you try to build the later, often the result is a system that is too complex. Design only for what is required; if scalability beyond 100k nodes isn't a requirement, don't design for it, unlimited scalability has unlimited cost! (Dont take me wrong, if requirement is for 100k nodes, rollup your sleeves and do it!)

Solving real world problem with software is naturally a complex task; don't make things unnecessarily complex with your architecture!

[tag: 99xt ]

8 comments:

creed said...

And how many years in Software industry and how many complex architectures did we required to understand that :) ? Time to action what we think we understood!

Hasith Yaggahavita said...

This is nothing new. Everybody know but in fails to practice these principles in their architectures.

Being hardcore techies our heads are exploded with new catchy tech concepts that are mostly marketing material for companies publishing articles on their products :).

It has been always a struggle to implement "what is actually required" over "what is really cool to code".

Kalhara said...

You are on the dot Hasith, that's why the no 18 from my list Simplicity before generality, use before reuse is perfectly matching to your post. And I also I like the 63rd point If you design it, you should be able to code it. I think you always proves this point :)

Cheers

Hasith Yaggahavita said...

Thanks Kala, I have updated the post with links to your post.

Anonymous said...

Nice post hasith, and a real true one. We as software engineers face lots of problems because archtects focus on the complexity more than than the requirements.

Thanks

Rohan Fernando

Anonymous said...

Nice post hasith, and a real true one. We as software engineers face lots of problems because archtects focus on the complexity more than than the requirements.

Thanks

Rohan Fernando

Mark said...

Wise words :) This blog reminded me of how Occams razor can be applied to software architecture...

Joshua Smith said...
This comment has been removed by a blog administrator.