On a large Orthanc instance, we recently noticed that our DelayedDeletion (DD) plugin’s speed of deletion decreased dramatically to about 1 deletion/second.
The DD’s “Pending” table grew to almost 7M rows during the past few days.
After some examination of the plugin’s code (select and delete queries issued on every deletion), we put a unique index on the Pending.uuid column (after stopping Orthanc of course) and our deletion speed was increased about 100x.
With the index, our DB grow from ~300Mb to ~600Mb, so the cost in disk space is negligible.
May I suggest that we add a unique index to the uuid (how ironic) column in future versions by default?
Thanks for all the great work you do!