Tuesday, May 01, 2007

What is a software architecture?

Short version:

Make a complex problem abstract !!!

(if it gets too confusing to understand, refactor it)

'nuff said

Longer version:

Problem: please write a financial application (read: so that my lazy boss can understand how much money he has)

Solution:

1/ Beginner coder:
    Let's start with Access, create 10 tables, throw in 5 forms in VB and we're done.

2/ Intermediate coder:
   Definitely SQL stored procs. Make 20 of 'em, throw in 20 forms, including security login/out (so that no one except me, the master developer can steal money).

  Wait, what do you mean there are bugs? Bugs? Sigh, I'll spend this week sleepless fixing it for you, boss.

3/ Code guru:
  Let's use this spanking new Uber Framework version 9.6 beta 2. I'll spend the next week to read about it and you will have your application 1 hour later.

  Bugs? You humiliate me, sir! There's absolutely no bugs. All those cumbersome features are the framework's fault. You should upgrade to beta 3.

4/ Junior architect:
  Any application starts with 3 layers, see? You need to buy data layer from Microsoft, stick to their recommended best practices & design patterns. For business layer, let's do it from scratch. For presentation layer, let's buy the coolest control suites available.

  No bugs envisioned. My design is perfect. The bugs introduced are developers' faults.

5/ Senior architect:
  All applications need AT LEAST the following:
  - fast, multi-destination logging & instrumentation (log file is not enough)
  - exception publishing (throw new Exception("blah blah") is unacceptable )
  - data abstraction layer (sorry, no SQL, noobs)
  - data binding layer (hands-free, code-free automatic data binding)
  - platform independent, threadsafe, lightweight UI controls (winform, webform are the same, right? )
  - flexible, performant, fault-tolerant, management-free security system
  - workflow engine
  - process engine
  - rule engine
  - query engine
  - report engine (forget those pathetic, pre-built SQL report tools, we're talking about business object reporting tools with slice-n-dice data mining here)

For any of those little, cute items up there, make it:
 - extendable
 - re-usable
 - scalable

Basically, that means there is no design, no commercial product, nothing whatsoever sastisfies my requirements. Thus I have to build it from scratch (let the boss cries, he knows nothing. If he forces me to use a pre-made solution, I'll spend 9 months out of a 10 month project for my own researching, and I will make everything related to the project in the last month)

Bugs? What do you mean somecode somewhere in my some layer is broken? They must be pre-designed features that I forgot to write documents (if I ever do write one)

bienca101

No comments: