Editor very slow for editing many rows
Editor very slow for editing many rows
timbcusick
Posts: 21Questions: 6Answers: 0
When editing 500 rows after clicking save button it takes minutes before the post method even gets called, client side. This is 1.8.1. If I change to 1.6.1 the post method gets called almost immediately. Seems to be a bug, but not sure. Apologies, but when I try to run the Datatables debugger it just hangs trying to "Uploading data to the server...."
This discussion has been closed.
Answers
1.8.1 is doing a fair amount more computation to check for differences in values, but I'm really surprised that it would cause such an issue.
Any chance you can give me a link to the page so I can profile it? Send me a PM by clicking my name above and then "Send message" if you don't want to make it public.
Thanks,
Allan
thanks allan. I think I was able to get a debug. Can you see this? If you can get 500 rows of data and edit you should see what I'm seeing.
https://debug.datatables.net/edulub
I've just loaded up one of my tables with 513 rows and used:
To trigger editing on all rows. It takes 335mS for the data to be processed by Editor before submitting it to the server:
You have more columns in your table (17 to my 6), but that wouldn't account for the difference between 335mS and minutes.
I'm afraid I'd need to be able to profile your app to understand where the time is being taken up. You aren't doing any client-side validation or have any hooks on
preSubmit
or similar do you?Allan
allan thanks for digging into this. We do have a little presubmit code, but from debugging it doesn't seem like that's where it's getting hung up. Here is that code. If I remove it, it doesn't seem to make a difference in performance.
I was hoping that debug that I shared would give you a better idea. Unfortunately our site is not private so I can't point you at a URL. It appears that 1.7.1 is where the change occurred. 1.7.0 appeared to work for me.
allan,
I just emailed you a profile of the submit event. I wasn't able to attach the file as it was too large. Hope that helps.
Tim