The Contributing Code page on the Knowledge Base details many of the actual steps involved in working with the MariaDB source code. See this page on JIRA for beginner-friendly tasks as well as this page for more.
It’s important that you use the same tools and submit patches in the same way as other developers to keep development running smoothly.
All MariaDB code is developed and maintained with git. Using GitHub is optional, but it makes contributing very easy thanks to the pull request process on GitHub and your contributions will be visible in your GitHub profile. Below are instructions that apply directly for GitHub users:
- Open the page https://github.com/mariadb/server and click “Fork” to create your own development branch.
- Clone your own branch to your local computer:
git clone --depth=50 --branch=10.4 https://github.com/mariadb/server(The full repository is well over 1 GB in size so limiting git clone scope will decrease the download significantly.)
- Create your feature or bugfix branch e.g.:
git checkout -b fix-macosx-build
- Hack the code. Create a test to match you new code. Make sure everything builds OK and test suite passes.
- Run git commit and git push to your GitHub branch. Open a pull request on GitHub. Try to make one commit and one pull request for each logical set of changes.
Unlike some other related projects, in MariaDB all development is public and every commit done by any developer is visible in real-time to the world to build upon.
Development of new features is done on the development master branch, currently 10.4. In general all development is done on the master branch first, and later high-priority bug fixes might be backported to stable release branches (10.3, 10.2, 10.1, 10.0, 5.5).
If a patch is very safe and/or very useful we are willing to push it into the stable code (as long as it can’t break any existing applications). We are willing to do this to ensure the freedom to add small, needed fixes on a stable release so users don’t have to wait a year for something to be added which is critical to their business.
We are very responsive toward reviews of submitted code and as soon as the review is done, the submitted code is merged into an existing MariaDB tree and made available to everyone. Code reviews are performed by the MariaDB core development team and the quality, detail, and timeliness of our reviews are better than you will find elsewhere.
Not just any bit of code can be accepted into MariaDB. In general, we expect any code you contribute to:
- be nice, modular, performant, easy to read, and believed to be bug free.
- be properly reviewed by at least one maria-captain.
- follow the MariaDB coding standards.
- not contain duplicated code / features that we already have.
- provide a new valuable addition to MariaDB that benefits a large number of users.
- not break anything for old MySQL / MariaDB users.
- not stop anyone from implementing another important feature.
On a personal note, we expect you to:
- follow the Ubuntu Code Of Conduct
- participate in e-mail discussions via our Launchpad lists (whichever list is most appropriate):
- maintain a positive, productive, light-hearted attitude. Developers temporarily stepping away gracefully to ensure real productivity is always understood in our community. Emphasis on gracefully.
- work with the maria-captains to get your code approved.
- submit your approved code to the captain who worked on your review or to the email list for inclusion in MariaDB.
- take ownership of the code that you submit, and interact as a cohesive whole with other code-owners. This means you should:
- fix bugs in your code
- review, approve or apply your own version of code that people submit to you that touches your code.
- be available for people that want to discuss your code.
- help upgrade your code from one MariaDB version to the next.
If you are unable or unwilling to follow the above expectations, then the maria-captains, or ultimately the MariaDB Foundation, will find someone who will collaborate maintaining your code.
If you are an active contributor, you can become a member of maria-captains, even if you aren’t working for the MariaDB Foundation or MariaDB Corporation. All captains have the same rights as any other captain to accept and reject patches. Our development model is truly open for everyone.
Similar to other open source projects, the MariaDB foundation needs to have a shared ownership of the code that is included in the MariaDB distribution. This can be done by submitting your code under the BSD-new license. The only currently known exceptions to this rule are storage engines and code that is loadable through a plugin. For these, it’s enough that the code is GPL.
- Most of the core developers hang out on Zulip and on IRC in the #maria channel on freenode
- Code, proposals, and feature requests are sent to (and discussed on) the maria-developers list.
- The MariaDB Foundation also hosts regular times where developers are available to assist new contributors on Zulip and on IRC. See Live Q&A for New MariaDB Contributors.