Compare with

Comparison of DataNucleus with HSQLDB embedded vs Hibernate with SQLite 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
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
Basic Person Test14.20.0834.81.09.50.55
Element Collection Test6.60.0672.10.694.30.38
Inheritance Test13.60.0804.60.999.10.54
Indexing Test24.60.09811.11.017.80.55
Graph (Binary Tree) Test6.80.274.50.965.70.61
Multithreading Test38.5failed8.5failed23.5failed
All Tests17.40.125.90.9311.70.53

Hibernate with SQLite embedded has failed in 2 tests (see exceptions).

The results above show that in general DataNucleus with HSQLDB embedded is much more efficient than Hibernate with SQLite embedded in persisting JPA entity objects to the database. Comparing the normalized speed of Hibernate with SQLite embedded database (0.53) to the normalized speed of DataNucleus with HSQLDB embedded database (11.7) reveals that in these tests, DataNucleus with HSQLDB embedded is 22.1 times faster than Hibernate with SQLite embedded.

A huge performance gap has been detected when using database indexes with small transaction size. Comparing the normalized speed of Hibernate with SQLite embedded database (0.098) to the normalized speed of DataNucleus with HSQLDB embedded database (24.6) reveals that in that case, DataNucleus with HSQLDB embedded is 251 times faster than Hibernate with SQLite embedded.

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

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
Basic Person Test6.61.810.21.38.41.5
Element Collection Test3.60.00088.1failed5.80.0008
Inheritance Test5.72.48.81.47.21.9
Indexing Test5.11.99.52.37.32.1
Graph (Binary Tree) Test7.20.569.30.888.30.72
Multithreading Test8.1failed9.5failed8.8failed
All Tests6.01.39.21.57.61.4

Hibernate with SQLite embedded has failed in 3 tests (see exceptions).

The results above show that in general DataNucleus with HSQLDB embedded is much more efficient than Hibernate with SQLite embedded in retrieving JPA entity objects from the database. Comparing the normalized speed of Hibernate with SQLite embedded database (1.4) to the normalized speed of DataNucleus with HSQLDB embedded database (7.6) reveals that in these tests, DataNucleus with HSQLDB embedded is 5.4 times faster than Hibernate with SQLite embedded.

A huge performance gap has been detected when using JPA element collections with small retrieval size. Comparing the normalized speed of Hibernate with SQLite embedded database (0.0008) to the normalized speed of DataNucleus with HSQLDB embedded database (3.6) reveals that in that case, DataNucleus with HSQLDB embedded is 4,500 times faster than Hibernate with SQLite embedded.

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

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
Basic Person Test1.41.10.480.220.950.65
Element Collection Test1.30.390.67failed1.00.39
Inheritance Test1.60.530.610.281.10.40
Indexing Test0.00160.00110.630.430.320.21
Multithreading Test0.40failedfailedfailed0.40failed
All Tests0.960.500.600.310.800.42

DataNucleus with HSQLDB embedded has failed in 1 tests (see exceptions). Hibernate with SQLite embedded has failed in 3 tests (see exceptions).

The results above show that in general DataNucleus with HSQLDB embedded is more efficient than Hibernate with SQLite embedded in executing the tested JPA queries.

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

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
Basic Person Test11.50.0762.70.657.10.37
Element Collection Test6.90.00222.7failed4.80.0022
Inheritance Test10.30.0793.60.976.90.53
Indexing Test11.40.0574.40.547.90.30
Graph (Binary Tree) Test3.50.261.50.422.50.34
Multithreading Testfailedfailedfailedfailedfailedfailed
All Tests8.70.0943.00.655.80.34

DataNucleus with HSQLDB embedded has failed in 2 tests (see exceptions). Hibernate with SQLite embedded has failed in 3 tests (see exceptions).

The results above show that in general DataNucleus with HSQLDB embedded is much more efficient than Hibernate with SQLite embedded in updating JPA entity objects in the database. Comparing the normalized speed of Hibernate with SQLite embedded database (0.34) to the normalized speed of DataNucleus with HSQLDB embedded database (5.8) reveals that in these tests, DataNucleus with HSQLDB embedded is 17.1 times faster than Hibernate with SQLite embedded.

