Comparison of OpenJPA with PostgreSQL server vs EclipseLink with HSQLDB embedded
Each of the following tables focuses on a specific database operation, where the last table presents average results comparison.
Speed comparison of JPA database persistence operations (normalized score, higher is better)
Transaction Size => | Few Entities | Many Entities | Average Score | |||
---|---|---|---|---|---|---|
  | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded |
Basic Person Test | 5.2 | 27.1 | 4.8 | 17.2 | 5.0 | 22.2 |
Element Collection Test | 2.8 | 17.2 | 2.2 | 8.2 | 2.5 | 12.7 |
Inheritance Test | 4.6 | 26.7 | 3.2 | 11.9 | 3.9 | 19.3 |
Indexing Test | 7.4 | 30.6 | 6.9 | 18.6 | 7.1 | 24.6 |
Graph (Binary Tree) Test | 0.98 | 20.0 | 0.81 | 15.9 | 0.89 | 18.0 |
Multithreading Test | 23.4 | 32.5 | 9.1 | 11.4 | 16.2 | 22.0 |
All Tests | 7.4 | 25.7 | 4.5 | 13.9 | 5.9 | 19.8 |
The results above show that in general EclipseLink with HSQLDB embedded is much more efficient than OpenJPA with PostgreSQL server in persisting JPA entity objects to the database. Comparing the normalized speed of OpenJPA with PostgreSQL database server (5.9) to the normalized speed of EclipseLink with HSQLDB embedded database (19.8) reveals that in these tests, EclipseLink with HSQLDB embedded is 3.4 times faster than OpenJPA with PostgreSQL server.
A huge performance gap has been detected when using graphs of objects with small transaction size. Comparing the normalized speed of OpenJPA with PostgreSQL database server (0.98) to the normalized speed of EclipseLink with HSQLDB embedded database (20.0) reveals that in that case, EclipseLink with HSQLDB embedded is 20.4 times faster than OpenJPA with PostgreSQL server.
Speed comparison of JPA database retrieval operations (normalized score, higher is better)
Retrieval Size => | Few Entities | Many Entities | Average Score | |||
---|---|---|---|---|---|---|
  | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded |
Basic Person Test | 5.8 | 24.4 | 16.1 | 36.0 | 10.9 | 30.2 |
Element Collection Test | 0.013 | 14.9 | 8.7 | 19.1 | 4.4 | 17.0 |
Inheritance Test | 5.2 | 22.8 | 17.6 | 40.0 | 11.4 | 31.4 |
Indexing Test | 4.8 | 20.7 | 18.7 | 38.7 | 11.8 | 29.7 |
Graph (Binary Tree) Test | 0.27 | 8.7 | 0.35 | 14.2 | 0.31 | 11.4 |
Multithreading Test | 11.9 | 24.2 | 23.3 | 28.0 | 17.6 | 26.1 |
All Tests | 4.7 | 19.3 | 14.1 | 29.3 | 9.4 | 24.3 |
The results above show that in general EclipseLink with HSQLDB embedded is more efficient than OpenJPA with PostgreSQL server in retrieving JPA entity objects from the database. Comparing the normalized speed of OpenJPA with PostgreSQL database server (9.4) to the normalized speed of EclipseLink with HSQLDB embedded database (24.3) reveals that in these tests, EclipseLink with HSQLDB embedded is 2.6 times faster than OpenJPA with PostgreSQL server.
A huge performance gap has been detected when using JPA element collections with small retrieval size. Comparing the normalized speed of OpenJPA with PostgreSQL database server (0.013) to the normalized speed of EclipseLink with HSQLDB embedded database (14.9) reveals that in that case, EclipseLink with HSQLDB embedded is 1,146 times faster than OpenJPA with PostgreSQL server.
Speed comparison of JPA database query operations (normalized score, higher is better)
Retrieval Size => | Few Entities | Many Entities | Average Score | |||
---|---|---|---|---|---|---|
  | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded |
