Compare with

Comparison of EclipseLink with HSQLDB embedded vs DataNucleus with Derby 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 EntitiesMany EntitiesAverage Score
 EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
Basic Person Test27.14.617.22.822.23.7
Element Collection Test17.22.48.21.612.72.0
Inheritance Test26.74.611.92.719.33.7
Indexing Test30.67.618.64.824.66.2
Graph (Binary Tree) Test20.01.615.91.418.01.5
Multithreading Test32.58.611.43.322.05.9
All Tests25.74.913.92.819.83.8

The results above show that in general EclipseLink with HSQLDB embedded is much more efficient than DataNucleus with Derby embedded in persisting JPA entity objects to the database. Comparing the normalized speed of DataNucleus with Derby embedded database (3.8) to the normalized speed of EclipseLink with HSQLDB embedded database (19.8) reveals that in these tests, EclipseLink with HSQLDB embedded is 5.2 times faster than DataNucleus with Derby embedded.

A huge performance gap has been detected when using graphs of objects with small transaction size. Comparing the normalized speed of DataNucleus with Derby embedded database (1.6) to the normalized speed of EclipseLink with HSQLDB embedded database (20.0) reveals that in that case, EclipseLink with HSQLDB embedded is 12.5 times faster than DataNucleus with Derby embedded.

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

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
Basic Person Test24.46.836.014.930.210.9
Element Collection Test14.95.419.17.617.06.5
Inheritance Test22.88.840.014.831.411.8
Indexing Test20.79.238.714.129.711.6
Graph (Binary Tree) Test8.79.914.215.811.412.9
Multithreading Test24.211.928.011.526.111.7
All Tests19.38.729.313.124.310.9

The results above show that in general EclipseLink with HSQLDB embedded is more efficient than DataNucleus with Derby embedded in retrieving JPA entity objects from the database. Comparing the normalized speed of DataNucleus with Derby embedded database (10.9) to the normalized speed of EclipseLink with HSQLDB embedded database (24.3) reveals that in these tests, EclipseLink with HSQLDB embedded is 2.2 times faster than DataNucleus with Derby embedded.

A large performance gap has been detected when using simple basic entities with small retrieval size. Comparing the normalized speed of DataNucleus with Derby embedded database (6.8) to the normalized speed of EclipseLink with HSQLDB embedded database (24.4) reveals that in that case, EclipseLink with HSQLDB embedded is 3.6 times faster than DataNucleus with Derby embedded.

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

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
Basic Person Test2.939.10.887.51.923.3
Element Collection Test3.246.01.46.72.326.3
Inheritance Test2.67.71.13.81.95.7
Indexing Test21.50.05333.38.027.44.0
Multithreading Test1.1failed0.52failed0.82failed
All Tests6.323.27.46.56.914.8

DataNucleus with Derby embedded has failed in 2 tests (see exceptions).

The results above show that in general DataNucleus with Derby embedded is more efficient than EclipseLink with HSQLDB embedded in executing the tested JPA queries. Comparing the normalized speed of EclipseLink with HSQLDB embedded database (6.9) to the normalized speed of DataNucleus with Derby embedded database (14.8) reveals that in these tests, DataNucleus with Derby embedded is 2.1 times faster than EclipseLink with HSQLDB embedded.

A huge performance gap has been detected when using JPA element collections with small retrieval size. Comparing the normalized speed of EclipseLink with HSQLDB embedded database (3.2) to the normalized speed of DataNucleus with Derby embedded database (46.0) reveals that in that case, DataNucleus with Derby embedded is 14.4 times faster than EclipseLink with HSQLDB embedded.

On the other hand, DataNucleus with Derby embedded is slower, for instance, when using database indexes with small retrieval size. Comparing the normalized speed of DataNucleus with Derby embedded database (0.053) to the normalized speed of EclipseLink with HSQLDB embedded database (21.5) reveals that in that case, DataNucleus with Derby embedded is 406 times slower than EclipseLink with HSQLDB embedded.

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
Basic Person Test17.94.07.03.812.53.9
Element Collection Test14.63.78.34.511.44.1
Inheritance Test16.24.49.74.813.04.6
Indexing Test12.05.26.84.29.44.7
Graph (Binary Tree) Test4.72.73.41.54.02.1
Multithreading Test24.4failed4.4failed14.4failed
All Tests15.04.06.63.710.83.9

