[Django] #26207: New implementation for deferred instance loading

33 views
Skip to first unread message

Django

unread,
Feb 11, 2016, 4:21:51 AM2/11/16
to django-...@googlegroups.com
#26207: New implementation for deferred instance loading
-------------------------------------+-------------------------------------
Reporter: akaariai | Owner: nobody
Type: | Status: new
Cleanup/optimization |
Component: Database | Version: master
layer (models, ORM) |
Severity: Normal | Keywords:
Triage Stage: | Has patch: 0
Unreviewed |
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-------------------------------------+-------------------------------------
Instead of creating subclasses of the real model with descriptors for the
deferred fields, always add non-data descriptors for all concrete fields.
Gone is dynamic class creation for deferred loading!

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

Django

unread,
Feb 11, 2016, 8:21:15 AM2/11/16
to django-...@googlegroups.com
#26207: Replace dynamic classes with non-data descriptors for deferred instance

loading
-------------------------------------+-------------------------------------
Reporter: akaariai | Owner: nobody
Type: | Status: new
Cleanup/optimization |
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 1

Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):

* needs_better_patch: 0 => 1
* has_patch: 0 => 1
* stage: Unreviewed => Accepted


Comment:

[https://github.com/django/django/pull/6118 PR] and
[https://groups.google.com/d/msg/django-
developers/BDAlTyJwQeY/Fh2Qy07cAQAJ django-dev discussion]

--
Ticket URL: <https://code.djangoproject.com/ticket/26207#comment:1>

Django

unread,
Apr 25, 2016, 8:50:38 PM4/25/16
to django-...@googlegroups.com
#26207: Replace dynamic classes with non-data descriptors for deferred instance

loading
-------------------------------------+-------------------------------------
Reporter: akaariai | Owner: nobody
Type: | Status: new
Cleanup/optimization |
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by timgraham):

* needs_better_patch: 1 => 0


Comment:

[https://github.com/django/django/pull/6491 Updated PR] with cosmetic
edits + docs. One TODO remains from Anssi's original PR that I'm not sure
how to handle.

--
Ticket URL: <https://code.djangoproject.com/ticket/26207#comment:2>

Django

unread,
Apr 29, 2016, 8:53:05 PM4/29/16
to django-...@googlegroups.com
#26207: Replace dynamic classes with non-data descriptors for deferred instance

loading
-------------------------------------+-------------------------------------
Reporter: akaariai | Owner: nobody
Type: | Status: closed

Cleanup/optimization |
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Tim Graham <timograham@…>):

* status: new => closed
* resolution: => fixed


Comment:

In [changeset:"7f51876f99851fdc3fef63aecdfbcffa199c26b9" 7f51876f]:
{{{
#!CommitTicketReference repository=""
revision="7f51876f99851fdc3fef63aecdfbcffa199c26b9"
Fixed #26207 -- Replaced dynamic classes with non-data descriptors for
deferred instance loading.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/26207#comment:3>

Django

unread,
Nov 17, 2016, 10:23:38 AM11/17/16
to django-...@googlegroups.com
#26207: Replace dynamic classes with non-data descriptors for deferred instance
loading
-------------------------------------+-------------------------------------
Reporter: Anssi Kääriäinen | Owner: nobody

Type: | Status: closed
Cleanup/optimization |
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Tim Graham <timograham@…>):

In [changeset:"721f0ca85c68929354b3ea20cdc61cb671652487" 721f0ca]:
{{{
#!CommitTicketReference repository=""
revision="721f0ca85c68929354b3ea20cdc61cb671652487"
Simplified a test after refs #26207.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/26207#comment:4>

Django

unread,
Nov 20, 2016, 6:22:32 PM11/20/16
to django-...@googlegroups.com
#26207: Replace dynamic classes with non-data descriptors for deferred instance
loading
-------------------------------------+-------------------------------------

Reporter: Anssi Kääriäinen | Owner: nobody
Type: | Status: closed
Cleanup/optimization |
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Tim Graham <timograham@…>):

In [changeset:"9d4246419ca5b913a7a9b05f18e695f10a9fd0fb" 9d42464]:
{{{
#!CommitTicketReference repository=""
revision="9d4246419ca5b913a7a9b05f18e695f10a9fd0fb"
Refs #26207 -- Removed obsolete comments about deferred model classes.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/26207#comment:5>

Django

unread,
Oct 14, 2019, 6:51:51 AM10/14/19
to django-...@googlegroups.com
#26207: Replace dynamic classes with non-data descriptors for deferred instance
loading
-------------------------------------+-------------------------------------

Reporter: Anssi Kääriäinen | Owner: nobody
Type: | Status: closed
Cleanup/optimization |
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Mariusz Felisiak <felisiak.mariusz@…>):

In [changeset:"35396a7f243eceec42cc90725ab573a7d9ac3b4c" 35396a7f]:
{{{
#!CommitTicketReference repository=""
revision="35396a7f243eceec42cc90725ab573a7d9ac3b4c"
Refs #26207 -- Removed obsolete note about slow constructing a model with
deferred fields.

This is not true since 7f51876 removed the necessity of creating
proxy model classes at runtime for each deferred field sets.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/26207#comment:6>

Django

unread,
Oct 14, 2019, 6:54:07 AM10/14/19
to django-...@googlegroups.com
#26207: Replace dynamic classes with non-data descriptors for deferred instance
loading
-------------------------------------+-------------------------------------

Reporter: Anssi Kääriäinen | Owner: nobody
Type: | Status: closed
Cleanup/optimization |
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Mariusz Felisiak <felisiak.mariusz@…>):

In [changeset:"8d196e6feaeef38dc7b698c26de5fe2317349fe3" 8d196e6f]:
{{{
#!CommitTicketReference repository=""
revision="8d196e6feaeef38dc7b698c26de5fe2317349fe3"
[3.0.x] Refs #26207 -- Removed obsolete note about slow constructing a
model with deferred fields.

This is not true since 7f51876 removed the necessity of creating
proxy model classes at runtime for each deferred field sets.

Backport of 35396a7f243eceec42cc90725ab573a7d9ac3b4c from master
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/26207#comment:7>

Django

unread,
Oct 14, 2019, 6:54:30 AM10/14/19
to django-...@googlegroups.com
#26207: Replace dynamic classes with non-data descriptors for deferred instance
loading
-------------------------------------+-------------------------------------

Reporter: Anssi Kääriäinen | Owner: nobody
Type: | Status: closed
Cleanup/optimization |
Component: Database layer | Version: master
(models, ORM) |
Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Mariusz Felisiak <felisiak.mariusz@…>):

In [changeset:"f037ae11ec97f90ff94fbff2cdae336619ae63c5" f037ae11]:
{{{
#!CommitTicketReference repository=""
revision="f037ae11ec97f90ff94fbff2cdae336619ae63c5"
[2.2.x] Refs #26207 -- Removed obsolete note about slow constructing a
model with deferred fields.

This is not true since 7f51876 removed the necessity of creating
proxy model classes at runtime for each deferred field sets.
Backport of 35396a7f243eceec42cc90725ab573a7d9ac3b4c from master
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/26207#comment:8>

Reply all
Reply to author
Forward
0 new messages