Author: Liviu Nastasa

Passionate about software development, sociology, running...definitely a geek.

One thought

  1. I had the same problem. Hibernate documentation gives us a description of the two approaches. I chose the clean 2 tier/closed session approach, implemented mainly with Criteria not with Query, because you can state clearly the FetchMode you want for your members/properties. It certainly has some disadvantages like:
    – eliminates the caching 😦 – a big performance hit here
    – forces you to fetch data even if you don’t need it OR complicates your data logic function (“To Fetch ..Or Not To Fetch? … That Is The Question” – HiberHamlet by HiberTitan + a guy named Shakespeare)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s