Redesign the database the right way
Add index fields on all foreign keys (jid_id
) as it does not slow logging down but instead speeds opening new chat windows A LOT. Currently I have to wait 10 seconds each time I open a new chat window as if there are no indexes, SQLite has to read all the rows to select data (and that means parsing a whole 5MB file).
Tested it here and adding indexes greatly improves that.