You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ever since pagination was implemented into the panel I can no longer open links with large amounts of visits (anywhere from 30-100K visits).
The page will load for a while and then will eventually freeze the tab, and will require a task manager kill to be able to close chrome. I've also tried letting it sit for an extended period of time. After about 5 minutes it would go back to the main shlink control panel screen where you select a server.
Here is an image of console/network activity when trying to load one of these link analytics.
@tivyhosting I have managed to reproduce the issue, and it is due to the fact that every time a change in the UI happens, all the stats are recalculated from the huge dataset (and React was considering a lot of things as "changes in the UI", like just clicking anywhere), which makes the UI freeze until it finishes.
I have found a solution which consists on memoizing the result of that calculation based on the filtering arguments (short code and dates).
I also plan to make the stats from all graphics to be calculated in just one iteration (it is now performing one iteration each).
It still takes quite some time to load the entire dataset (about 2min for 100k results, but I suppose this value tightly depends on the server performance and network latency).
One way to improve this could be parallelizing requests. Maybe in blocks of 4 (browsers never do more than 6 requests at a time).
I'll let you know how it goes once I have applied all the improvements.
Originally reported in shlinkio/shlink#349
The text was updated successfully, but these errors were encountered: