Skip to content

Add support for MariaDB connection in configuration and URI generation #1552

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

Vasanth-96
Copy link

@Vasanth-96 Vasanth-96 commented May 6, 2025

A Pull Request should be associated with an Issue.

We wish to have discussions in Issues. A single issue may be targeted by multiple PRs.
If you're offering a new feature or fixing anything, we'd like to know beforehand in Issues,
and potentially we'll be able to point development in a particular direction.

Related issue: #1488
#1488

Further notes in https://github.com/github/gh-ost/blob/master/.github/CONTRIBUTING.md
Thank you! We are open to PRs, but please understand if for technical reasons we are unable to accept each and any PR

Description

This PR addresses the issue encountered with MariaDB 10.3 when running gh-ost version 1.1.7. The error occurs due to the use of the transaction_isolation system variable, which is not present in MariaDB 10.3. Instead, MariaDB 10.3 uses tx_isolation to configure the transaction isolation level.

In case this PR introduced Go code changes:

  • contributed code is using same conventions as original code
  • script/cibuild returns with no formatting errors, build errors or unit test errors.

attaching the images
image
image

@Vasanth-96
Copy link
Author

HI @rashiq @meiji163 @timvaillancourt could you guys review this pr and let me know if any more fix/changes need!
thanks!

@meiji163
Copy link
Contributor

Thanks for your PR @Vasanth-96! Ideally we should run the localtests on a MariaDB docker image. I'm not sure if there's one that works out of the box.

@Vasanth-96
Copy link
Author

Thanks for the suggestion, @meiji163
I’ve already tested the changes locally using a MariaDB 10.3.31 container:

CONTAINER ID   IMAGE             COMMAND                  CREATED      STATUS      PORTS                    NAMES  
f8ae17daf37b   mariadb:10.3.31   "docker-entrypoint.s…"   6 days ago   Up 6 days   0.0.0.0:3306->3306/tcp   mariadb-container-fix

The fallback to tx_isolation is working as expected.
Let me know if you’d like me to add a CI test setup for MariaDB as well!

@Vasanth-96
Copy link
Author

@meiji163 please if you could checkout the reply comment thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants