Compare with

Comparison of DataNucleus with Derby server vs Hibernate with HSQLDB 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
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
Basic Person Test5.2stopped7.4stopped6.3stopped
Element Collection Test3.9stopped2.6stopped3.2stopped
Inheritance Test4.0stopped7.7stopped5.9stopped
Indexing Test7.2stopped9.9stopped8.5stopped
Graph (Binary Tree) Test2.4stopped2.0stopped2.2stopped
Multithreading Test6.0stopped0.0000stopped3.0stopped
All Tests4.8stopped4.9stopped4.9stopped

The results above show that in general DataNucleus with Derby server is much more efficient than Hibernate with HSQLDB server in persisting JPA entity objects to the database. Comparing the normalized speed of Hibernate with HSQLDB database server (0.0000) to the normalized speed of DataNucleus with Derby database server (4.9) reveals that in these tests, DataNucleus with Derby server is ? times faster than Hibernate with HSQLDB server.

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

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
Basic Person Test0.29stopped3.8stopped2.0stopped
Element Collection Test0.31stopped2.1stopped1.2stopped
Inheritance Test0.32stopped3.0stopped1.7stopped
Indexing Test0.31stopped3.2stopped1.8stopped
Graph (Binary Tree) Test1.2stoppedfailedstopped1.2stopped
Multithreading Test0.48stopped4.8stopped2.6stopped
All Tests0.49stopped3.4stopped1.8stopped

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

The results above show that in general DataNucleus with Derby server is much more efficient than Hibernate with HSQLDB server in retrieving JPA entity objects from the database. Comparing the normalized speed of Hibernate with HSQLDB database server (0.0000) to the normalized speed of DataNucleus with Derby database server (1.8) reveals that in these tests, DataNucleus with Derby server is ? times faster than Hibernate with HSQLDB server.

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

Retrieval Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
Basic Person Test0.072stopped0.62stopped0.35stopped
Element Collection Test0.16stopped0.68stopped0.42stopped
Inheritance Test0.063stopped0.73stopped0.40stopped
Indexing Test0.066stopped0.67stopped0.37stopped
Multithreading Test0.33stoppedfailedstopped0.33stopped
All Tests0.14stopped0.68stopped0.38stopped

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

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

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
Basic Person Test0.51stopped0.56stopped0.54stopped
Element Collection Test1.1stopped0.90stopped1.0stopped
Inheritance Test0.45stopped0.82stopped0.64stopped
Indexing Test1.9stopped0.81stopped1.4stopped
Graph (Binary Tree) Test0.41stoppedfailedstopped0.41stopped
Multithreading Testfailedstoppedfailedstoppedfailedstopped
All Tests0.88stopped0.78stopped0.83stopped

DataNucleus with Derby server has failed in 3 tests (see exceptions).

The results above show that in general DataNucleus with Derby server is much more efficient than Hibernate with HSQLDB server in updating JPA entity objects in the database. Comparing the normalized speed of Hibernate with HSQLDB database server (0.0000) to the normalized speed of DataNucleus with Derby database server (0.83) reveals that in these tests, DataNucleus with Derby server is ? times faster than Hibernate with HSQLDB server.

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

Transaction Size =>Few EntitiesMany EntitiesAverage Score
 DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
Basic Person Test1.8stopped0.81stopped1.3stopped
Element Collection Test2.5stopped0.25stopped1.4stopped
Inheritance Test2.1stopped0.59stopped1.3stopped
Indexing Test3.4stopped0.57stopped2.0stopped
Graph (Binary Tree) Test3.2stoppedfailedstopped3.2stopped
Multithreading Testfailedstopped26.7stopped26.7stopped
All Tests2.6stopped5.8stopped4.2stopped

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

The results above show that in general DataNucleus with Derby server is much more efficient than Hibernate with HSQLDB server in deleting JPA entity objects from the database. Comparing the normalized speed of Hibernate with HSQLDB database server (0.0000) to the normalized speed of DataNucleus with Derby database server (4.2) reveals that in these tests, DataNucleus with Derby server is ? times faster than Hibernate with HSQLDB server.

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

Transaction/Retrieval SizeFew EntitiesMany EntitiesAverage Score
 DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
Basic Person Test1.6stopped2.6stopped2.1stopped
Element Collection Test1.6stopped1.3stopped1.4stopped
Inheritance Test1.4stopped2.6stopped2.0stopped
Indexing Test2.6stopped3.0stopped2.8stopped
Graph (Binary Tree) Test1.8stopped2.0stopped1.9stopped
Multithreading Test2.3stopped10.5stopped6.4stopped
All Tests1.8stopped3.4stopped2.6stopped

The results above show that in general DataNucleus with Derby server is much more efficient than Hibernate with HSQLDB server in performing JPA database operations. Comparing the normalized speed of Hibernate with HSQLDB database server (0.0000) to the normalized speed of DataNucleus with Derby database server (2.6) reveals that in these tests, DataNucleus with Derby server is ? times faster than Hibernate with HSQLDB server.

A huge performance gap has been detected when using simple basic entities with small transaction/retrieval size. Comparing the normalized speed of Hibernate with HSQLDB database server (0.0000) to the normalized speed of DataNucleus with Derby database server (1.6) reveals that in that case, DataNucleus with Derby server is ? times faster than Hibernate with HSQLDB server.

Other Head to Head DBMS/JPA Comparisons