On fre, 2002-04-19 at 14:28, Ara Abrahamian wrote:
> > "What I am trying to do is allow lazy-loading of related objects from
> data
> > object. So it contains some finder-related methods, which go and fetch
> the
> > data."
> > 
> > I like this idea: lazy loading Aggregated/Composed ValueObjects from
> > ValueObject.  Maybe have the ValueObject use the aggregated/composed
> beans
> > util object to do a lookup and retrieve the value object?  Could solve
> the
> > problem of large data graphs, but at the cost of multiple network
> trips.
> 
> I don't like this idea! You're ending up writing two set of more or less
> similar code, one in value object and another in your ejbs. Honestly I'm
> starting to hate this valueobject pattern! In my application I ended up
> modeling everything (the graph I mean) as serializable dependent objects
> and simply pass them around. All ejb container dependent code is out of
> those dependent objects, inside a session fa�ade. And btw if web and ejb
> tiers on in the same jvm you don't really need value object, just wrap
> the access in a transaction.
> 
> Imho it really is a design discussion, and by the above design I don't
> have to deal with value objects any more, I only use a finer grained one
> for listing.
> 
> I'll be glad to hear what ejb gurus think. Comments?
I don't think there are any advantage of creating large graphs if the
client is a web-server, espsecially not if in the same VM. Single DTO or
simple ones are enough.

I like this proposal for distance clients like a java swing gui on the
users PC. Some parts (some parts of the graph) could be lazy loaded
first when you know what the user want to see. It could also be done
using separate Session bean methods.

But I think implementing something like this could be hard. Often not
all is to be lazy loaded, just some parts. Although it can be a lot
easier that implementing it for every DTO (Data Transfer Object) in your
application.

Marius K
Boostcom.no

> 
> Ara.
> 
> 
> _________________________________________________________
> Do You Yahoo!?
> Get your free @yahoo.com address at http://mail.yahoo.com
> 
> 
> _______________________________________________
> Xdoclet-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/xdoclet-user



_______________________________________________
Xdoclet-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-user

Reply via email to