Basic Person Test | failed | 2.9 | failed | 0.88 | failed | 1.9 |
Element Collection Test | failed | 3.2 | failed | 1.4 | failed | 2.3 |
Inheritance Test | failed | 2.6 | failed | 1.1 | failed | 1.9 |
Indexing Test | failed | 21.5 | failed | 33.3 | failed | 27.4 |
Multithreading Test | failed | 1.1 | failed | 0.52 | failed | 0.82 |
All Tests | failed | 6.3 | failed | 7.4 | failed | 6.9 |
OpenJPA with PostgreSQL server has failed in 10 tests (see exceptions).
Speed comparison of JPA database update operations (normalized score, higher is better)
Transaction Size => | Few Entities | Many Entities | Average Score | |||
---|---|---|---|---|---|---|
  | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded |
Basic Person Test | 4.9 | 17.9 | 3.9 | 7.0 | 4.4 | 12.5 |
Element Collection Test | 0.033 | 14.6 | 4.6 | 8.3 | 2.3 | 11.4 |
Inheritance Test | 4.8 | 16.2 | 4.9 | 9.7 | 4.9 | 13.0 |
Indexing Test | 5.1 | 12.0 | 6.0 | 6.8 | 5.6 | 9.4 |
Graph (Binary Tree) Test | 0.57 | 4.7 | 0.31 | 3.4 | 0.44 | 4.0 |
Multithreading Test | 22.2 | 24.4 | 7.4 | 4.4 | 14.8 | 14.4 |
All Tests | 6.3 | 15.0 | 4.5 | 6.6 | 5.4 | 10.8 |
The results above show that in general EclipseLink with HSQLDB embedded is more efficient than OpenJPA with PostgreSQL server in updating JPA entity objects in the database. Comparing the normalized speed of OpenJPA with PostgreSQL database server (5.4) to the normalized speed of EclipseLink with HSQLDB embedded database (10.8) reveals that in these tests, EclipseLink with HSQLDB embedded is 2.0 times faster than OpenJPA with PostgreSQL server.
A huge performance gap has been detected when using JPA element collections with small transaction size. Comparing the normalized speed of OpenJPA with PostgreSQL database server (0.033) to the normalized speed of EclipseLink with HSQLDB embedded database (14.6) reveals that in that case, EclipseLink with HSQLDB embedded is 442 times faster than OpenJPA with PostgreSQL server.
Speed comparison of JPA database removal operations (normalized score, higher is better)
Transaction Size => | Few Entities | Many Entities | Average Score | |||
---|---|---|---|---|---|---|
  | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded |
Basic Person Test | 4.6 | 32.3 | 5.3 | 20.3 | 5.0 | 26.3 |
Element Collection Test | 0.032 | 14.3 | 2.8 | 6.0 | 1.4 | 10.2 |
Inheritance Test | 4.3 | 29.2 | 4.6 | 23.9 | 4.4 | 26.6 |
Indexing Test | 8.0 | 55.3 | 7.1 | 27.1 | 7.5 | 41.2 |
Graph (Binary Tree) Test | 0.53 | 6.8 | 0.55 | 14.1 | 0.54 | 10.4 |
Multithreading Test | 17.4 | 52.9 | 9.1 | 28.4 | 13.3 | 40.6 |
All Tests | 5.8 | 31.8 | 4.9 | 20.0 | 5.4 | 25.9 |
The results above show that in general EclipseLink with HSQLDB embedded is much more efficient than OpenJPA with PostgreSQL server in deleting JPA entity objects from the database. Comparing the normalized speed of OpenJPA with PostgreSQL database server (5.4) to the normalized speed of EclipseLink with HSQLDB embedded database (25.9) reveals that in these tests, EclipseLink with HSQLDB embedded is 4.8 times faster than OpenJPA with PostgreSQL server.
A huge performance gap has been detected when using JPA element collections with small transaction size. Comparing the normalized speed of OpenJPA with PostgreSQL database server (0.032) to the normalized speed of EclipseLink with HSQLDB embedded database (14.3) reveals that in that case, EclipseLink with HSQLDB embedded is 447 times faster than OpenJPA with PostgreSQL server.
Comparison of JPA/Database speed - the averages (normalized score, higher is better)
Transaction/Retrieval Size | Few Entities | Many Entities | Average Score | |||
---|---|---|---|---|---|---|
  | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded | OpenJPA PostgreSQL server | EclipseLink HSQLDB embedded |
