-
-
Notifications
You must be signed in to change notification settings - Fork 439
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
Disable DISABLE KEYS
statements
#188
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
+1
looks ok, I have no idea who is using MYISAM tables with Magento anyway.
I was testing it with Magento and sample data and no issue with reindexing.
Would you mind rebasing or resubmitting on 1.9.3.x branch? Otherwise I approve. |
…ove useless calls to useDisableKeys()
Rebased on 1.9.3.x |
@colinmollenhour would you mind merging it once you approve? |
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
disable 'ALTER TABLE ... DISABLE KEYS' statements by default, and remove useless calls to useDisableKeys()
This is part of a group of PRs containing the changes discussed in issue #152
Indexers that extend
Mage_Index_Model_Resource_Abstract
run anALTER TABLE ... DISABLE|ENABLE KEYS
statement before and after inserting data.The statement is only supported by MyISAM tables so it is useless for modern magento installations, but it still requires a table metadata lock even if MyISAM is not used.
The catalogsearch index does still use MyISAM, but it doesn't extend
Mage_Index_Model_Resource_Abstract
so it isn't affected.This PR disables the statements by default, but leaves the functionality in place if still required.
It also removes calls to
Mage_Index_Model_Resource_Abstract::useDisableKeys
. In most cases it was called by mistake and had no effect (it should have beenMage_Index_Model_Resource_Abstract::disableTableKeys
), but now they aren't required at all.