locked
DTO... pattern or antipattern? RRS feed

  • General discussion

  • I've been working with DTO design pattern for years... but some days ago I read somewhere it was an antipattern.

    I think of it as a pattern as it helps reducing remote calls in distributed systems, as well as code.

    What do you think about it?
    laloivol
    Friday, March 13, 2009 12:05 AM

All replies

  • I'm not sure how Data Transfer Object is an anti pattern.  What was the article arguing?

    It might be helpful to post a citation so we can read the argument in full.


    Pl mark as answer or helpful if you found this useful
    Friday, March 13, 2009 8:54 AM
  • Hi,

    After doing some googling, it seems it is antipattern only in case of EJB 3.0. DTO is implemented in EJB 3.0 also but in its light weight form. In previous versions of EJB, it was context based which is called as anti-pattern.


    Here is the link that where it has been discussed.

    http://www.jroller.com/raghukodali/entry/dto_an_antipattern_in_ejb

    http://cz.sun.com/techdays/prague/prezentace/Day2_Track2/peformance%20antipatterns.pdf


    Friday, March 13, 2009 2:10 PM
  • I found similiar posts about EJB but thought they were probably not related to laloivols article as he/she would probably have posted on a more relavant forum!

    However, I can't find anything else...laloival?
    Pl mark as answer or helpful if you found this useful
    Saturday, March 14, 2009 11:33 AM
  • I don't understand how DTO could be an anti pattern!  It is a way of taking something complex where you need simplicity and shrinking it down to a more workable form.  Call it DTO or otherwise but it is a very useful way to get a particular task done.  Nothing more or less.
    Friday, March 27, 2009 11:00 PM
  • I don't think that DTOs are a pattern or an anti-pattern as such, they are only a name given to an entity object that originates in the data layer.  That isn't really a pattern.

    However, I do think that you need to expand upon your question a little, to give us a bit of an idea where you got the idea from, or what your area of concern is?

    Thanks,

    Martin.
    MCSD, MCTS. Please mark my post as helpful if you find the information good!
    Sunday, April 5, 2009 10:57 AM