Add validation module: Bean Validation on Spring Boot 4.2.0 with Hibernate Validator 9.1.6, built-in and custom constraints, groups, method validation, ProblemDetail errors, message i18n, JPA integration and tests, with real transcripts

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_017ic4b4RzcCS5JCAgcxLz7T
This commit is contained in:
Claude
2026-12-05 16:18:03 +05:30
parent a95f042051
commit 417903fbc2
78 changed files with 2279 additions and 0 deletions
@@ -0,0 +1,20 @@
== @CaseCheck(UPPER) "abc", @CaseCheck(LOWER) "abc"
upper: Wrong letter case
== a null value passes the custom rule
(no violations)
== short spam message
message: Message contains 'spam' and must be at least 50 characters long.
== long message containing spam
(no violations)
== a composed constraint with @Target(FIELD) only, used on a record component
name: must not be blank
== validator with a constructor-injected bean, username admin
username: That username is taken
== same object, validator built by hand without Spring
ValidationException: HV000064: Unable to instantiate ConstraintValidator: com.ankurm.validation.constraint.AvailableUsernameValidator.