The Artima Developer Community
Sponsored Link

Articles Forum
The DCI Architecture: A New Vision of Object-Oriented Programming

119 replies on 120 pages. Most recent reply: Jan 7, 2012 3:19 AM by Thorin Potjes

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 119 replies on 120 pages [ « | 1 ... 27 28 29 30 31 32 33 34 35 ... 120  | » ]
John Zabroski

Posts: 272
Nickname: zbo
Registered: Jan, 2007

Re: The DCI Architecture: A New Vision of Object-Oriented Programming Posted: Mar 24, 2009 8:15 AM
Reply to this message Reply
Advertisement
@Another thing I found interesting was the suggestion that the domain objects be very simple ("dumb, dumb" as Jim put it). This seems to promote what Martin Fowler and Eric Evans called an "anemic" domain model [...] These guys complained that you should put more interesting behavior on those objects.

Well, that's easy to reconcile. Evans/Fowler vs. Coplien/Reenskaug is not a battle of diametrically opposed forces. Instead, they're both wrong.

The big idea behind dynamic, multi-object interaction is that it is composed at run-time. You will have code fragmentation in order to do this. As you pointed out, their solution just pushes the fragmentation around and into traits. They're moving mounds of dirt, not setting up foundations for an architecture.

Rich domain models are wrong because the assumption is placing logic in one place (a domain class) is a good idea. Maybe, but you lose a degree of freedom and are creating an unstoppable geometric progression. Then there are awkward "N-Body Problems" where objects need to coordinate and no one object is in charge.

Anemic domain models are wrong because they flatten an architecture into orthogonal layers, requiring developers to pass tramp parameters to pass an object across multiple layers. This is fundamentally not OO, it is a data-driven CRUD/USER pipeline. This is the kind of app Spring and Struts and much of ASP.NET encourage writing. The POJO Facade pattern is a great example, and the book "J2EE Design Patterns" is a great example of OO anti-pattern after OO anti-pattern: breathtaking, really! Until J2EE5 and EJB3, Java land has been very far from OO theory&practice.

A major culprit here is buzzwords. So you'll forgive me if I snort when I see sections of an article with the header: "in spite of capturing structure, OO fails to capture behavior". The whole point of the GoF design patterns was to explain how to do dynamic substitution of behavior.

A more even handed approach is what Microsoft is trying to evangelize w/ Acropolis, Prism, MEF and Oslo, but very few seem to be adopting due to its immaturity. Redhat's JBoss also deserves some credit. Are you familiar with Redhat's JBoss and Microsoft's upcoming products?

Flat View: This topic has 119 replies on 120 pages [ « | 27  28  29  30  31  32  33  34  35 | » ]
Topic: Effect Choreography in Flex 4 Previous Topic   Next Topic Topic: Cooperative Visitor: A Template Technique for Visitor Creation

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use