Transactions are still needed. If you do not use them, you will turn off the cache as soon as you start updating some cached objects. ( Look here why , I recently bit the latest version of NH. Why did I forget the transaction? No excuses ... Also, read committed snapshot
included in SQL Server, which removes deadlocks related to read-only read requests.)
Collection caching works, but must be configured in collection mapping. Add the <cache usage="..." />
node to your collections and other collections that need to be cached. Their contained objects must be cacheable in order to be truly useful. (Collection caching only caches the associated primary keys of related objects.)
In your query engine, only identifiers from the database are loaded, if the request is cached, I have never witnessed this, although I am a long-time user of NHibernate. (I have been using it since version 0.9, it was already very mature and rich.) To my knowledge, there were no major changes in the second level cache with NH 4. You can check their problems and changes> .
source share