tags:

views:

165

answers:

2

I often see statements like "App x doesn't have a complicated enough domain to justify the overhead of a multi-tiered architecture. It is better suited to a forms over data approach." I'm wondering what the characteristics are of a domain which would compel one to go with a particular approach. That is, how can you tell when to do something simple like forms over data or when should you build in multiple tiers, a domain, DTO's, etc.

A: 

Both options seem to describe the more heavyweight mouse-driven frameworks where software helps write the software. (These are the usual suspects - frameworks you pay for directly or indirectly.)

I think it's possible to have patterns and practices that lie somewhere in the middle; where you write the software but most cases fit something your already comfortable with. (I think the key word is a strongly bonded relationship with "Patterns".)

A good specific example is the newly popular MVC conceptual framework (and its kindred). These can be treated pretty generically; and you may or may not choose to pay for the tools based on your platform, context and/or personal preferences. But I think there aren't many situations where MVC etc. would be underwhelmed or overwhelmed (but one of the two options proffered in the question would be a decisively better fit.)

At least I'd try real hard to find a middle path, if for no other reason that not doing so tends to lead to short-lifecycle patterns and tools, and scalability issues (which the question refers to directly.)

le dorfier
+2  A: 

This is by no means definitive, but I would say forms over data refers mostly to domains that are slim and light on business rules. That is, if you are just inputting data from a screen into a flat data structure that is more or less going straight to persistence, I would think a DDD architecture isn't quite as critical. But if your domain consists of multiple aggregates, and/or is very business rule heavy, then you should probably think about DDD.

Of course, as with all things in our world, there is a lot of grey area in the middle and your best judgment is all you have to make the decision.

You might try asking this question on the DDD message board

jlembke