Neutral Format as a Coupling reduction idea that doesn't work.
- From: John Carter <john.carter@xxxxxxxxxx>
- Date: Mon, 19 Feb 2007 11:14:53 +1300
Ever had a problem of two classes / frameworks/ packages / systems....
that have to be coupled in someway.
Info has to pass between the two.
So the obvious gets done and one side or the other gets to use a rich fat
object from the the other side. And WOW! Oh the PAIN! The two sides are
now deeply and horribly coupled by all the things that rich fat object
depends upon.
Often you can't even compile the ruddy thing!
At that point some bright soul steps forward and says, its the problem of
having the rich fat object. Reduce the information to a simple neutral
format like a number, string, a CSV file an XML file and we're done.
Grreat. Now we're making fast progress. We can unit test we can validate
the xml we can do Good Things. That worked, we decoupled the two systems.
Did we?
Then why during the maintenance phase do we have all kinds of issues
relating ...
* Semantics - (What exactly did that field mean again?)
* Currency - (You changed something? Why didn't you tell us?)
* Encapsulation - (You added something, I don't care why, it broke my
stuff. Pull it out!)
* Duplication - Why are we writing this data encoder / decoder stream
twice?
Oh dear. Maybe a neutral format wasn't so good after all.
Perhaps we needed a middle ground. A slim interface object that just
carried, owned and understood the data required. Maybe the Rich Smart
object should use/hold/reference one of these to it's version of the info.
We've lost something now. The pretty human readable text view. The ability
to time wise decouple things by having the XML on disk. No problem, let
the small slim interface object (de)?serialize itself using CSV/XML/....
ie. Neutral Interface Formats aren't Naked. They have Invariants, they
have life cycles, they ownership, upgrade and maintenance issues. They
should be small standalone, very few dependencies, very reusable
objects/components in their own right.
--
John Carter Phone : (64)(3) 358 6639
Tait Electronics Fax : (64)(3) 359 4632
PO Box 1645 Christchurch Email : john.carter@xxxxxxxxxx
New Zealand
.
- Follow-Ups:
- Re: Neutral Format as a Coupling reduction idea that doesn't work.
- From: AndyW
- Re: Neutral Format as a Coupling reduction idea that doesn't work.
- From: H. S. Lahman
- Re: Neutral Format as a Coupling reduction idea that doesn't work.
- From: Nick Malik [Microsoft]
- Re: Neutral Format as a Coupling reduction idea that doesn't work.
- Prev by Date: Re: Relational-to-OOP Tax
- Next by Date: Re: The reality of Topmind (Was: Topic-Organized Object-Oriented Programming)
- Previous by thread: Re: Booch's book feels too philosophical rather than practical?
- Next by thread: Re: Neutral Format as a Coupling reduction idea that doesn't work.
- Index(es):
Relevant Pages
|