Login Skip Navigation LinksWilsonORMapper > Forums Search
Demo Version Demo Version
Download and try for yourself a fully working demo version, including sample apps and documentation.  The only limitation is that the demo version only works inside the debugger.

PayPal Subscribe
Get It All for $50 USD:
WebPortal, ORMapper,
Source Code, All Updates
PayPal

User Login User Login
Log In
 
 
Reset Password

Wilson ORMapper Forums Wilson ORMapper Forums : Advanced Topics : Use actual domain objects or DTOs in remoting

Date Post
9/18/2006 2:46:21 PM

Hi,

I am just wondering how other people's experience has been in using remoting with the o/r mapper.  The main issue I am wondering about is whether to use serializard instances of my domain objects (those that are managed by the o/r mapper) on both the client and server, or if the domain objects should strictly stay on the server and only send DTOs back and forth over the wire.  It seems like using the domain objects is feasible as long as the relationships and aggregations are kept to a bare minimum, the objects are serializable, and they are not auto-tracked (use StartTracking only when saving).  But of course, you lose the conveneince of having an elaborate graph and the ability to get to a parent's parent's parent just through dot-notation and instead have to make a lot of queries to repositories.  That seems like it would adversly affect the readability of some complex business logic.  But then again, weigh that against the cost of having to translate your domain objects into and out of DTOs in every call... 

Any comments?

Thanks,

David Martines