title: Java 8 Spring Data JPA Parameter binding
body: <p>In my @Repository interface I created custom find method with JPQL @Query that contains parameter (addressType).</p>
  
  <p><code>from Address a where a.addressType = :addressType</code></p>
  
  <p>In the method I did not specify @Param("addressType") on the parameter. So I am getting</p>
  
  <blockquote>
    <p>java.lang.IllegalArgumentException: Name for parameter binding must not be null or empty! For named parameters you need to use @Param for query method parameters on Java versions &lt; 8.</p>
  </blockquote>
  
  <p>Okay, this is pretty much clear, but I am using Java 8. So what is special about Java 8 here?</p>