Load vs Get in Nhibernate

Posted by Quintin Par on Stack Overflow See other posts from Stack Overflow or by Quintin Par
Published on 2010-04-04T17:33:33Z Indexed on 2010/04/04 17:53 UTC
Read the original article Hit count: 319

The master page in my web application does authentication and loads up the user entity using a Get.

After this whenever the user object is needed by the usercontrols or any other class I do a Load.

Normally nhibernate is supposed to load the object from cache or return the persistent loaded object whenever Load of called. But this is not the behavior shown by my web application. NHprof always shows the sql whenever Load is called. How do I verify the correct behavior of Load?

I use the S#arp architecture framework.

© Stack Overflow or respective owner

Related posts about nhibernate

Related posts about s#arp-architecture