Opened 12 months ago
Closed 11 months ago
#35000 closed Cleanup/optimization (fixed)
Skip redundant defaults to allow INSTANT longtext (among others) column addition in MySQL
Reported by: | Tobias Krönke | Owned by: | Tobias Krönke |
---|---|---|---|
Component: | Migrations | Version: | 4.2 |
Severity: | Normal | Keywords: | mysql, migrations, performance |
Cc: | Triage Stage: | Ready for checkin | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
MySQL 8+ is capable of adding new columns instantly just by editing the meta information. It automatically chooses the fasted algorithm for ALTER TABLE statements (https://dev.mysql.com/doc/refman/8.0/en/alter-table.html), so I was wondering if the migration SQL code generated by django actually makes use of this.
PR is here: https://github.com/django/django/pull/17539
Original comment with workaround: https://code.djangoproject.com/ticket/27676#comment:8
Change History (5)
comment:1 by , 12 months ago
Triage Stage: | Unreviewed → Accepted |
---|---|
Type: | Uncategorized → Cleanup/optimization |
comment:2 by , 12 months ago
Needs tests: | set |
---|---|
Owner: | changed from | to
Patch needs improvement: | set |
Status: | new → assigned |
comment:3 by , 11 months ago
Patch needs improvement: | unset |
---|
comment:4 by , 11 months ago
Needs tests: | unset |
---|---|
Triage Stage: | Accepted → Ready for checkin |
comment:5 by , 11 months ago
Resolution: | → fixed |
---|---|
Status: | assigned → closed |
Note:
See TracTickets
for help on using tickets.
In d6c868a1: