You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm not super familiar with this feature of mysql, but could you set the algorithm and lock for other operations when altering a table, like adding or removing an index?
I'm not super familiar with this feature of mysql, but could you set the algorithm and lock for other operations when altering a table, like adding or removing an index?
for most of operations, only "In Place" algorithm takes place) https://dev.mysql.com/doc/refman/8.4/en/innodb-online-ddl-operations.html
So, I think it's not possible to set an algorithm for such kind of operations. For example, I need it only when need to modify column. And without migrations it's a bit painful :D
While I don't necessarily love the approach of setting options on alterColumn affecting subsequent alter column calls, I don't really have a good way to handle this in the current API, so 🤷
Thanks for the PR.
MasterOdin
changed the title
[2323] Add Native Support for ALGORITHM=INSTANT in Migrations for MYSQL
Add algorithm/lock Support for alter columns in mysql
Mar 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix for the issue - #2323
Original fix - https://github.com/cakephp/migrations/pull/955/files
Also changed version of PHP for Docker because project requires min 8.1 but there is 7.3 in the container