Results 1 to 3 of 3

Thread: <mvc:annotation-driven> ValidationException: Unable to find a default provider

  1. #1
    Join Date
    Jan 2008
    Location
    Merion, Pa
    Posts
    65

    Default <mvc:annotation-driven> ValidationException: Unable to find a default provider

    I am introducing <mvc:annotation-driven/> into an existing very large web application. I'm getting failures when <mvc:annotation-driven/> tries to instantiation JSR 303 validation:

    javax.validation.ValidationException: Unable to find a default provider

    We are not using JSR 303 validation at this point, but (probably because Websphere includes it with openjpa) Spring detects it on the classpath, attempts to configure it, fails, then renders the entire Spring applicationContext unusable. Is there some way to disable JSR validation creation even if it happens to be in the classpath?

  2. #2

  3. #3
    Join Date
    Jan 2008
    Location
    Merion, Pa
    Posts
    65

    Default

    Thanks, that's very helpful. The primary downside is the burden of keeping up with Spring's evolution. It would be preferable to have the option to directly specify this behavior. In general, the Spring framework makes lots of assumptions based on presence of libraries in the classpath; while this can be convenient, it can cause other problems when integrating with large applications especially with non-Spring libraries. As it turns out, in this case,JSR 303 validation api's were included by GWT 2.4, not websphere/openjpa as I originally thought.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •