Announcement Announcement Module
Collapse
No announcement yet.
TransactionProxy + Validator: IllegalArgumentException Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • TransactionProxy + Validator: IllegalArgumentException

    Hi everyone,

    I just refactored all Hibernate Daos to run through the openSessionInViewInterceptor to enable lazy-loading now everywhere.

    It all works fine except of the password change validation, which seems to get confused by this signature: com.vodafone.domain.UserBean$$EnhancerByCGLIB$$beb d757

    The full stack is:
    Code:
    java.lang.IllegalArgumentException: Validator class com.vodafone.validation.PasswordValidator does not support class com.vodafone.domain.UserBean$$EnhancerByCGLIB$$bebd757
    	org.springframework.validation.ValidationUtils.invokeValidator(ValidationUtils.java:60)
    	org.springframework.web.servlet.mvc.BaseCommandController.bindAndValidate(BaseCommandController.java:373)
    	org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:248)
    	org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
    	org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:45)
    	org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:820)
    	org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:755)
    	org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:396)
    	org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:360)
    	javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
    	javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
    	com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:118)
    	com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:52)
    	org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:292)
    	org.acegisecurity.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:108)
    	org.acegisecurity.intercept.web.SecurityEnforcementFilter.doFilter(SecurityEnforcementFilter.java:197)
    	org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:303)
    	org.acegisecurity.providers.anonymous.AnonymousProcessingFilter.doFilter(AnonymousProcessingFilter.java:143)
    	org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:303)
    	org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:214)
    	org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:303)
    	org.acegisecurity.ui.rememberme.RememberMeProcessingFilter.doFilter(RememberMeProcessingFilter.java:154)
    	org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:303)
    	org.acegisecurity.ui.AbstractProcessingFilter.doFilter(AbstractProcessingFilter.java:246)
    	org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:303)
    	org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:220)
    	org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:303)
    	org.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:173)
    	org.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:120)
    I've searched the net, the forums and JIIRA but didn't find anything which helps me. I'd appreciate any help.

    Cheers,
    Thomas

  • #2
    Hi all,

    I finally found the solution here in the forum. Not via the Forum's search, but via google. Maybe the board's search doesn't search a string inside a longer string? No idea.

    Solution is:

    changing the supports method inside the validator:

    Code:
        public boolean supports(Class clazz) {
            return UserBean.class.isAssignableFrom(clazz);
        }
    Cheers,
    Thomas

    Comment

    Working...
    X