Changes between Version 11 and Version 12 of Ticket #35941


Ignore:
Timestamp:
Dec 2, 2024, 3:53:41 AM (5 weeks ago)
Author:
Csirmaz Bendegúz
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #35941 – Description

    v11 v12  
    44442. ''GenericForeignKey with multiple `object_id`s'' - less flexible, can't store both regular primary keys and composite primary keys. Fastest JOINs.
    4545
    46 There's no reason we couldn't implement other strategies. I believe my proposal provides the most flexibility at the cost of performance. It should be implemented for backwards-compatibility, so systems using a `CharField` ''object_id'' (e.g. [https://github.com/django-guardian/django-guardian/blob/55beb9893310b243cbd6f578f9665c3e7c76bf96/guardian/models/models.py#L39 django-guardian]) can easily integrate with composite primary keys. Other strategies can then be implemented to improve performance (or other reasons).
     46There's no reason we couldn't implement other strategies. I believe my proposal provides the most flexibility at the cost of performance. It should be implemented for backwards-compatibility, so systems using a `CharField` / `TextField` ''object_id'' (e.g. [https://github.com/django-guardian/django-guardian/blob/55beb9893310b243cbd6f578f9665c3e7c76bf96/guardian/models/models.py#L39 django-guardian]) can easily integrate with composite primary keys. Other strategies can then be implemented to improve performance.
    4747
    4848Any feedback is appreciated!
Back to Top