Basic Person Test | 5.1 | 20.9 | 7.5 | 16.3 | 6.3 | 18.6 |
Element Collection Test | 0.72 | 12.8 | 4.6 | 8.6 | 2.6 | 10.7 |
Inheritance Test | 4.7 | 19.5 | 7.6 | 17.3 | 6.2 | 18.4 |
Indexing Test | 6.3 | 28.0 | 9.7 | 24.9 | 8.0 | 26.5 |
Graph (Binary Tree) Test | 0.59 | 10.0 | 0.50 | 11.9 | 0.55 | 11.0 |
Multithreading Test | 18.7 | 27.0 | 12.2 | 14.6 | 15.5 | 20.8 |
All Tests | 6.0 | 20.1 | 7.0 | 15.7 | 6.5 | 17.9 |
The results above show that in general EclipseLink with HSQLDB embedded is more efficient than OpenJPA with PostgreSQL server in performing JPA database operations. Comparing the normalized speed of OpenJPA with PostgreSQL database server (6.5) to the normalized speed of EclipseLink with HSQLDB embedded database (17.9) reveals that in these tests, EclipseLink with HSQLDB embedded is 2.8 times faster than OpenJPA with PostgreSQL server.
A huge performance gap has been detected when using graphs of objects with large transaction/retrieval size. Comparing the normalized speed of OpenJPA with PostgreSQL database server (0.50) to the normalized speed of EclipseLink with HSQLDB embedded database (11.9) reveals that in that case, EclipseLink with HSQLDB embedded is 23.8 times faster than OpenJPA with PostgreSQL server.
Other Head to Head DBMS/JPA Comparisons
OpenJPA with PostgreSQL server against:
- Oracle Database 11g
- IBM DB2 10
- Microsoft SQL Server 2008
- DataNucleus with Derby embedded
- DataNucleus with H2 embedded
- DataNucleus with HSQLDB embedded
- DataNucleus with DB4O embedded
- DataNucleus with Derby server
- DataNucleus with H2 server
- DataNucleus with MySQL server
- DataNucleus with PostgreSQL server
- EclipseLink with Derby embedded
- EclipseLink with H2 embedded
- EclipseLink with HSQLDB embedded
- EclipseLink with SQLite embedded
- EclipseLink with Derby server
- EclipseLink with H2 server
- EclipseLink with MySQL server
- EclipseLink with PostgreSQL server
- Hibernate with Derby embedded
- Hibernate with H2 embedded
- Hibernate with HSQLDB embedded
- Hibernate with SQLite embedded
- Hibernate with Derby server
- Hibernate with H2 server
- Hibernate with MySQL server
- Hibernate with PostgreSQL server
- OpenJPA with Derby embedded
- OpenJPA with H2 embedded
- OpenJPA with HSQLDB embedded
- OpenJPA with Derby server
- OpenJPA with H2 server
- OpenJPA with MySQL server
- ObjectDB embedded
- ObjectDB server
EclipseLink with HSQLDB embedded against:
- Oracle Database 11g
- IBM DB2 10
- Microsoft SQL Server 2008
- DataNucleus with Derby embedded
- DataNucleus with H2 embedded
- DataNucleus with HSQLDB embedded
- DataNucleus with DB4O embedded
- DataNucleus with Derby server
- DataNucleus with H2 server
- DataNucleus with MySQL server
- DataNucleus with PostgreSQL server
- EclipseLink with Derby embedded
- EclipseLink with H2 embedded
- EclipseLink with SQLite embedded
- EclipseLink with Derby server
- EclipseLink with H2 server
- EclipseLink with MySQL server
- EclipseLink with PostgreSQL server
- Hibernate with Derby embedded
- Hibernate with H2 embedded
- Hibernate with HSQLDB embedded
- Hibernate with SQLite embedded
- Hibernate with Derby server
- Hibernate with H2 server
- Hibernate with MySQL server
- Hibernate with PostgreSQL server
- OpenJPA with Derby embedded
- OpenJPA with H2 embedded
- OpenJPA with HSQLDB embedded
- OpenJPA with Derby server
- OpenJPA with H2 server
- OpenJPA with MySQL server
- OpenJPA with PostgreSQL server
- ObjectDB embedded
- ObjectDB server