The check_constraints operation is extremely expensive, and not suitable
for use at the end of savepoints.

The reason why we use deferred constraints by default is mostly historical.
We do need deferred constraints for fixture loading, and applications might
rely on current implementation, but we could perhaps get away with
deferrable initially immediate constraints if the user chooses those.
Allowing users to choose constraint style requires relatively large amount
of work, so nobody has tackled that problem yet.

 - Anssi

On Monday, December 21, 2015, Артём Клименко <aklim...@gmail.com> wrote:

> I opened this ticket https://code.djangoproject.com/ticket/25955
>
> The last proposal for the improvement
> https://code.djangoproject.com/ticket/25955#comment:5
> add parameter in OPTIONS
>
> DATABASES = {
>     'default': {
>         'ENGINE': 'django.db.backends.postgresql_psycopg2',
>         # ...
>         'OPTIONS': {
>             'savepoint_check_constraints': True
>         }
>     },
> }
>
>
> https://code.djangoproject.com/attachment/ticket/25955/django_master_v2.patch
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers (Contributions to Django itself)" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com
> <javascript:_e(%7B%7D,'cvml','django-developers%2bunsubscr...@googlegroups.com');>
> .
> To post to this group, send email to django-developers@googlegroups.com
> <javascript:_e(%7B%7D,'cvml','django-developers@googlegroups.com');>.
> Visit this group at https://groups.google.com/group/django-developers.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-developers/f1d474af-1191-4110-b664-2561d9477631%40googlegroups.com
> <https://groups.google.com/d/msgid/django-developers/f1d474af-1191-4110-b664-2561d9477631%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers  (Contributions to Django itself)" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at https://groups.google.com/group/django-developers.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-developers/CALMtK1GjzZWEQxvZAGZuaSsjzVYhV8eNVLAgY8eqa5Chmw9NEg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to