Win a copy of Java Mock Exams (software) this week in the Programmer Certification (OCPJP) forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Liferay 6.0 SP1 Spring Portlet FilterClassLoader unable to find a resource available on classpath

Jignesh Gohel
Ranch Hand
Posts: 276
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have com.springsource.javax.validation-1.0.0.GA.jar (JSR 303 framework) and hibernate-validator-4.2.0.Final.jar (Reference Implementation for JSR 303 framework)
available at <LIFERAY_PORTAL_ROOT>/tomcat-6.0.29/webapps/ROOT/WEB-INF/lib.

All the portlet plugins are able to find the implementation class org.hibernate.validator.HibernateValidator
[META-INF/services/javax.validation.spi.ValidationProvider implementation in hibernate-validator-4.2.0.Final.jar]
and the classloader in context is found to be following by JSR 303 validation framework:

delegate: false
----------> Parent Classloader:

But when kaleo-web plugin deployment is started the classloader changes to com.liferay.portal.spring.util.FilterClassLoader due to
a org.springframework.beans.factory.config.BeanFactoryPostProcessor registered in the spring's application context for kaleo

The Liferay's implementation of org.springframework.beans.factory.config.BeanFactoryPostProcessor is as below:

And the com.liferay.portal.spring.util.FilterClassLoader is unable to find the implementation for resource META-INF/services/javax.validation.spi.ValidationProvider
which fails the kaleo-web plugin initialization by Spring framework saying "Unable to find a default provider".

Can anybody provide some guidance on how to resolve this or rather how to make the custom classloader com.liferay.portal.spring.util.FilterClassLoader find the required resource
in the server?
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!