Interesting hibernate behavior