Add full text search
Just a small experiment: Does a full text search on answers ("text"), comments ("text"), exams ("text" + "remark") and exam pages ("text"). Pdf text is extracted using pdftotext (Uses the poppler pdf parser). To speed up the search the SearchVector is stored and updated when one of the attributes is updated using a TRIGGER
. I also added a GIN index for the search_vector columns. A trigram ranking function is used on exam pages.
Searching on 15333 answers takes ~10 ms and ~80 ms with django + python overhead (without GIN and stored tsvector it takes ~1500 ms)
Edited by Lukas Möller