Opened 2 years ago

Closed 2 years ago

Last modified 18 months ago

#26207 closed Cleanup/optimization (fixed)

Replace dynamic classes with non-data descriptors for deferred instance loading

Reported by: Anssi Kääriäinen Owned by: nobody
Component: Database layer (models, ORM) Version: master
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

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!

Change History (5)

comment:1 Changed 2 years ago by Tim Graham

Has patch: set
Patch needs improvement: set
Summary: New implementation for deferred instance loadingReplace dynamic classes with non-data descriptors for deferred instance loading
Triage Stage: UnreviewedAccepted

comment:2 Changed 2 years ago by Tim Graham

Patch needs improvement: unset

Updated PR with cosmetic edits + docs. One TODO remains from Anssi's original PR that I'm not sure how to handle.

comment:3 Changed 2 years ago by Tim Graham <timograham@…>

Resolution: fixed
Status: newclosed

In 7f51876f:

Fixed #26207 -- Replaced dynamic classes with non-data descriptors for deferred instance loading.

comment:4 Changed 18 months ago by Tim Graham <timograham@…>

In 721f0ca:

Simplified a test after refs #26207.

comment:5 Changed 18 months ago by Tim Graham <timograham@…>

In 9d42464:

Refs #26207 -- Removed obsolete comments about deferred model classes.

Note: See TracTickets for help on using tickets.
Back to Top