trust the NH defaults. learn to work with the framework rather than
against it. you can use nh in a CRUD like fashion, but it does allow
you to create a domain driven design, where the application is focused
more on the business process and less on how/when data is saved to a
database.

On Oct 14, 3:11 pm, Trygve Lorentzen <[email protected]>
wrote:
> Thanks a lot for the clarifying answer. I obviously did the right
> thing to begin with with a separate LINQ query for in-memory objects.
> The reason why I can't persist single objects at a time to be able to
> query them through nHibernate is that I want the whole object graph
> persisted as one transaction.
>
> Thanks for telling me about the non-lazy collections. It was done on
> purpose for testing. Since I know the object graph will never exceed
> 300 objects, to you think it will still be a huge performance issue?
> It will of course be better performance-wise with lazy collections,
> just want your opinion.
>
> On 14 Okt, 20:23, Jason Meckley <[email protected]> wrote:
>
> > session queries the database, the identity map (1st level cache) only
> > ensures a single instance of a object is referenced through the scope
> > of the session. for this type of query you will need to persist the
> > data, then query for it.
>
> > if you want to query transient objects then you need to use in memory
> > filters (linq).
>
> > BTW: you have a problem with your mappings. all your collections are
> > not lazy. This will become a performance problem very quickly.

-- 
You received this message because you are subscribed to the Google Groups 
"nhusers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/nhusers?hl=en.

Reply via email to