Search This Blog

Wednesday, November 14, 2018

How to solve JPA problem: HV000030: No validator could be found for type

This is because in your JPA entity some in-appropriate attributes are applied to your fields. For example, you apply

@Size(max = 45)

to a Long or Integer field. This may happen you re-factor your field from String to Long etc.

Another example is you use JSR303 bean validation in flavor of Hibernate Validator and you have in your JPA entity the Hibernate-specific @NotEmpty on an Integer property like this:

@NotEmpty
private Integer some;