Hello,
I use Umbraco v8.18.3 and I have a process which serves to simply reads contnent (IContent), update it with some data and save and publish. Average number of items to process is around 800 documents.
When I run it on my developer database, which has small amount of overall content inside, my process is very fast (8-11 documents per minute), hovewver when I run it on production DB (a lot of content) the same process is very slow (1 document per minute).
I tested both databases on the same DB server instance to ensure the same circumstances. I can see strong corelation between performance and number of documents stored in DB.
When I added metrics to the code I observed longer execution time on SaveAndPublish method. For small database it took around 0,5 second to complete operation, when for large database, it is around 6-8 seconds. I would like to mention here that I am saving excatly the same document and excatly the same data. The only difference here is the database where the data is stored.
Do you have any ideas why the performance is related to amount of data stored inside db and how to tweak it?
This is a companion discussion topic for the original entry at https://our.umbraco.com/forum/111322-save-and-publish-is-taking-longer-the-more-content-i-have-in-database