Compare with

Comparison of EclipseLink with PostgreSQL server vs OpenJPA with Derby server

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 EntitiesMany EntitiesAverage Score
 EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
Basic Person Test7.33.14.22.75.82.9
Element Collection Test3.12.01.91.72.51.8
Inheritance Test6.93.05.02.35.92.6
Indexing Test10.04.76.84.18.44.4
Graph (Binary Tree) Test3.50.713.30.643.40.67
Multithreading Test31.86.014.53.823.14.9
All Tests10.43.36.02.58.22.9

The results above show that in general EclipseLink with PostgreSQL server is more efficient than OpenJPA with Derby server in persisting JPA entity objects to the database. Comparing the normalized speed of OpenJPA with Derby database server (2.9) to the normalized speed of EclipseLink with PostgreSQL database server (8.2) reveals that in these tests, EclipseLink with PostgreSQL server is 2.8 times faster than OpenJPA with Derby server.

A large performance gap has been detected when using multithreading with small transaction size. Comparing the normalized speed of OpenJPA with Derby database server (6.0) to the normalized speed of EclipseLink with PostgreSQL database server (31.8) reveals that in that case, EclipseLink with PostgreSQL server is 5.3 times faster than OpenJPA with Derby server.

Speed comparison of JPA database retrieval operations (normalized score, higher is better)

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
Basic Person Test6.80.7817.211.612.06.2
Element Collection Test0.0260.00240.0201.10.0230.54
Inheritance Test6.00.01419.75.012.92.5
Indexing Test5.60.6219.513.012.66.8
Graph (Binary Tree) Test0.470.0650.610.390.540.23
Multithreading Test13.51.627.819.020.610.3
All Tests5.40.5114.18.49.84.4

The results above show that in general EclipseLink with PostgreSQL server is more efficient than OpenJPA with Derby server in retrieving JPA entity objects from the database. Comparing the normalized speed of OpenJPA with Derby database server (4.4) to the normalized speed of EclipseLink with PostgreSQL database server (9.8) reveals that in these tests, EclipseLink with PostgreSQL server is 2.2 times faster than OpenJPA with Derby server.

A huge performance gap has been detected when using class inheritance in the object model with small retrieval size. Comparing the normalized speed of OpenJPA with Derby database server (0.014) to the normalized speed of EclipseLink with PostgreSQL database server (6.0) reveals that in that case, EclipseLink with PostgreSQL server is 429 times faster than OpenJPA with Derby server.

On the other hand, EclipseLink with PostgreSQL server is slower, for instance, when using JPA element collections with large retrieval size. Comparing the normalized speed of EclipseLink with PostgreSQL database server (0.020) to the normalized speed of OpenJPA with Derby database server (1.1) reveals that in that case, EclipseLink with PostgreSQL server is 55.0 times slower than OpenJPA with Derby server.

Speed comparison of JPA database query operations (normalized score, higher is better)

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
Basic Person Test55.529.27.85.531.617.3
Element Collection Test15.42.20.0281.47.71.8
Inheritance Test54.92.211.51.033.21.6
Indexing Test0.0772.210.011.75.17.0
Multithreading Test55.335.512.08.333.721.9
All Tests36.214.38.35.622.39.9

The results above show that in general EclipseLink with PostgreSQL server is more efficient than OpenJPA with Derby server in executing the tested JPA queries. Comparing the normalized speed of OpenJPA with Derby database server (9.9) to the normalized speed of EclipseLink with PostgreSQL database server (22.3) reveals that in these tests, EclipseLink with PostgreSQL server is 2.3 times faster than OpenJPA with Derby server.

A huge performance gap has been detected when using class inheritance in the object model with small retrieval size. Comparing the normalized speed of OpenJPA with Derby database server (2.2) to the normalized speed of EclipseLink with PostgreSQL database server (54.9) reveals that in that case, EclipseLink with PostgreSQL server is 25.0 times faster than OpenJPA with Derby server.

On the other hand, EclipseLink with PostgreSQL server is slower, for instance, when using JPA element collections with large retrieval size. Comparing the normalized speed of EclipseLink with PostgreSQL database server (0.028) to the normalized speed of OpenJPA with Derby database server (1.4) reveals that in that case, EclipseLink with PostgreSQL server is 50.0 times slower than OpenJPA with Derby server.

Speed comparison of JPA database update operations (normalized score, higher is better)

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
Basic Person Test6.21.54.14.05.12.8
Element Collection Test0.0800.00810.0281.90.0540.94
Inheritance Test6.40.0436.13.86.21.9
Indexing Test6.51.87.06.86.84.3
Graph (Binary Tree) Test0.900.160.500.270.700.22
Multithreading Test36.06.99.15.022.55.9
All Tests9.31.74.53.66.92.7

