I am applying multiple validations on path variable
@PathVariable(name = "id")
@NotBlank(message = "Missing required field")
@Size(min = 1, max = 3, message = "Invalid input size")
String id
Now, when I am sending empty string in path param then I am getting both messages because both validations are failing.
For my param id, I want both validations but it should not throw both error messages at a time when I am sending empty string.
I want it to throw only
"Missing required field"
and not both.