2009/3/2 Graham Bunce <[email protected]> > > As I was writing that, I suspected it needed to know the key which, of > course, it doesn't - so just to clarify, if I did a Load by key, the > 1st level cache will be checked, otherwise it won't?
That was only the quick answer, as you can imagine a real answer would require a book. Something quick... You have 30 entities loaded in the session-cache (the UnitOfWork). Now you run a query that hit 100 records representing the top of the iceberg of 100 object graph. Instead analyze your query, execute it in the session-cache, change your query to exclude what is actually in RAM, execute your query hitting DB, add what is actually in ram to the result of the query... NH are doing what has better performance. > 2nd level cache eh? Looks like I'm going to be learning how to use > yet another feature of NHibernate :) Yes you should. The reference is a good place where start. http://nhforge.org/doc/nh/en/index.html#performance-cache -- Fabio Maulo --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
