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,23 @@
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;
import java.util.Arrays;
/** Where does an annotation end up when its @Target omits RECORD_COMPONENT? */
public class RecordTarget {
@Target(ElementType.FIELD)
@Retention(RetentionPolicy.RUNTIME)
@interface FieldOnly { }
record Message(@FieldOnly String text) { }
public static void main(String[] args) throws Exception {
System.out.println("compiled: @Target(FIELD) annotation on a record component");
System.out.println("on the record component: "
+ Arrays.toString(Message.class.getRecordComponents()[0].getAnnotations()));
System.out.println("on the private field: "
+ Arrays.toString(Message.class.getDeclaredField("text").getAnnotations()));
}
}