The results above show that in general EclipseLink with PostgreSQL server is more efficient than OpenJPA with Derby server in updating JPA entity objects in the database. Comparing the normalized speed of OpenJPA with Derby database server (2.7) to the normalized speed of EclipseLink with PostgreSQL database server (6.9) reveals that in these tests, EclipseLink with PostgreSQL server is 2.6 times faster than OpenJPA with Derby server.

A huge performance gap has been detected when using class inheritance in the object model with small transaction size. Comparing the normalized speed of OpenJPA with Derby database server (0.043) to the normalized speed of EclipseLink with PostgreSQL database server (6.4) reveals that in that case, EclipseLink with PostgreSQL server is 149 times faster than OpenJPA with Derby server.

On the other hand, EclipseLink with PostgreSQL server is slower, for instance, when using JPA element collections with large transaction size. Comparing the normalized speed of EclipseLink with PostgreSQL database server (0.028) to the normalized speed of OpenJPA with Derby database server (1.9) reveals that in that case, EclipseLink with PostgreSQL server is 67.9 times slower than OpenJPA with Derby server.

Speed comparison of JPA database removal operations (normalized score, higher is better)

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
Basic Person Test5.71.45.73.75.72.5
Element Collection Test0.0250.0082stopped1.40.0120.71
Inheritance Test5.50.0355.42.55.41.3
Indexing Test10.42.310.03.510.22.9
Graph (Binary Tree) Test0.0160.130.0130.350.0150.24
Multithreading Test26.33.616.84.021.63.8
All Tests8.01.36.32.67.21.9

The results above show that in general EclipseLink with PostgreSQL server is much more efficient than OpenJPA with Derby server in deleting JPA entity objects from the database. Comparing the normalized speed of OpenJPA with Derby database server (1.9) to the normalized speed of EclipseLink with PostgreSQL database server (7.2) reveals that in these tests, EclipseLink with PostgreSQL server is 3.8 times faster than OpenJPA with Derby server.

A huge performance gap has been detected when using class inheritance in the object model with small transaction size. Comparing the normalized speed of OpenJPA with Derby database server (0.035) to the normalized speed of EclipseLink with PostgreSQL database server (5.5) reveals that in that case, EclipseLink with PostgreSQL server is 157 times faster than OpenJPA with Derby server.

On the other hand, EclipseLink with PostgreSQL server is slower, for instance, when using graphs of objects with large transaction size. Comparing the normalized speed of EclipseLink with PostgreSQL database server (0.013) to the normalized speed of OpenJPA with Derby database server (0.35) reveals that in that case, EclipseLink with PostgreSQL server is 26.9 times slower than OpenJPA with Derby server.

Comparison of JPA/Database speed - the averages (normalized score, higher is better)

Transaction/Retrieval SizeFew EntitiesMany EntitiesAverage Score
 EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
EclipseLink
PostgreSQL server
OpenJPA
Derby server
Basic Person Test16.37.27.85.512.16.4
Element Collection Test3.70.840.401.52.11.2
Inheritance Test15.91.19.52.912.72.0
Indexing Test6.52.310.77.88.65.1
Graph (Binary Tree) Test1.20.271.10.411.20.34
Multithreading Test32.610.716.08.024.39.4
All Tests13.13.97.84.510.54.2

The results above show that in general EclipseLink with PostgreSQL server is more efficient than OpenJPA with Derby server in performing JPA database operations. Comparing the normalized speed of OpenJPA with Derby database server (4.2) to the normalized speed of EclipseLink with PostgreSQL database server (10.5) reveals that in these tests, EclipseLink with PostgreSQL server is 2.5 times faster than OpenJPA with Derby server.

A huge performance gap has been detected when using class inheritance in the object model with small transaction/retrieval size. Comparing the normalized speed of OpenJPA with Derby database server (1.1) to the normalized speed of EclipseLink with PostgreSQL database server (15.9) reveals that in that case, EclipseLink with PostgreSQL server is 14.5 times faster than OpenJPA with Derby server.

On the other hand, EclipseLink with PostgreSQL server is slower, for instance, when using JPA element collections with large transaction/retrieval size. Comparing the normalized speed of EclipseLink with PostgreSQL database server (0.40) to the normalized speed of OpenJPA with Derby database server (1.5) reveals that in that case, EclipseLink with PostgreSQL server is 3.8 times slower than OpenJPA with Derby server.

Other Head to Head DBMS/JPA Comparisons