pg_gather icon indicating copy to clipboard operation
pg_gather copied to clipboard

Multiple times of page rendering causing CPU spikes in browser.

Open jobinau opened this issue 2 years ago • 2 comments

When the Report is loaded, First HTML DOM with CSS is displayed as it is. The analysis data comes later on top of that. Currently, jquery is used to manipulate the DOM by using CSS for highlighting and Mouseover hints (element.title) are directly inserted into the DOM elements. All these dynamic changes result in Rendering the HTML page multiple times in the browser, causing CPU usage spikes and sometimes delays. This problem is more visible when the report is big in size.

jobinau avatar Aug 21 '22 08:08 jobinau

One feasible solution is to hold the rendering until the DOM is fully ready with all modifications to highlight the analysis. Wait for all jquery action on the elements.

jobinau avatar Aug 21 '22 08:08 jobinau

The delayed rendering patches are pushed to dev templates commit : 5cca672105ba1b015c79c064e9f32888b2e7c386 Currently under testing. Showing considerable performance gains and much less CPU utilization. Planning to merge with the main script in a week

jobinau avatar Aug 31 '22 06:08 jobinau