title: Spring: java: package javax.validation.constraints does not exist
body: <p>I already have this dependency in my pom.xml file</p>
  <pre><code>&lt;dependency&gt;
        &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt;
        &lt;artifactId&gt;spring-boot-starter-validation&lt;/artifactId&gt;
  &lt;/dependency&gt;
  </code></pre>
  <p>And have refreshed Maven and already restarted IntelliJ but always get this error
  <code>java: package javax.validation.constraints does not exist</code></p>
  <p>It cannot find this package for some reason.
  But this error occurs only when I try to compile.</p>
  <p>In my Entity class I imported <code>import javax.validation.constraints.Size;</code></p>
  <p>and want to add an annotation to a column for example:</p>
  <pre><code>@Size(min = 1)
  private String name;
  </code></pre>
  <p>or</p>
  <pre><code>@DecimalMin(&quot;0.01&quot;)
  private BigDecimal amount;
  </code></pre>
  <p>But always I get the problem with the validation package.</p>
  <p>There is no error message in the IDE, the error appears when I run.</p>