Compare with

Comparison of Hibernate with HSQLDB server vs DataNucleus with Derby 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
 Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Basic Person Teststopped5.2stopped7.4stopped6.3
Element Collection Teststopped3.9stopped2.6stopped3.2
Inheritance Teststopped4.0stopped7.7stopped5.9
Indexing Teststopped7.2stopped9.9stopped8.5
Graph (Binary Tree) Teststopped2.4stopped2.0stopped2.2
Multithreading Teststopped6.0stopped0.0000stopped3.0
All Testsstopped4.8stopped4.9stopped4.9

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
 Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Basic Person Teststopped0.29stopped3.8stopped2.0
Element Collection Teststopped0.31stopped2.1stopped1.2
Inheritance Teststopped0.32stopped3.0stopped1.7
Indexing Teststopped0.31stopped3.2stopped1.8
Graph (Binary Tree) Teststopped1.2stoppedfailedstopped1.2
Multithreading Teststopped0.48stopped4.8stopped2.6
All Testsstopped0.49stopped3.4stopped1.8

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
 Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Basic Person Teststopped0.072stopped0.62stopped0.35
Element Collection Teststopped0.16stopped0.68stopped0.42
Inheritance Teststopped0.063stopped0.73stopped0.40
Indexing Teststopped0.066stopped0.67stopped0.37
Multithreading Teststopped0.33stoppedfailedstopped0.33
All Testsstopped0.14stopped0.68stopped0.38

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
 Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Basic Person Teststopped0.51stopped0.56stopped0.54
Element Collection Teststopped1.1stopped0.90stopped1.0
Inheritance Teststopped0.45stopped0.82stopped0.64
Indexing Teststopped1.9stopped0.81stopped1.4
Graph (Binary Tree) Teststopped0.41stoppedfailedstopped0.41
Multithreading Teststoppedfailedstoppedfailedstoppedfailed
All Testsstopped0.88stopped0.78stopped0.83

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
 Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Basic Person Teststopped1.8stopped0.81stopped1.3
Element Collection Teststopped2.5stopped0.25stopped1.4
Inheritance Teststopped2.1stopped0.59stopped1.3
Indexing Teststopped3.4stopped0.57stopped2.0
Graph (Binary Tree) Teststopped3.2stoppedfailedstopped3.2
Multithreading Teststoppedfailedstopped26.7stopped26.7
All Testsstopped2.6stopped5.8stopped4.2

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
 Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Hibernate
HSQLDB server
DataNucleus
Derby server
Basic Person Teststopped1.6stopped2.6stopped2.1
Element Collection Teststopped1.6stopped1.3stopped1.4
Inheritance Teststopped1.4stopped2.6stopped2.0
Indexing Teststopped2.6stopped3.0stopped2.8
Graph (Binary Tree) Teststopped1.8stopped2.0stopped1.9
Multithreading Teststopped2.3stopped10.5stopped6.4
All Testsstopped1.8stopped3.4stopped2.6

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