Add Hibernate logic.