#21039: Support Postgres "CREATE INDEX CONCURRENTLY" in migrations
-----------------------------+------------------------------------
     Reporter:  FunkyBob     |                    Owner:  (none)
         Type:  New feature  |                   Status:  new
    Component:  Migrations   |                  Version:  master
     Severity:  Normal       |               Resolution:
     Keywords:               |             Triage Stage:  Accepted
    Has patch:  0            |      Needs documentation:  0
  Needs tests:  0            |  Patch needs improvement:  0
Easy pickings:  0            |                    UI/UX:  0
-----------------------------+------------------------------------

Comment (by Dan Tao):

 Now that #25833 is resolved, it seems to me there are (at least) two
 possible ways to approach this:

 1. Add a new `CreateIndexConcurrently` operation in the
 django.contrib.postgres.operations module.
 2. Add a new `concurrent` argument to the constructor for the base
 `AddIndex` operation, and conditionally support this argument via feature
 detection based on a new attribute (maybe something like
 `supports_concurrent_index_creation`) on the base schema editor class.
 Database backends that don't support concurrent index creation (i.e.
 everything but PostgreSQL at present) would presumably raise
 `NotSupportedError` or something along those lines.

 The first option seems simpler to me, at least for now, unless there is
 compelling evidence that another database backend will support concurrent
 index creation in the near future.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/21039#comment:11>
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 django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.e1be6436612f7a965529f1b524ac770f%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to