H2 is a lightweight database server written in Java. It can be embedded in Java applications, or run as a standalone server.
In this tutorial, we’ll review why H2 can be a good option for your projects. We’ll also learn how to integrate H2 with Node.js by building a simple Express API.
H2 was built with performance in mind.
“H2 is a combination of: fast, stable, easy to use, and features”.
Although H2 is prominent mainly because it can be embedded in Java applications, it has some interesting features that also apply to its server version. Let’s see some of them next.
The .jar file used for the server version is around 2MB. We can download it from the H2 site, bundled with extra scripts and documentation. If we search in Maven Central though, we can download the .jar file on its own.
H2 performance shines in its embedded version. Even so, the official benchmark shows that its client-server version is also impressive.
#node #javascript #h2 #database #express