An example showing how to set up and test JPA classes.
The project offers examples showing how to set up and test JPA classes, covering the following cases:
Documentation is always generated for the latest release, kept in the 'master' branch:
Documentation is also generated from the latest snapshot, taken from the 'develop' branch:
The documentation site sources come along the source code (as it is a Maven site), so it is always possible to generate them using the following Maven command:
mvn verify site -P h2,eclipselink
The verify phase is required, as otherwise some of the reports won't be created.
The application is coded in Java, using Maven to manage the project.
Maven profiles are included for setting up the database and JPA provider.
Profile | Database |
---|---|
h2 | H2 in-memory database |
hsqldb | HSQLDB in-memory database |
mysql | MySQL database |
postgres | PostgreSQL database |
Profile | Provider |
---|---|
hibernate | Hibernate |
eclipselink | Eclipselink |
The project requires a database and a JPA provider for being able to run the integration tests:
mvn verify -P h2,eclipselink
Currently there are some problems when generating the JPA metadata classes automatically. Mainly that they are not generated when trying to refresh the Maven project on Eclipse.
To fix this just package the project:
mvn package
Any kind of help with the project will be well received, and there are two main ways to give such help:
Issues are managed at the GitHub project issues tracker, where any Github user may report bugs or ask for new features.
If you wish to fork or modify the code, visit the GitHub project page, where the latest versions are always kept. Check the 'master' branch for the latest release, and the 'develop' for the current, and stable, development version.
The project has been released under the MIT License.