(Opens New Window)
Mark as an Answer
Portlet Classloading Problem
November 28, 2012 2:45 PM
Rank: New Member
Join Date: December 18, 2007
This is a problem I've been having in a few forms now. I am upgrading a custom portlet from 5.2.3 CE to 6.1.2 EE. The portlet uses spring MVC and hibernate, though not the Liferay ServiceBuilder (for now).
Ever since attempting to deploy, I've been getting a classloading problem. The relevant part of the one that's got me stuck is here:
Caused by: java.lang.IllegalStateException: Cannot convert value of type [org.hibernate.impl.SessionFactoryImpl] to required type [org.hibernate.SessionFactory] for property 'sessionFactory': no matching editors or conversion strategy found
... 44 more
I have a single copy of the hibernate3.jar file in my portlet lib, and a single copy in my portal lib, and moving that to the tomcat/lib directory doesn't do anything. I don't deploy my Liferay as the ROOT tomcat app because my server people don't allow for it. I build my portlet with the SDK and load jar files with the liferay-plugin-package.properties file, so it's not like there's a versioning issue between the portlet and Liferay.
After reading this article: http://www.liferay.com/home/-/blogs/10770905/maximized I separated my spring contexts into two files, one loaded by service.properties and the other in the web.xml, which didn't work. I've also re-ordered the listeners in my web.xml file after Liferay has deployed the portlet, after seeing this article: http://issues.liferay.com/browse/LPS-29103
I'm stumped. Any ideas?
Sign in to vote.
Please sign in to flag this as inappropriate.