JOOQ or JDBI?

  • It has nice type safety.
  • It’s pretty similar to SQL.
  • It’s popular.
  • It has decent documentation.
  • It has good support by Lukas Eder — The guy is very responsive.
  • It’s still not SQL, and sometimes it wasn’t obvious how to translate queries. Especially if queries are more complex. See for example: https://stackoverflow.com/questions/65129169/updating-table-rows-in-postgres-using-subquery-with-jooq
  • We are using the code-gen feature. We also use flyway and our setup is not ideal. We need flyway to update the schema (for example by commit) and only then we run the code gen to create another commit with the generated JOOQ classes. This is quite cumbersome. I guess it’s possible to automate it better than how we did it with some effort, but it’s not that obvious.
  • It’s less popular than JOOQ. For example we need JTS Geometry binding extension. JOOQ has extension for that but JDBI doesn’t.
  • The docs are not always that clear. It has good docs for the simple use cases, but some stuff is not obvious.
  • The API has 2 flavors: Fluent and Declarative. Some examples and code snippets are not for the kind we’re using. We started with the Fluent API as it is easier to migrate to it from JOOQ because it’s more similar. But many examples uses the Declarative style.
  • It’s open source, with open source kind of (best effort) support. Some questions on StackOverflow remains unanswered.

Final Thoughts

Photo by Jac Alexandru on Unsplash

--

--

--

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

How to get past console.log() and start automated testing [simple guide]

Behind the scenes with Javascript: An introduction.

Polyfills… Polyfills… Polyfills…(Part 1)

How to use React Query to perform Create, Edit, and Delete Mutation for GraphQL based Web Apps

How to Structure Your TypeScript React Application Using CRA.

Manipulating Document Object Model | CV Building | To-Do App

One app to rule them all — Building a white-label application with React Native

Vuefire CRUD Todo List App — Part 1

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
osha1

osha1

More from Medium

22 in ‘22: 22 New Breweries in 2022

Boys I Know by Anna Gracia

From the 2nd Day of the 2nd Week of the month

Why cash isn’t always the best gift, especially when it comes to your kids