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

Fix transaction level capability check #14920

Merged
merged 1 commit into from Sep 30, 2019
Merged

Conversation

diosmosis
Copy link
Member

No description provided.

@diosmosis diosmosis added not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org. Needs Review PRs that need a code review labels Sep 30, 2019
@diosmosis diosmosis added this to the 3.12.0 milestone Sep 30, 2019
@@ -37,12 +40,15 @@ public function canLikelySetTransactionLevel()

public function setUncommitted()
{
$backup = $this->db->fetchOne('SELECT @@TX_ISOLATION');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@diosmosis does this need to be $this->statusBackup instead of $backup?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's done below after successfully changing it. If it fails for some reason to set it then we don't need to set it back.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

makes sense 👍

@tsteur tsteur merged commit 98837a7 into 3.x-dev Sep 30, 2019
@tsteur tsteur deleted the transaction-level-fix branch September 30, 2019 03:44
@tsteur
Copy link
Member

tsteur commented Sep 30, 2019

@diosmosis fyi I'm now getting an error

SQLSTATE[HY000]: General error: 1193 Unknown system variable 'TX_ISOLATION' - in plugin Goals see https://dev.mysql.com/doc/relnotes/mysql/8.0/en/news-8-0-3.html

with MySQL8. Will investigate and create PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs Review PRs that need a code review not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants