Unleash/unleash

Support databases other than Postgres

Closed this issue · 3 comments

Support for some other DBs would be really nice.

To start:

  • MongoDB
  • MySQL

MySQL would be "easy" to support because we are using Knex. MongoDB would require building an abstraction layer on top...

First of all, thanks for showing interest in the project @mhamann 😃

Previously we have discussed to support multiple databases. There is more to it than "just" support multiple databases. This will require custom migrations, db-specific features, db-drivers, e2e test per db etc. This will obviously increase the complexity of the code, make it harder to add new features and harder to maintain, and easier to introduce bugs.

If we are going on this route we should, in my view, do this by providing a explicit data-store contract and allow the user to provide an implementation of that contract. Each data-store implementation should be its own artifact.

Another approach could be to see if we are able to drop the database in full, and go down the route of event-sourced and append-only log written to disc. Then we could focus more on pushing changes to the view and make it more "real-time-ish". Personally I think this could be a suitable architecture for Unleash, but I would of course bring a long other kind of complexities.

I'm curious to learn more about your use-case? Is it because it is "nice to have"? Or is it because it's difficult to set up a postgres instance for Unleash? We obviously would like it to be easy to adopt Unleash!

Closing as no more details is provided.