Improving MariaDB support in open source projects
As part of MariaDB’s efforts in Adoption, we have been working on support of MariaDB in open source projects.
The open source projects we have been looking at range from well known, ready to use projects like WordPress or MediaWiki (that Wikipedia runs on), to under-the-hood solutions like ORMs that connect software with databases for countless other open source and private projects.
MariaDB is the de facto standard that many projects and users are running. As MariaDB diverges, matures and develops on its own path from MySQL, especially in later versions, it’s not enough to shrug off compatibility questions with “MariaDB is a drop-in MySQL replacement – everybody knows that”. To remove doubt from users and ensure actual technical compatibility, more efforts are required.
How can the MariaDB Foundation support projects best? Our work has revealed practical approaches starting from how projects communicate their database compatibility: Most projects have their source code shared on GitHub making it easy to review their READMEs and documentation.
Many projects mention both MariaDB and MySQL with versions in their requirements. Many other projects however, for whatever reason, only mention MySQL which can raise the question of MariaDB compatibility with the project for an end user. Other projects may have inconsistencies mentioning MariaDB in one place but not in another.
A good first step for us has been to simply reach out to the project in their GitHub discussion forum and ask “Is there any particular reason MariaDB is not mentioned in your README or requirements?”. Answers range from “yes, we should, I’ll approve a PR”, to more complex answers.
Examples of simpler updates to READMEs or docs through Pull Requests so far include Joomla, MyBB, and AlchemyCMS. Examples of slightly more complex documentation updates include Bugzilla and Ansible.
Just adding an equivalent MariaDB version to the project requirement documentation feels without basis until there is some sort of technical proof – especially for versions after MariaDB and MySQL 5.7 where paths have started to diverge. We have offered help in setting up tests for MariaDB and also MySQL with CI workflows in GitHub, a best practice in ensuring database compatibility for the project.
Examples of CI tests that the MariaDB Foundation has helped setting up include Abantecart, PrestaShop, and mysqlclient-sys.
In some cases projects don’t mention MariaDB because they are using underlying dependencies that haven’t documented or verified MariaDB compatibility themselves. Some have outstanding MariaDB compatibility bugs reported. This has led us to explore those projects to see what can be done.
Some fixes have been made on Doctrine DBAL (+ 3.8.x quickfix), PrestaShop (going further to fix compatibility in MariaDB Server), and FreVa (and fixing MariaDB Docker Official Images) to name a few.
The MariaDB Foundation does not always have sufficient language skills and may not be able to help build MariaDB compatibility straight away, but when resources become available we know where they may be needed.
Examples where development work is needed are Diesel Rust ORM and Grafana. A simpler example of pending development work is the handling of version checking of MariaDB or MySQL in WordPress, which has been discussed for its next release.
As we go though the range of projects and improve their MariaDB documentation, CI and occasionally issues, we are reminded how fragile our ecosystem is. Many projects have one or two active maintainers on which a significant user base depends. From xz to OpenSSL Heartbleed, years of open source development still leaves a large burden on few individuals. Like WordPress’ Five for the Future initiative, it’s important to give back to the community that has given you free software to use.
For anyone looking for help in fixing, documenting and ensuring your projects’ compatibility with MariaDB, reach out to expertise at MariaDB Foundation on Zulip at mariadb.zulipchat.com.