Changes between Initial Version and Version 1 of Ticket #37287


Ignore:
Timestamp:
Aug 19, 2026, 6:29:41 AM (26 hours ago)
Author:
Ali Rafiei
Comment:

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #37287 – Description

    initial v1  
    55SELECT ... FROM "django_admin_log" ORDER BY "django_admin_log"."action_time" DESC LIMIT 10;
    66
    7 Because LogEntry explicitly defines ordering = ['-action_time'] in its Meta options but lacks any indexing on the action_time field, database engines must perform a highly inefficient sequential table scan to retrieve these 10 rows. This causes severe CPU spikes and long page-load delays on large datasets, as highlighted in recent community discussions (e.g., Django Forum thread #41943). 
     7Because LogEntry explicitly defines ordering = ['-action_time'] in its Meta options but lacks any indexing on the action_time field, database engines must perform a highly inefficient sequential table scan to retrieve these 10 rows. This causes severe CPU spikes and long page-load delays on large datasets, as highlighted in recent community discussions (e.g., Django Forum thread https://forum.djangoproject.com/t/strange-behaviour-for-django-5-0-long-loading-times-and-high-postgres-cpu-load-only-admin/41943). 
    88
    99Historical Context & Precedent
Back to Top