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

MYR-103 : rocksdb.gap_lock_error fails #1519

Merged
merged 1 commit into from
Mar 21, 2017

Conversation

george-lorch
Copy link
Contributor

@george-lorch george-lorch commented Mar 16, 2017

  • Test components were still creating tables w/o explicit engine specifier.
  • Fixed remaining CREATE TABLE statements and re-recorded affected tests.

@george-lorch george-lorch changed the title MYR-102 : rocksdb.gap_lock_error fails MYR-103 : rocksdb.gap_lock_error fails Mar 16, 2017
@@ -71,7 +71,6 @@ insert into u1 values (1,2,1,1) on duplicate key update c4=10;
commit;
begin;
select * from u1 where c3=1 and c1 = 1 for update;
--error ER_UNKNOWN_ERROR
select * from u1 where c3=1 for update;
Copy link
Contributor

Choose a reason for hiding this comment

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

But this is not a point select, is it? c3 is only an initial part of an unique column, and as such, this query might return a range of rows

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I don't believe so, the query should lock and return specific rows but not a true range of rows and gaps between rows. It should not be locking any space in between keys which would trigger the gap lock violation. So true, it is not a single row point select, but it is not a gap or range select either.

What I am curious about is how this behavior changed/test started failing without detection at the time of the cause. I suspect something in one of the massive upstream merges got by without me noticing due to the noise of continuous mass failures of mtr cases. I'm tempted to start a history bisection to see if I can figure at what point this changed from my initial work on MYR-15 and later work in MYR-35. i.e. why did this pass (incorrectly) before and not now?

Copy link
Contributor

Choose a reason for hiding this comment

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

OK, please find out

Copy link
Contributor Author

Choose a reason for hiding this comment

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

OK, here is the real problem, this table, u1, is not created with an engine specifier. I reported/noticed this issue while switching from the custom mtr incantation that specifies default_storage_engine to the standard mtr incantation that does not and dis not make the mental connection of that change over to where this failure started appearing. The test is broken in that this specific table is not properly created with the engine specifier.

That said, looking back at the logic, yes, your original statement is correct, I read through the !using_full_primary_key too fast, which is the first condition to be met for a gap lock. So this change is not the correct fix for the issue.

- Test components were still creating tables w/o explicit engine specifier.
- Fixed remaining CREATE TABLE statements and re-recorded affected tests.
@george-lorch
Copy link
Contributor Author

Pushed correct changes, changed PR message and now that we are into common mt code added jenkins job to prove that other tests do not break as a result
https://bugs.launchpad.net/percona-server/+bug/1674507
http://jenkins.percona.com/view/PS%205.6/job/percona-server-5.6-param/1779/

@george-lorch george-lorch merged commit 6a40171 into percona:5.6 Mar 21, 2017
@george-lorch george-lorch deleted the ps-5.6-MYR-103 branch March 21, 2017 16:05
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.

2 participants