Hibernate Reactive: Is It Worth It?

java database October 29, 2021

The Hibernate team announced the release of Hibernate Reactive 1.0.0.Final on October 27, 2021, which gives applications using reactive architecture access to non-blocking object-relational access. They also wrote a fascinating blog entry, “Hibernate Reactive: Is It Worth It?.”

The blog entry is pretty interesting. From the first section:

We were curious to see if we can indeed show when it might be worth switching to Hibernate Reactive when working with relational databases: both for our own understanding, and to help all of you make a reasonable decision.

We discovered it’s not simple to answer such questions as databases are designed for classic interactions; this has implications at various levels - from the low-level protocol design up to higher-level constructs, such as the highly desirable need to encapsulate units of work in ACID transactions, which are modeled by defining explicit boundaries for the “work” being performed: a transaction begins at a point in time A, ends at a point in time B, and all operations enqueued on that same connection within those markers are considered as taking part within this scope.

It’s written with some depth, including performance graphs; in general, as expected, designs that leverage the strengths of each architecture tend to perform better (and there’s still a ceiling); the one thing the graphs don’t have that I would have liked to have seen is a comparison with no ORM in the mix (perhaps straight JDBC, as well as reactive-JDBC) to see what Hibernate and Hibernate-Reactive actually add or take from the architecture.

Congrats to the Hibernate team on a successful release!

in database architecture reactive java

Reading time: 1 minute.