Skip to content
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

Abstract database get_lock to the current PDO adapter #19643

Open
bx80 opened this issue Aug 19, 2022 · 3 comments
Open

Abstract database get_lock to the current PDO adapter #19643

bx80 opened this issue Aug 19, 2022 · 3 comments
Assignees
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc.

Comments

@bx80
Copy link
Contributor

bx80 commented Aug 19, 2022

Many distributed databases do not support the MySQL get_lock() function. In order to be able to support alternative databases in the future we need to abstract the use of get_lock() to the configured PDO adapter.

Instead of calling get_lock() directly all code should call a new getLock() method on the current PDO adapter which will allow locking to be handled differently for each database type. All Matomo PDO adapters should be implementing core/Db/AdapterInterface which can contain the new abstract method definition.

This should not change locking behavior for MySQL in any way.

@bx80 bx80 added the Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc. label Aug 19, 2022
@bx80 bx80 self-assigned this Oct 6, 2022
@jSML4ThWwBID69YC
Copy link

It appears that recent MariaDB changes have broken Matomo. (https://jira.mariadb.org/browse/MDEV-30473 )

Matomo worked on Galera before that change. Is this the right issue for a long term solution to using Glaera?

@bx80
Copy link
Contributor Author

bx80 commented Jun 6, 2023

Hi @jSML4ThWwBID69YC, that's correct 👍

This issue when implemented would add support for databases that do not support GET_LOCK() which should then allow Galera to work as before.

@jSML4ThWwBID69YC
Copy link

Hi @jSML4ThWwBID69YC, that's correct +1

This issue when implemented would add support for databases that do not support GET_LOCK() which should then allow Galera to work as before.

Then this is my vote for it. Despite working for over a year, my Matomo is now oddly broken.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement For new feature suggestions that enhance Matomo's capabilities or add a new report, new API etc.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants