How to setup Eclipselink with JPA?

Posted by deamon on Stack Overflow See other posts from Stack Overflow or by deamon
Published on 2010-06-09T06:04:11Z Indexed on 2010/06/09 9:12 UTC
Read the original article Hit count: 267

Filed under:
|
|
|
|

The Eclipselink documentation says that I need the following entries in my pom.xml to get it with Maven:

<dependencies>
  <dependency>
    <groupId>org.eclipse.persistence</groupId>
    <artifactId>eclipselink</artifactId>
    <version>2.0.0</version>
    <scope>compile</scope>
       ...
  </dependency>
<dependencies>
      ...
<repositories>
  <repository>
     <id>EclipseLink Repo</id>
     <url>http://www.eclipse.org/downloads/download.php?r=1&amp;nf=1&amp;file=/rt/eclipselink/maven.repo</url>
  </repository>    
      ...
</repositories> 

But when I try to use @Entity annotation NetBeans tells me, that the class cannot be found. And indeed: there is no Entity class in the javax.persistence package from Eclipselink.

How do I have to setup Eclipselink with Maven?

© Stack Overflow or respective owner

Related posts about java

Related posts about jpa