Custom Validation in Spring Boot best explained – Part 1

In this post, we focus on a common case, when we have to check if a value in a JSON field, passed in the body of a POST request, is one of the values provided in an array we define.