Compare with

Comparison of DataNucleus with H2 server vs EclipseLink with MySQL 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
 DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
Basic Person Test3.43.62.21.52.82.6
Element Collection Test1.21.50.640.690.921.1
Inheritance Test3.03.51.91.42.42.4
Indexing Test5.35.33.52.54.43.9
Graph (Binary Tree) Test2.11.71.31.31.71.5
Multithreading Test10.07.24.32.47.24.8
All Tests4.23.82.31.63.22.7

The results above show that in general DataNucleus with H2 server is slightly more efficient than EclipseLink with MySQL server in persisting JPA entity objects to the database.

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

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
Basic Person Test2.50.435.215.53.98.0
Element Collection Test0.560.161.11.40.820.78
Inheritance Test2.20.396.117.64.29.0
Indexing Test2.10.437.716.64.98.5
Graph (Binary Tree) Test5.70.538.90.767.30.65
Multithreading Test2.30.198.711.05.55.6
All Tests2.50.356.310.54.45.4

The results above show that in general EclipseLink with MySQL server is slightly more efficient than DataNucleus with H2 server in retrieving JPA entity objects from the database.

A large performance gap has been detected when using simple basic entities with large retrieval size. Comparing the normalized speed of DataNucleus with H2 database server (5.2) to the normalized speed of EclipseLink with MySQL database server (15.5) reveals that in that case, EclipseLink with MySQL server is 3.0 times faster than DataNucleus with H2 server.

On the other hand, EclipseLink with MySQL server is slower, for instance, when using multithreading with small retrieval size. Comparing the normalized speed of EclipseLink with MySQL database server (0.19) to the normalized speed of DataNucleus with H2 database server (2.3) reveals that in that case, EclipseLink with MySQL server is 12.1 times slower than DataNucleus with H2 server.

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

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
Basic Person Test4.11.51.30.442.70.95
Element Collection Test4.01.40.490.432.30.92
Inheritance Test2.91.11.50.612.20.86
Indexing Test0.00360.261.50.520.750.39
Multithreading Test1.31.9failed0.721.31.3
All Tests2.51.21.20.541.90.88

DataNucleus with H2 server has failed in 1 tests (see exceptions).

The results above show that in general DataNucleus with H2 server is more efficient than EclipseLink with MySQL server in executing the tested JPA queries. Comparing the normalized speed of EclipseLink with MySQL database server (0.88) to the normalized speed of DataNucleus with H2 database server (1.9) reveals that in these tests, DataNucleus with H2 server is 2.2 times faster than EclipseLink with MySQL server.

A large performance gap has been detected when using simple basic entities with large retrieval size. Comparing the normalized speed of EclipseLink with MySQL database server (0.44) to the normalized speed of DataNucleus with H2 database server (1.3) reveals that in that case, DataNucleus with H2 server is 3.0 times faster than EclipseLink with MySQL server.

On the other hand, DataNucleus with H2 server is slower, for instance, when using database indexes with small retrieval size. Comparing the normalized speed of DataNucleus with H2 database server (0.0036) to the normalized speed of EclipseLink with MySQL database server (0.26) reveals that in that case, DataNucleus with H2 server is 72.2 times slower than EclipseLink with MySQL server.

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
Basic Person Test2.50.391.41.81.91.1
Element Collection Test2.00.231.01.41.50.83
Inheritance Test2.40.422.32.62.31.5
Indexing Test2.70.463.03.12.91.8
Graph (Binary Tree) Test1.80.670.600.411.20.54
Multithreading Testfailed0.48failed2.6failed1.5
All Tests2.30.441.72.02.01.2

DataNucleus with H2 server has failed in 2 tests (see exceptions).

The results above show that in general DataNucleus with H2 server is more efficient than EclipseLink with MySQL server in updating JPA entity objects in the database.

A large performance gap has been detected when using JPA element collections with small transaction size. Comparing the normalized speed of EclipseLink with MySQL database server (0.23) to the normalized speed of DataNucleus with H2 database server (2.0) reveals that in that case, DataNucleus with H2 server is 8.7 times faster than EclipseLink with MySQL server.

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
Basic Person Test3.40.351.31.72.31.0
Element Collection Test1.50.110.680.511.10.31
Inheritance Test2.70.291.31.62.00.94
Indexing Test5.70.461.91.93.81.2
Graph (Binary Tree) Test1.50.541.20.491.30.51
Multithreading Testfailed0.315.13.65.11.9
All Tests3.00.341.91.62.40.98

DataNucleus with H2 server has failed in 1 tests (see exceptions).

The results above show that in general DataNucleus with H2 server is more efficient than EclipseLink with MySQL server in deleting JPA entity objects from the database. Comparing the normalized speed of EclipseLink with MySQL database server (0.98) to the normalized speed of DataNucleus with H2 database server (2.4) reveals that in these tests, DataNucleus with H2 server is 2.4 times faster than EclipseLink with MySQL server.

A huge performance gap has been detected when using JPA element collections with small transaction size. Comparing the normalized speed of EclipseLink with MySQL database server (0.11) to the normalized speed of DataNucleus with H2 database server (1.5) reveals that in that case, DataNucleus with H2 server is 13.6 times faster than EclipseLink with MySQL server.

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

Transaction/Retrieval SizeFew EntitiesMany EntitiesAverage Score
 DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
DataNucleus
H2 server
EclipseLink
MySQL server
Basic Person Test3.21.32.34.22.72.7
Element Collection Test1.90.690.780.891.30.79
Inheritance Test2.61.12.64.82.62.9
Indexing Test3.21.43.54.93.33.2
Graph (Binary Tree) Test2.80.853.00.732.90.79
Multithreading Test4.52.06.04.05.33.0
All Tests2.91.22.83.32.92.3

The results above show that in general DataNucleus with H2 server is slightly more efficient than EclipseLink with MySQL server in performing JPA database operations.

A large performance gap has been detected when using graphs of objects with large transaction/retrieval size. Comparing the normalized speed of EclipseLink with MySQL database server (0.73) to the normalized speed of DataNucleus with H2 database server (3.0) reveals that in that case, DataNucleus with H2 server is 4.1 times faster than EclipseLink with MySQL server.

Other Head to Head DBMS/JPA Comparisons