3 ms·
so i did a little bit of digging into it and it looks like it does a delete command for each of the items that are selected in the list separately. this is all
by weaksauce 7y ago
so i did a little bit of digging into it and it looks like it does a delete command for each of the items that are selected in the list separately. this is all overly simplified as there are other things going on (selecting the nodes to be deleted as well as notifications to other subsystems.)
That item can be a node(website) that has thousands of visits associated with it so it needs to then delete each of those in multiple batches of delete statements chunked by the db variable limit(~100 or 1000 I think).
Then after that transaction sqlite rebuilds the indexes(17 by my count) on the database with those items missing.
then it does the next chunk and continues on in chunks until there are no more items to delete and then the next item that was selected begins the process again. there might also be a problem with redrawing the history list taking time away from the deletion itself too. it's tough to say exactly what the full bottleneck it but the chunking of the deletes like that looks like a culprit.