Hello, In a project I'm working on, to populate the asp.net mvc views, we are loading NHibernate entities (through a repository interface) and then using Automapper to map to a viewmodel. So far, we have not implemented the 2nd level cache yet. I was wondering if I would see improved performance by using ICriteria and projections to create a sql query to directly populate the view model instead of going to the trouble of loading the entities. At first glance, this would definitely help performance because I would be only getting the exact data I need with a very specific query. However, the 2nd level cache has me wondering if implementing that would be a better way to go about things. I would imagine directly loading the view model wouldn't use the 2nd level cache because we aren't really loading the entities but this would mean going back to the database every time unless we implemented some sort of view model cache. Can anyone give me any insight?
Mark -- 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.
