We say Small and medium installs: A minimum of 1024MB (-Xmx1024m).
Note that the Admin Tools apps says: Your cache configuration is too low for a production usage. Your cache is set to 500 documents, it should be 1000 or more.
How do you arrive at that number? Does that include translations? I see 720 pages in a default installation. I suspect (but I’m not sure) that many of them don’t need to be in the document cache to have good performance. For example, there is no reason to have the syntax guide in cache. Same for all color themes. What would be interesting to understand is how the admin tools app arrived at that value of 1000.
This includes translations and many documents that we don’t need to have in the cache all the time, as @MichaelHamann mentioned. I really doubt we need to increase the default document cache size.
I guess we could check the cache hit ratio on xwiki.org, maybe you’ve done that already @tmortagne ? To have some comparison between the # of docs and the doc cache size we’ve used on xwiki.org. That could give some ratio idea.
FWIW is what I get when starting XS and just loading the home page:
I’m surprised to see that 500 pages are already in the cache (and 1480 evictions). For hit ratio, I guess I’d need more navigation to see how it evolves.
I doubt we need that many documents to access the home page, I guess there are other inits that load a lot of documents. Clearing the document cache and loading the home page (without restarting) would probably get a more accurate result for what you are checking.
hmm we do have timed-based evictions or any eviction strategy not based on the cache being full? After navigating a bit in the wiki and coming back to it after 15 minutes, the cache size is now at 164 entries which I find weird (evictions = 1511). I thought it was always supposed to increase until it’s full, no?
The reason is that evictions number is not reset when calling flushcache and there were evictions when the cache got to 500 in prior restarts of my instance (and thus there were evictions). I’ve now reset statistics (through JMX) and I can clearly see that evictions stay to 0, and when calling my page with the flushcache call using http://localhost:8080/xwiki/bin/view/Main/?xpage=xml the doc cache is at 132 entries (still a lot). It moves to 164 when calling http://localhost:8080/xwiki/bin/view/Main/ (which contains the flushcache), and to 188 when calling http://localhost:8080/xwiki/bin/view/Sandbox/.
It moves to 295 entries when I click all the App Panel entries.
So indeed for a standard XS wiki without anything in it, it seems that 500 is enough.
OK, but the eviction number was not really the weird thing for me: from what you described you went from a cache containing 189 entries to one containing “only” 164 without doing anything.