A huge performance gap has been detected when using JPA element collections with small transaction size. Comparing the normalized speed of Hibernate with SQLite embedded database (0.0022) to the normalized speed of DataNucleus with HSQLDB embedded database (6.9) reveals that in that case, DataNucleus with HSQLDB embedded is 3,136 times faster than Hibernate with SQLite embedded.

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
Basic Person Test4.20.0611.30.912.80.49
Element Collection Test4.90.00071.6failed3.20.0007
Inheritance Test4.00.0581.30.902.70.48
Indexing Test7.50.0791.90.544.70.31
Graph (Binary Tree) Test2.90.242.00.802.50.52
Multithreading Test40.1failed13.7failed26.9failed
All Tests10.60.0883.70.797.10.40

Hibernate with SQLite embedded has failed in 3 tests (see exceptions).

The results above show that in general DataNucleus with HSQLDB embedded is much more efficient than Hibernate with SQLite embedded in deleting JPA entity objects from the database. Comparing the normalized speed of Hibernate with SQLite embedded database (0.40) to the normalized speed of DataNucleus with HSQLDB embedded database (7.1) reveals that in these tests, DataNucleus with HSQLDB embedded is 17.7 times faster than Hibernate with SQLite embedded.

A huge performance gap has been detected when using JPA element collections with small transaction size. Comparing the normalized speed of Hibernate with SQLite embedded database (0.0007) to the normalized speed of DataNucleus with HSQLDB embedded database (4.9) reveals that in that case, DataNucleus with HSQLDB embedded is 7,000 times faster than Hibernate with SQLite embedded.

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
Basic Person Test41.490.241.490.241.490.2
Element Collection Test23.482.023.482.023.482.0
Inheritance Test41.480.541.480.541.480.5
Indexing Test48.493.449.294.848.894.1
Graph (Binary Tree) Test12.567.99.450.910.959.4
Multithreading Test51.9failed10.3failed31.1failed
All Tests36.582.829.279.732.981.2

Hibernate with SQLite embedded has failed in 2 tests (see exceptions).

The results above show that in general Hibernate with SQLite embedded is more efficient than DataNucleus with HSQLDB embedded in using disk space. Comparing the normalized score of DataNucleus with HSQLDB embedded database (32.9) to the normalized score of Hibernate with SQLite embedded database (81.2) reveals that in these tests, Hibernate with SQLite embedded is 2.5 times more efficient than DataNucleus with HSQLDB embedded.

A large gap has been detected when using graphs of objects with small transaction size. Comparing the normalized score of DataNucleus with HSQLDB embedded database (12.5) to the normalized score of Hibernate with SQLite embedded database (67.9) reveals that in that case, Hibernate with SQLite embedded is 5.4 times more efficient than DataNucleus with HSQLDB embedded.

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

Transaction/Retrieval SizeFew EntitiesMany EntitiesAverage Score
 DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
DataNucleus
HSQLDB embedded
Hibernate
SQLite embedded
Basic Person Test7.60.633.90.815.70.72
Element Collection Test4.70.0923.00.693.80.19
Inheritance Test7.10.633.80.915.40.77
Indexing Test9.70.425.50.967.60.69
Graph (Binary Tree) Test5.10.334.30.774.70.55
Multithreading Test21.8failed10.6failed17.0failed
All Tests9.00.424.80.867.00.62

The results above show that in general DataNucleus with HSQLDB embedded is much more efficient than Hibernate with SQLite embedded in performing JPA database operations. Comparing the normalized speed of Hibernate with SQLite embedded database (0.62) to the normalized speed of DataNucleus with HSQLDB embedded database (7.0) reveals that in these tests, DataNucleus with HSQLDB embedded is 11.3 times faster than Hibernate with SQLite embedded.

A huge performance gap has been detected when using JPA element collections with small transaction/retrieval size. Comparing the normalized speed of Hibernate with SQLite embedded database (0.092) to the normalized speed of DataNucleus with HSQLDB embedded database (4.7) reveals that in that case, DataNucleus with HSQLDB embedded is 51.1 times faster than Hibernate with SQLite embedded.

Other Head to Head DBMS/JPA Comparisons