Closed jasonfharris closed 11 months ago
Ohh... I should add this occurs if I have defer_js on or off. Ie this behaviour doesn't depend on this setting...
@Klap-in @splitbrain Is this just me or can anyone else reproduce this with a larger site?
I didn’t observe slow behavior, in my own setup.
If you have two same pages with and without the indexmenu you see this difference again? Or if it is in the sidebar, you can create a second namespace with its own sidebar with and without sidebar, and compare?
What is your setup? Which versions of the software PHP, DokuWiki, webserver etc. Local machine or server? Please provide some context, which allows others to replicate the situation.
dokuwiki-hogfather.zip @Klap-in
Ok. Thanks! Good to know that you are not seeing this in your builds.
I think the easiest way to show this is a cut down docker image. It is basically a vanilla hogfather dokuwiki release. (I included the bootstrap3 template in the image but the image defaults to the dokuwiki template and it is evident in both templates.)
I created 18 folders with 12 pages per folder just to give index menu something non-trivial to chew on. I don't see as big of a slow down with this cut down wiki my actual bigger production wiki but it still definitely illustrates the problem.
It is using:
ENV DOKUWIKI_VERSION=2020-07-29
ARG DOKUWIKI_CSUM=8867b6a5d71ecb5203402fe5e8fa18c9
So attached is the zipped up wiki. Just decompress it then execute:
cd dokuwiki-hogfather
./up
and it will launch a docker container at port 8080, then go to localhost:8080
user: test pass: qwerty
Then go to any page in the index, pull up the web console and reload it and observe the timing and hopefully you will see the page load times varying like I do...
@Klap-in Actually just to confirm it wasn't something with the Dockerfile I tried this with a totally different image (the bitnami one) it uses apache instead of lighttp, and does quite a few things differently in set up. It has the same problem with loading times.
The bitnami image is a lot harder to figure out what is going on, and links in a lot of different "performance" things I guess. (The bitnami docker image is some 704Mbs vs 281Mbs for the mprasil/dokuwiki image so has a lot more "gunk" in it.)
(Instructions are the same as above, cd dokuwiki-bitnami
followed by ./up
)
There is also the crazy-max image but I tested upgrading with it and I couldn't get it to work straight off the bat... Also it had some problems in installing extensions, but likely I might have been doing something wrong. Perhaps I should give it another go...
But the point is this is two very different nearly virgin docker images, and they both slow down every other load with indexmenu on, and are both fine when indexmenu is disabled...
I have not reproduced this case (however, I haven't test the dockers). At the moment I'm implementing a new javascript library FancyTree in this plugin. Also the items in the tree will be retrieved via ajax, and then default only the first one or two levels. Probably that could improve the performance.
Please see the progress here: https://github.com/samuelet/indexmenu/issues/230
The recent update contains the new JavaScript tree based on Fancytree.
You can test it now with {{indexmenu>#1| js treenew}}
Closing this as I expect that the ajax loading by the treenew
could improve this quite a bit.
After upgrading to hogfather, I am seeing a large slowdown in page loading times (around 10x slower see below). (This is off a docker instance which is running directly on my machine so there are no website latency issues.)
If I immediately reload the page I often see it is back to its normal fast speed, but reloading it again it will be slow. Maybe like a cache time was set to a single second or couple of seconds? I have all the other plugins turned off except indexmenu. So only Indexmenu is different than a virgin install... (this uses the default template, but also occurs with the bootstrap3 template)
I use
{{indexmenu>#1| js }}