Exception in hibernate-validator. nested exception is java.lang.NoClassDefFoundError: ConfigurationImpl

你说的曾经没有我的故事 提交于 2019-11-29 14:35:47

This is as per Hibernate Validator FAQ at

http://hibernate.org/validator/faq/

What’s the difference between Hibernate Validator 3, 4 and 5?

Hibernate Validator 3.x and 4.x/5.x are different codebases.

Hibernate Validator is the original validation framework from the Hibernate team and is now referred to as "Legacy Hibernate Validator". Hibernate Validator 4.x is the reference implementation of Bean Validation 1.0 (JSR 303), while Hibernate Validator 5.x is the reference implementation of Bean Validation 1.1 (JSR 349). Active development happens on the 5.x codebase.

Also as you are using spring validation framework for MVC:

 <!-- JSR-303 support will be detected on classpath and enabled automatically -->
 <mvc:annotation-driven />

Thus the discrepancy might be : hibernate-validator-5.x won't support JSR303, try downgrading the version to 4.x.

Also prefer Hibernate Validator 4.3.1.Final. rather than 4.2.x as both have different package structures.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!