#30060: Improve extensibility of schema migration for custom backends for new
Index/Check/Unique and other constraints
-------------------------------------+-------------------------------------
               Reporter:  Pavel      |          Owner:  nobody
  Tyslacki                           |
                   Type:             |         Status:  new
  Uncategorized                      |
              Component:  Database   |        Version:  master
  layer (models, ORM)                |
               Severity:  Normal     |       Keywords:
           Triage Stage:             |      Has patch:  1
  Unreviewed                         |
    Needs documentation:  0          |    Needs tests:  0
Patch needs improvement:  0          |  Easy pickings:  0
                  UI/UX:  0          |
-------------------------------------+-------------------------------------
 New in django 2.2 Index condition
 [https://code.djangoproject.com/ticket/29547] and Check/Unique constraints
 [https://code.djangoproject.com/ticket/29641] are a very useful, but have
 a some issues with extensibility by custom backends:

 - sql generation for migrations splitted to `schema` and
 `indexes`/`constraints` modules, but custom backend for
 `indexes`/`constraints` modules don't appliable
 - schema logic can be improved for extensibility to avoid huge overriding
 as `_alter_field` method

 to fix it proposed:

 - move sql generation from `Index`/`CheckConstraint`/`UniqueConstraint` to
 schema methods (similar to `_create_index_sql`)
 - provide methods for sql generation for index/unique/primary key/foreign
 key/check constraints

-- 
Ticket URL: <https://code.djangoproject.com/ticket/30060>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/048.ca13f56df1996b65ae4581efa1835e68%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to