MongoDB no longer open source? 🤔

There is a Github issue about Homebrew’s dropping of MongoDB because it isn’t open source any more. There is also a HN discussion.

Here is their tweet about it:

I wonder if that will affect its popularity.

Explain’s why MongoDB was unlinked when I updated Homebrew.
I always wanted to learn Postgre. Later I intend to replace the Mongo backend of one of my projects with SQL.

1 Like

I use Mongo sometimes, because it’s easy to set up for quickly storing some data, but it has become easier with other databases too.

Many relational databases can now store JSON directly:

It’s getting easier to set up relational data for small projects too:

  • For Node.js, Sequelize and knex are pretty easy to use.
  • There is a simple ORM for Python called peewee that makes it easy to persist data.
  • I’ve been looking at using databases with Elixir and there are two built-in key-value stores (Erlang Term Storage and Mnesia/Amnesia) as well as Ecto.
  • Working with databases in Ruby only requires a few lines of code, and there are some ORMs.
  • Most other common languages have similar tools.

It seems like if an app requires defining a schema for relational data, it probably isn’t much faster to do it with Mongo than with another tool these days.

1 Like

Well, that’s the last time I’m going to suggest MongoDB to a client. Thanks for the heads-up.

1 Like

I made a repo that demos using Postgres with Node. I put Postgres in a Docker container, since I don’t have it installed on my computer. It doesn’t do more than initialize some data and query it with JS, but it at least shows the basic idea.

I used TypeScript so that I could write ES6. The syntax is all JavaScript, except for three type annotations here to get the compiler to stop complaining. For anyone who hasn’t use TypeScript, it just means that text has to be a string, params has to be an array of any type, and callback has to be a function with two parameters.

function query(
    text: string,
    params: any[],
    // I don't know the exact callback type here, but this works for now.
    callback: (err: Error, res: any) => any
) {
    return pool.query(text, params, callback);
1 Like