Active Oldest Votes. Validation starter not included in web starters anymore. Add this dependency for validations work. Improve this answer. Braian Silva Braian Silva 1, 12 12 silver badges 17 17 bronze badges. The werid thing on my screen is, that I see the spring-boot-starter-validation as external dependency but it does not work anyway. For me, the problem was that it's not transitive as you said.
So even if it was present in a base-library it was not working on the main app and need to add it there as well. Thank you! LalithK90 LalithK90 6 6 silver badges 13 13 bronze badges.
If your experiencing the issue of for example: not being able to see the validation errors default-messages returned back to the client, this is what you could do: Top Solution 1: Simply add devtools. Esther Esther 4 4 silver badges 9 9 bronze badges. Thanks for solution 2! This answer saved the day, solution 2 worked for my issue after trying to upgrade Spring Boot from 2. Actually there error was in the unit tests.
The validation was working well. Duplicate post below 24 May — Grigory Kislin. GrigoryKislin why does it duplicate? I'm saying the unit tests were wrong and refer to Braian Silva's post.
Hi You have to annotate you controller class with Validated annotation see example below: For testing purpose please try commenting Validated annotation you won't notice javax. Even though, I tested with Validated and it's not working anyway. Did the 2. This will fix the issue with this version Vipul. Vipul Goyal Vipul Goyal 9 3 3 bronze badges. Can you explain where the solution lies???
This is a Spring-Boot versioning vs dependency issue — Esther. Sign up or log in Sign up using Google. Sign up using Facebook. Sign up using Email and Password. Post as a guest Name. Email Required, but never shown. The Overflow Blog. Does ES6 make JavaScript frameworks obsolete? Podcast Do polyglots have an edge when it comes to mastering programming Featured on Meta. Now live: A fully responsive profile.
Linked 4. Related 6. Hot Network Questions. Question feed. Stack Overflow works best with JavaScript enabled. Accept all cookies Customize settings.
R Programming. React Native. Python Design Patterns. Python Pillow. Python Turtle. Verbal Ability. Interview Questions.
Company Questions. Artificial Intelligence. Cloud Computing. Data Science. Angular 7. Machine Learning. Data Structures. Operating System. Computer Network. Compiler Design. Computer Organization. Discrete Mathematics. Ethical Hacking. Computer Graphics. Software Engineering. Web Technology. Cyber Security. C Programming. Control System.
0コメント