Got rid of deprecated method in HibernateUtil