in

Ative at Work

Agile software development

Ative at Work

Don't Propagate a Bad Decision

If you get data in a weird format, don't let that mistake propagate into your app. 

For example, I once worked on a legacy system that received data from an external source in a CSV file. Dates in this file were, split into three columns: day, month and year.

Surprisingly this had led the system's designer to store dates in the database not as date values, but as three columns: day, month and year. The result of course propagated to the whole system so that every place dates were used they were three separate values instead of a semantically meaningful atomic DateTime class.

Needless to say this caused all kinds of problems around the system.

The lesson is very clear - and particularly something you need to observe at interfaces and system boundaries:

Don't propagate a bad decision.

Create a model that is semantically correct according to the business domain and implement a mapping at the interface points.

Comments

 

Søren Lindstrøm said:

This is especially true, when building domain models on top of mainframe systems (i.e. with a PL1 mapping layer). Don't be tempted to let the data-centric types of this ancient language propagate into your domain model! It is the first indication that you are in fact synthesizing the data model and not the business domain.  

oktober 3, 2006 9:06

Leave a Comment

(required)  
(optional)
(required)  
Add
© Ative Consulting ApS