I have been experiencing intermittent CPU spikes and outages using XWiki 10.x series. I believe this behavior started at version 10 but I cannot be 100% certain.
The setup is one AWS t2.medium instance (2 vCPUs, 4GiB RAM). This instance runs nginx (reverse proxy), xwiki, and mysql. I am using the packages provided for Ubuntu. Currently on version 10.7.
Overall this setup is slow. During normal operation, java will be using a minimal amount of CPU and responses return in a few seconds. The regressive behavior is java CPU usage spikes up to 177%+, and seemingly never comes down. nginx starts reporting 504 gateway timed out errors. Running “systemctl restart tomcat8” will get things running again, but the issue can re-appear at any time thereafter. Constantly restarting tomcat8 is not ideal since it takes so long for xwiki to get started again (it seemingly waits for a first http connection and then spends a lot of time caching stuff to memory? Is my guess of what is happening there?)
The functionality of XWiki is terrific but operationally it is a bit of a nightmare. I do not know where I am supposed to be looking when things go wrong. Is there a recommended configuration I can try? A certain vm size or deployment model I can follow? I was using a t2.small (1 vCPU), upgrading to t2.medium helped tremendously at first. However, within a few weeks the site overall felt slower and the hanging CPU issue reasserted itself again. As you can probably tell, we are trying to keep costs down but it is important that the system run consistently.
edit: to be clear, the usage of the wiki is extremely low. We have just over 20 users, many of whom are not very technical. Only about 5 real content producers, who might add content once every couple weeks. Most of the time, this system is idling. It is just as soon as you try to use it, you are almost guaranteed to hit problems fairly quickly, or return to the site to find it not responding.
Any help would be very welcome. Thanks.