perf(Audit): Audit log pagination is expensive

Aperta
#8,856 2 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
48/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
postgresql, python

Direzione di ricerca

Start by locating the audit log list endpoints and how they apply page-number pagination; inspect the count query and the indexes added for #8846. The issue identifies the expensive per-request count as the problem, but does not specify a replacement pagination approach. Done should reduce the cost of listing audit logs on large projects while preserving the endpoint behavior.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Problem

The audit log list endpoints use page-number pagination, which runs SELECT COUNT(*) on every request to work out the total and the last page. The count reads every audit log row that matches the filters, so its cost grows with the size of the project's audit log, even when the client only asks for the first page.

On large projects, the count can take up to 500 ms. Indexes added for #8846 make this cheaper, but it's still a lot

Lingua principale
Python
Stelle
7.1k
Fork
603
Merge medio
3g 8h
PR unite (30g)
102

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Flagsmith/flagsmith

Tutte le issue di Flagsmith/flagsmith

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.