springboot2.3之后hibernate-validator依赖缺失【踩坑】

这篇文章主要介绍了springboot2.3之后hibernate-validator依赖缺失【踩坑】,文中通过示例代码介绍的非常详细,对大家的学习或者工作具有一定的参考学习价值,需要的朋友们下面随着小编来一起学习学习吧

springboot2.3之后,hibernate-validator依赖缺失

今天在写项目的时候,发现@Blank注解没有了,检查了一下,发现老版本springboot内集成的hibernate-validator依赖已经去掉了

如图,当前版本2.4.0的spring-boot-starter-web包

2.4.0

版本2.1.3

2.1.3

在网上查阅了一下:

官方解释

解决方法:

在pom文件里手动加入依赖

  org.springframework.bootspring-boot-starter-validation2.3.5.RELEASE

以上就是springboot2.3之后hibernate-validator依赖缺失【踩坑】的详细内容,更多请关注0133技术站其它相关文章!

赞(0) 打赏
未经允许不得转载:0133技术站首页 » Java