Hi...
 
I patched my version of Hibernate with a feature that I think is useful, but before I committed it I wanted make sure everyone agrees with what I have done and if we should make this feature configurable, etc...
 
Normally if you open a session, load or find some object, then close the session you will be unable to access the objects with a many-to-one relation if it is setup to use lazy initialization.
 
I modified the LazyInitializer so that instead of throwing an exception because the session is closed, it will open a new connection and reconnect the session if the session, do the find, and the close the session again...  This way I only have to load the objects I really need at runtime, and I don't need to worry about managing the session.
 
If anyone has any comments on this kind of functionality, then I would definately like to hear them.
 
Thanks,
Jon...

Reply via email to