DataNucleus with Derby embedded has failed in 2 tests (see exceptions).

The results above show that in general EclipseLink with HSQLDB embedded is more efficient than DataNucleus with Derby embedded in updating JPA entity objects in the database. Comparing the normalized speed of DataNucleus with Derby embedded database (3.9) to the normalized speed of EclipseLink with HSQLDB embedded database (10.8) reveals that in these tests, EclipseLink with HSQLDB embedded is 2.8 times faster than DataNucleus with Derby embedded.

A large performance gap has been detected when using simple basic entities with small transaction size. Comparing the normalized speed of DataNucleus with Derby embedded database (4.0) to the normalized speed of EclipseLink with HSQLDB embedded database (17.9) reveals that in that case, EclipseLink with HSQLDB embedded is 4.5 times faster than DataNucleus with Derby embedded.

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
Basic Person Test32.33.520.31.326.32.4
Element Collection Test14.31.96.01.610.21.7
Inheritance Test29.22.423.91.326.61.9
Indexing Test55.36.627.11.941.24.3
Graph (Binary Tree) Test6.80.8114.10.9310.40.87
Multithreading Test52.9failed28.4failed40.6failed
All Tests31.83.020.01.425.92.2

DataNucleus with Derby embedded has failed in 2 tests (see exceptions).

The results above show that in general EclipseLink with HSQLDB embedded is much more efficient than DataNucleus with Derby embedded in deleting JPA entity objects from the database. Comparing the normalized speed of DataNucleus with Derby embedded database (2.2) to the normalized speed of EclipseLink with HSQLDB embedded database (25.9) reveals that in these tests, EclipseLink with HSQLDB embedded is 11.8 times faster than DataNucleus with Derby embedded.

A huge performance gap has been detected when using class inheritance in the object model with large transaction size. Comparing the normalized speed of DataNucleus with Derby embedded database (1.3) to the normalized speed of EclipseLink with HSQLDB embedded database (23.9) reveals that in that case, EclipseLink with HSQLDB embedded is 18.4 times faster than DataNucleus with Derby embedded.

Comparison of database storage efficiency (normalized score, higher is better)

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
Basic Person Test41.453.341.453.341.453.3
Element Collection Test46.942.646.942.646.942.6
Inheritance Test41.448.141.448.141.448.1
Indexing Test48.462.349.263.348.862.8
Graph (Binary Tree) Test28.513.621.410.225.011.9
Multithreading Test51.952.010.38.031.130.0
All Tests43.145.335.137.639.141.5

The results above show that in general DataNucleus with Derby embedded is slightly more efficient than EclipseLink with HSQLDB embedded in using disk space.

On the other hand, DataNucleus with Derby embedded is slower, for instance, when using graphs of objects with large transaction size. Comparing the normalized score of DataNucleus with Derby embedded database (10.2) to the normalized score of EclipseLink with HSQLDB embedded database (21.4) reveals that in that case, DataNucleus with Derby embedded is 2.1 times less efficient than EclipseLink with HSQLDB embedded.

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

Transaction/Retrieval SizeFew EntitiesMany EntitiesAverage Score
 EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
EclipseLink
HSQLDB embedded
DataNucleus
Derby embedded
Basic Person Test20.911.616.36.118.68.8
Element Collection Test12.811.98.64.410.78.1
Inheritance Test19.55.617.35.518.45.5
Indexing Test28.05.724.96.626.56.2
Graph (Binary Tree) Test10.03.711.94.911.04.3
Multithreading Test27.010.314.67.420.88.8
All Tests20.18.015.75.717.96.9

The results above show that in general EclipseLink with HSQLDB embedded is more efficient than DataNucleus with Derby embedded in performing JPA database operations. Comparing the normalized speed of DataNucleus with Derby embedded database (6.9) to the normalized speed of EclipseLink with HSQLDB embedded database (17.9) reveals that in these tests, EclipseLink with HSQLDB embedded is 2.6 times faster than DataNucleus with Derby embedded.

A large performance gap has been detected when using database indexes with small transaction/retrieval size. Comparing the normalized speed of DataNucleus with Derby embedded database (5.7) to the normalized speed of EclipseLink with HSQLDB embedded database (28.0) reveals that in that case, EclipseLink with HSQLDB embedded is 4.9 times faster than DataNucleus with Derby embedded.

Other Head to Head DBMS/JPA Comparisons