Compare with

Comparison of DataNucleus with Derby embedded vs DataNucleus 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 EntitiesMany EntitiesAverage Score
 DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
Basic Person Test4.614.22.84.83.79.5
Element Collection Test2.46.61.62.12.04.3
Inheritance Test4.613.62.74.63.79.1
Indexing Test7.624.64.811.16.217.8
Graph (Binary Tree) Test1.66.81.44.51.55.7
Multithreading Test8.638.53.38.55.923.5
All Tests4.917.42.85.93.811.7

The results above show that in general DataNucleus 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 DataNucleus with HSQLDB embedded database (11.7) reveals that in these tests, DataNucleus with HSQLDB embedded is 3.1 times faster than DataNucleus with Derby embedded.

A large performance gap has been detected when using multithreading with small transaction size. Comparing the normalized speed of DataNucleus with Derby embedded database (8.6) to the normalized speed of DataNucleus with HSQLDB embedded database (38.5) reveals that in that case, DataNucleus with HSQLDB embedded is 4.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
 DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
Basic Person Test6.86.614.910.210.98.4
Element Collection Test5.43.67.68.16.55.8
Inheritance Test8.85.714.88.811.87.2
Indexing Test9.25.114.19.511.67.3
Graph (Binary Tree) Test9.97.215.89.312.98.3
Multithreading Test11.98.111.59.511.78.8
All Tests8.76.013.19.210.97.6

The results above show that in general DataNucleus with Derby embedded is more efficient than DataNucleus with HSQLDB embedded in retrieving JPA entity objects from the database.

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

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
Basic Person Test39.11.47.50.4823.30.95
Element Collection Test46.01.36.70.6726.31.0
Inheritance Test7.71.63.80.615.71.1
Indexing Test0.0530.00168.00.634.00.32
Multithreading Testfailed0.40failedfailedfailed0.40
All Tests23.20.966.50.6014.80.80

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

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

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

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
Basic Person Test4.011.53.82.73.97.1
Element Collection Test3.76.94.52.74.14.8
Inheritance Test4.410.34.83.64.66.9
Indexing Test5.211.44.24.44.77.9
Graph (Binary Tree) Test2.73.51.51.52.12.5
Multithreading Testfailedfailedfailedfailedfailedfailed
All Tests4.08.73.73.03.95.8

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

The results above show that in general DataNucleus with HSQLDB embedded is more efficient than DataNucleus with Derby embedded in updating JPA entity objects in the database.

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 DataNucleus with HSQLDB embedded database (11.5) reveals that in that case, DataNucleus with HSQLDB embedded is 2.9 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
 DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
Basic Person Test3.54.21.31.32.42.8
Element Collection Test1.94.91.61.61.73.2
Inheritance Test2.44.01.31.31.92.7
Indexing Test6.67.51.91.94.34.7
Graph (Binary Tree) Test0.812.90.932.00.872.5
Multithreading Testfailed40.1failed13.7failed26.9
All Tests3.010.61.43.72.27.1

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

The results above show that in general DataNucleus 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 DataNucleus with HSQLDB embedded database (7.1) reveals that in these tests, DataNucleus with HSQLDB embedded is 3.2 times faster than DataNucleus with Derby embedded.

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

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
Basic Person Test53.341.453.341.453.341.4
Element Collection Test42.623.442.623.442.623.4
Inheritance Test48.141.448.141.448.141.4
Indexing Test62.348.463.349.262.848.8
Graph (Binary Tree) Test13.612.510.29.411.910.9
Multithreading Test52.051.98.010.330.031.1
All Tests45.336.537.629.241.532.9

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

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

Transaction/Retrieval SizeFew EntitiesMany EntitiesAverage Score
 DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
DataNucleus
Derby embedded
DataNucleus
HSQLDB embedded
Basic Person Test11.67.66.13.98.85.7
Element Collection Test11.94.74.43.08.13.8
Inheritance Test5.67.15.53.85.55.4
Indexing Test5.79.76.65.56.27.6
Graph (Binary Tree) Test3.75.14.94.34.34.7
Multithreading Test10.321.87.410.68.817.0
All Tests8.09.05.74.86.97.0

The results above show that in general DataNucleus with HSQLDB embedded is slightly more efficient than DataNucleus with Derby embedded in performing JPA database operations.

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

On the other hand, DataNucleus with HSQLDB embedded is slower, for instance, when using JPA element collections with small transaction/retrieval size. Comparing the normalized speed of DataNucleus with HSQLDB embedded database (4.7) to the normalized speed of DataNucleus with Derby embedded database (11.9) reveals that in that case, DataNucleus with HSQLDB embedded is 2.5 times slower than DataNucleus with Derby embedded.

Other Head to Head DBMS/JPA Comparisons