Category Archives: hibernate

Why and when to wrap external library classes

At some point, every developer starts using an external library. They then have to decide if that external library should be wrapped in their own custom interfaces and classes. If the external library would be pervasively imported in throughout the … Continue reading

Posted in code review, hibernate, technical | Leave a comment

hibernate and component querying

Well here is some interestingness with querying for components using the 3.2.0cr5 version of hibernate. (FYI using accessor methods is the way the code was actually written. Direct references to properties in this example used just for clarity.) Components in … Continue reading

Posted in hibernate | Leave a comment

Hibernate nastiness using the one-to-one mapping.

Hibernate nastiness filed as bug HHH-2128. When reading this please notice that this situation arose from the most minimal definition. Using the ‘defaults’ is what caused this issue! Steps: define two classes (Primary, Secondary) that have a one-to-one relationship. use … Continue reading

Posted in hibernate, technical | Leave a comment

Hibernate’s event system

So I just had an interesting realization, Hibernate uses various default listeners in it’s poorly documented event system to do all of its persistence work. For example, saving an object through a Hibernate Session object quickly goes to the Session.fireSaveOrUpdate, … Continue reading

Posted in amplafi, help notes, hibernate | 6 Comments

hibernate messages … nice and unhelpful

One of the reasons why I recommend Tapestry as a web framework is the helpfulness of its error messages. Hibernate is just the opposite. Current annoying hibernate error message :”Null index column for collection” when trying to examine a previously … Continue reading

Posted in amplafi, hibernate, technical | Leave a comment