[meta] Add database driver for MongoDB to Core as experimental

Created on 27 June 2024, 6 months ago
Updated 21 September 2024, 3 months ago

Problem/Motivation

The main problem for why Drupal is slow is, because of getting entity data out of the database is slow. Entity data for a single entity instance is stored in many different database tables. Getting a single entity instance out of the database will result in a complicated join query. The relational database storage used by Drupal will result in getting entity data out of the database always being slow.

Conditions and sorts also often have to be run against multiple different tables, which works against database queries. If we were to try to store fields more in multiple columns, we'd also run into index limitations due to sheer index length.

Proposed resolution

Add the database driver for MongoDB as experimental to Drupal Core. All entity instance data is stored in a single JSON document. Getting a single entity instance out of the database is always a very simple query. A single row from a single database table. The same as a keyvalue store and just as fast. The database driver is a full support database driver. Only a MongoDB database is used by Drupal. No other and/or relational database is necessary. Just MongoDB.

The database driver has a contrib module. The code with a readme on how to install Drupal on MongoDB on DDEV can be found here

Remaining tasks

Hard requirements:

Not hard requirements:

Minimum requirements for MongoDB

- The minimum required version for MongoDB is 7.0. This is the most current version of MongoDB.
- A MongoDB replica set is required. MongoDB with a replica set is the minimum for transaction support. A single MongoDB instance does not support transactions. Drupal needs database transactions to do what it needs to do.

API changes

None

Data model changes

Entity instances are stored in JSON documents for MongoDB.

Release notes snippet

TBD

Feature request
Status

Active

Version

11.0 🔥

Component
Database 

Last updated 2 days ago

  • Maintained by
  • 🇳🇱Netherlands @daffie
Created by

🇳🇱Netherlands daffie

Live updates comments and jobs are added and updated live.
  • Needs product manager review

    It is used to alert the product manager core committer(s) that an issue represents a significant new feature, UI change, or change to the "user experience" of Drupal, and their signoff is needed. If an issue significantly affects the usability of Drupal, use Needs usability review instead (see the governance policy draft for more information).

  • Needs framework manager review

    It is used to alert the framework manager core committer(s) that an issue significantly impacts (or has the potential to impact) multiple subsystems or represents a significant change or addition in architecture or public APIs, and their signoff is needed (see the governance policy draft for more information). If an issue significantly impacts only one subsystem, use Needs subsystem maintainer review instead, and make sure the issue component is set to the correct subsystem.

  • Needs release manager review

    It is used to alert the release manager core committer(s) that an issue significantly affects the overall technical debt or release timeline of Drupal, and their signoff is needed. See the governance policy draft for more information.

Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024