Why is location plugin using so much CPU?

AI-generated summary

Users ckshen and Richie report high CPU usage on their Discourse servers after updates, with the openvpn user and Ruby unicorns consuming significant resources. ckshen observes 100% CPU utilization and suspects the location plugin and layouts plugin as culprits. After removing both, the issue resolves. Richie confirms the location plugin is the likely cause, as CPU usage returns to normal after disabling it. ckshen notes the problem also disappeared after upgrading to Discourse 2.6.0.beta6. RBoy asks how to monitor CPU and memory usage per plugin, as htop only shows unicorn workers. The discussion suggests the location plugin is a potential cause of high CPU usage, and upgrading or disabling it may resolve the issue.

I rebuilt the container with the latest test-passed from today, and suddenly all the CPU cycles are used up. The site becomes real slow.

The server pretty much only has Discourse running. What’s this openvpn user running the Ruby/ unicorns? Is it the same as the Discourse unicorns?

Assuming this is intended and desired, how can I free up some cpu cycles so the site doesn’t run so slow?

Sidekiq is showing barely anything running in the background. No users are on other than me.

Potentially also an issue here, I upgraded at 09:03 this morning, will monitor during the day:

Our two CPU cores are 100% utilized.

Mine seems to be coming down again now, will continue to monitor.

Removed the layouts plugin and the location plugin and the problem resolved itself for now. Because its really late my time I haven’t had a chance to isolate whether one or both or none are causing the issue, but @angus @merefield giving you a heads up.

Mine has also returned completely back to normal after turning off the locations plugin:

Did you have the issue I’ve mentioned in this topic too @ckshen ?

I didn’t have a chance to check the errors before I took down the plugins. And then today I rebuilt Discourse to 2.6.0.beta6 ( e7bad9f05d ). Problem went away.

A basic question, how does one know which plugin is taking how much CPU and memory? htop only shows the unicorn workers but not much resource each plugin is utilizing.