Page 2 of 3

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 3:49 pm
by mcrossley
Changing the range only redraws the graph, it does not download any new data. A bit of a mystery this one!

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 3:58 pm
by Mapantz
I don't know if you've changed anything since your first post, but your graphs load instantly for me - all of them.

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 4:13 pm
by stevendt
Hi, thanks for the input

No, not changed anything. Are you selecting Wind Direction, then changing the time base from All to 12h? - And it's working fine?

regards
Dave

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 4:24 pm
by PaulMy
No, not changed anything. Are you selecting Wind Direction, then changing the time base from All to 12h? - And it's working fine?
I can confirm the slow load behaviour. Selecting the various elements from the bottom selection is pretty much instant, and the same for selecting from the top All, 12h and 6hr except for WindDir which at first I thought froze the page but in actuality can take a few minutes the first try and then less than a minute on subsequent selection between 6h, 12h or All, but still a long time.

Enjoy,
Paul

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 4:27 pm
by stevendt
Hi Paul,

thanks a lot for the confirmation - I'm glad that the issue can be duplicated on other computers.

But, as Mark says . ."A bit of a mystery this one!"

:( :?

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 4:57 pm
by HansR
Yes, that specific graph (Wind Direction) is also slow here.
I made a performance analysis and it shows as follows:
Aantekening 2020-06-21 185215.png
Maybe somebody more familiar with the inner workings of Highcharts can bake something of this.

This almost 8 seconds on a total of creating the graph of 10 seconds (don't count the idle :) )
Did you try upgrading some Highcharts libraries? Maybe some version mismatch?

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 5:01 pm
by HansR
And this is a second try, now with the flamechart. Displaying the calls again to show where the time consumption is.
Aantekening 2020-06-21 190020.png

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 5:07 pm
by HansR
And I can add, that on my own site, with the wind direction it is also not performing very well.
So I assume there is something wrong in that graph
Indeed.

Btw, I rarely use that range selector.

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 5:20 pm
by stevendt
Hi Hans,

thanks for the info.

I only noticed this behaviour after I had upgraded from b3079 to b3084 by copying the changed files for all intermediate and latest release.

I have checked, and as far as I can see, I have copied all of the necessary files to my local and remote directories. Of course, the problem may have existed previously, but it seems that something changed? Although, I probably don't use the range selector on Wind Direction very much - I was checking something in particular from last night, so perhaps the issue was always there. (b3079 was my first install)

Mark did say that the Wind Dir graph does some extra processing, but having fetched the data, it's odd that asking for a redraw causes such a big delay

regards
Dave

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 5:23 pm
by Mapantz
Have you tried adding boost.js?

Code: Select all

<script src="https://code.highcharts.com/modules/boost.js"></script>

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 5:24 pm
by stevendt
Mapantz wrote: Sun 21 Jun 2020 5:23 pm Have you tried adding boost.js?

Code: Select all

<script src="https://code.highcharts.com/modules/boost.js"></script>
Since I have no idea what that means, then, no, I haven't :D

regards
Dave

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 5:26 pm
by Mapantz
Add that line underneath your highstock.js in trends.htm and then try a ctrl + F5 refresh.

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 5:37 pm
by stevendt
Hi,

thanks - I'm guessing that I should put it in trendsT.htm?

The latest CumulusMX build trends includes :

Code: Select all

		<script src="https://code.highcharts.com/stock/8.0/highstock.js"></script>
		<script src="https://code.highcharts.com/8.0/themes/grid.js"></script>
		<script src="js/cumuluscharts.js"></script>
does the boost.js need to point somewhere similar? (8.0?)

regards
Dave

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 5:40 pm
by Mapantz
Just use the exact link I posted

Code: Select all

		<script src="https://code.highcharts.com/stock/8.0/highstock.js"></script>
                <script src="https://code.highcharts.com/modules/boost.js"></script>
		<script src="https://code.highcharts.com/8.0/themes/grid.js"></script>
		<script src="js/cumuluscharts.js"></script>
Not saying it will work, but it does speed up the rendering of my wind direction charts.

Re: Long running trend scripts - b3084

Posted: Sun 21 Jun 2020 6:16 pm
by Weerhaas
WindDir uses scatter instead of line or spline. The only graph , that gives some delay.