Notice: This Wiki is now read only and edits are no longer possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Difference between revisions of "EclipseLink/Maven"
(→) |
(→) |
||
Line 47: | Line 47: | ||
| The full eclipselink.jar intended for non-OSGi environments. | | The full eclipselink.jar intended for non-OSGi environments. | ||
| javax.persistence<br/>commonj.sdo | | javax.persistence<br/>commonj.sdo | ||
− | | [http://download.eclipse.org/rt/eclipselink/maven.repo/org/eclipse/persistence/eclipselink/2.4.0/eclipselink-2.4.0.pom | + | | [http://download.eclipse.org/rt/eclipselink/maven.repo/org/eclipse/persistence/eclipselink/2.4.0/eclipselink-2.4.0.pom 2.4.0.pom] |
|- | |- | ||
− | | org.eclipse.persistence. | + | | org.eclipse.persistence.jpa |
− | | EclipseLink | + | | EclipseLink JPA OSGI bundle |
− | | | + | | javax.persistence<br/>org.eclipse.persistence.asm<br/>org.eclipse.persistence.antlr<br/>org.eclipse.persistence.jpa.jpql<br/>org.eclipse.persistence.core |
+ | | [http://download.eclipse.org/rt/eclipselink/maven.repo/org/eclipse/persistence/org.eclipse.persistence.jpa/2.4.0/org.eclipse.persistence.jpa-2.4.0.pom 2.4.0.pom | ||
|- | |- | ||
| org.eclipse.persistence.dbws | | org.eclipse.persistence.dbws | ||
| EclipseLink DBWS OSGI bundle | | EclipseLink DBWS OSGI bundle | ||
− | |||
− | |||
− | |||
|- | |- | ||
| org.eclipse.persistence.jpa.modelgen | | org.eclipse.persistence.jpa.modelgen | ||
Line 79: | Line 77: | ||
| org.eclipse.persistence.sdo | | org.eclipse.persistence.sdo | ||
| EclipseLink SDO OSGI bundle | | EclipseLink SDO OSGI bundle | ||
− | |||
− | |||
− | |||
|- | |- | ||
| org.eclipse.persistence.equinox | | org.eclipse.persistence.equinox |
Revision as of 13:13, 22 August 2012
The EclipseLink project currently produces a maven repository for its releases
If you have any questions about using it, or experience problems, please let us know on our users mailing list or forum.
Configuring your pom.xml
To help users diagnose Maven issues, we have created a basic POM that simply establishes EclipseLink dependencies (currenly using the 2.4.0 release). Executing it will verify your connection to the repository. Alternate Repository URLs are discussed. The POM can be found [here].
<repository>
Within your pom.xml you will need to specify the EclipseLink repository using:
<repository> <id>EclipseLink Repo</id> <url>http://download.eclipse.org/rt/eclipselink/maven.repo</url> </repository>
<dependencies>
The artifacts can then be added to you pom as follows. The complete list of available artifacts and their usage is below.
<dependency>\ <groupId>org.eclipse.persistence</groupId> <artifactId>{artifact}</artifactId> <version>{version}</version> <scope>compile</scope> </dependency>
The following are the primary artifacts. All listed dependencies are also included in this repository.
Artifact Id | Description | Dependencies | POM |
---|---|---|---|
eclipselink | The full eclipselink.jar intended for non-OSGi environments. | javax.persistence commonj.sdo |
2.4.0.pom |
org.eclipse.persistence.jpa | EclipseLink JPA OSGI bundle | javax.persistence org.eclipse.persistence.asm org.eclipse.persistence.antlr org.eclipse.persistence.jpa.jpql org.eclipse.persistence.core |
[http://download.eclipse.org/rt/eclipselink/maven.repo/org/eclipse/persistence/org.eclipse.persistence.jpa/2.4.0/org.eclipse.persistence.jpa-2.4.0.pom 2.4.0.pom |
org.eclipse.persistence.dbws | EclipseLink DBWS OSGI bundle | ||
org.eclipse.persistence.jpa.modelgen | EclipseLink Modelgen pre-processor (non-OSGI) | ||
org.eclipse.persistence.moxy | EclipseLink MOXY OSGI bundle | ||
org.eclipse.persistence.nosql | OSGI fragment of Core bundle for NoSQL support (including MongoDB) | ||
org.eclipse.persistence.oracle | OSGI fragment of Core bundle with Oracle-DB specific EclipseLink extensions | ||
org.eclipse.persistence.oracle.nosql | OSGI fragment of Core bundle for Oracle specific NoSQL support | ||
org.eclipse.persistence.osgi | | ||
org.eclipse.persistence.sdo | EclipseLink SDO OSGI bundle | ||
org.eclipse.persistence.equinox | EclipseLink JPA Equinox OSGi Fragment | ||
org.eclipse.persistence.jpa.modelgen.processor | EclipseLink JPA Modelgen Processor (non-OSGi) (Meta-data only) | ||
org.eclipse.persistence.tools.oracleddl | Oracle DB model - OSGi bundle | ||
org.eclipse.persistence.weaving | EclipseLink JPA - "Weaving for Equinox" OSGi Fragment |
What bundles should I get
The following lists what you should get based on your needs
Full functionality - non OSGI
This is the recommended way of getting EclipseLink unless you are using OSGi, or you want to explicitly exclude certain parts of EclipseLink
- eclipselink
- javax.persistence (optional - only needed if you are using JPA outside of a Java EE container)
JPA
- JPA
- Core (starting in 2.0.0 should be retrieved by maven dependency mechanism)
- Antlr (starting in 2.0.0 should be retrieved by maven dependency mechanism)
- Asm (starting in 2.0.0 should be retrieved by maven dependency mechanism)
- javax.persistence
- Oracle (optional - only needed to access Oracle DB specific functionality)
MOXy
- MOXy
- Core (starting in 2.0.0 should be retrieved by maven dependency mechanism)
- Antlr (starting in 2.0.0 should be retrieved by maven dependency mechanism)
- Asm (starting in 2.0.0 should be retrieved by maven dependency mechanism)
SDO
- SDO
- MOXy
- Core (starting in 2.0.0 should be retrieved by maven dependency mechanism)
- Antlr (starting in 2.0.0 should be retrieved by maven dependency mechanism)
- Asm (starting in 2.0.0 should be retrieved by maven dependency mechanism)
Versioning
Available Released Versions
- 2.4.0
- 2.3.3
- 2.3.2
- 2.3.1
- 2.3.0
- 2.2.1
- 2.2.0
- 2.1.3
- 2.1.2
- 2.1.1
- 2.1.0
- 2.0.2
- 2.0.1
- 2.0.0
- JPA 2.0 Implementation release
- 1.2.0
- 1.1.4
- final 1.1.x patchset
- 1.1.3
- 1.1.2
- Eclipse Galileo Release
- 1.1.1
- 1.1.0
- 1.0.2
- 1.0.1
- 1.0
NOTE: javax.persistence (JPA 2.0) has been released as version 2.0.0, 2.0.1, 2.0.2, and 2.0.3
Releases Under development
- 2.5.0
- 2.4.1
- 2.3.4
Under development releases have the following additional naming conventions
- <releaseNumber>-SNAPSHOT (The most recent nightly build e.g. 2.1.0-SNAPSHOT)
- <releaseNumber>-Mx (For milestones, replace x with the milestone number e.g. 2.0.0-M1)
- <releaseNumber>-RCx (For release candidates, replace x with the release candidate number e.g. 2.0.0-RC1)
Sample pom.xml
The following pom.xml is from an EclipseLink example that uses JPA to access a MySQL database and leverages JUnit for testing.
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>org.eclipse.persistence.example</groupId> <artifactId>Employee</artifactId> <version>0.0.1-SNAPSHOT</version> <packaging>jar</packaging> <name>Employee Example</name> <url>http://wiki.eclipse.org/EclipseLink/Examples/JPA/Employee</url> <description>Simple JPA example using annotations.</description> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <eclipselink.version>2.4.0</eclipselink.version> </properties> <repositories> <repository> <id>EclipseLink</id> <url>http://download.eclipse.org/rt/eclipselink/maven.repo</url> </repository> </repositories> <dependencies> <!-- eclipselink.jar with dependencies except commonj.sdo --> <dependency> <groupId>org.eclipse.persistence</groupId> <artifactId>eclipselink</artifactId> <version>${eclipselink.version}</version> <exclusions> <exclusion> <artifactId>commonj.sdo</artifactId> <groupId>commonj.sdo</groupId> </exclusion> </exclusions> </dependency> <dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId> <version>5.1.21</version> </dependency> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <version>4.8.2</version> </dependency> </dependencies> <build> ... </build> </project>