Koitlin support for JPA static metamodel

I had to use kapt plugin.

I had to add following line to my build.gradle file.

kapt "org.hibernate:hibernate-jpamodelgen:${hibernate_version}"

When using Maven, add the following snippet to <executions> of kotlin-maven-plugin.

<execution>
   <id>kapt</id>
   <goals>
      <goal>kapt</goal>
   </goals>
   <configuration>
      <sourceDirs>
         <sourceDir>src/main/kotlin</sourceDir>
      </sourceDirs>
      <annotationProcessorPaths>
         <annotationProcessorPath>
            <groupId>org.hibernate</groupId>
            <artifactId>hibernate-jpamodelgen</artifactId>
            <version>5.3.2.Final</version>
         </annotationProcessorPath>
      </annotationProcessorPaths>
   </configuration>
</execution>