Some help would be appreciated. As I understand it, Moodle has a "session locking" mechanism. We're using Redis on AWS for sessions, EC2 for web servers (behind a load balancer), RDS PostgreSQL, and EFS for moodledata.
We've been dealing with this issue for some years - when a page is slow to load, and hangs for whatever reason (often when we update course modules, and a heap of course recaching/regrading is triggered) - the whole user session gets locked.
The user is unable to open any other page in a new window/tab, and eventually receives timeouts. The only workaround is creating a new session (incognito window or different browser).
Recently, we've added in more AJAX web service calls (maybe 3-4 on some pages), to make the site appear more dynamic, and improve initial page load speeds.
Unfortunately, in the event that an AJAX web service call hangs, the user's session is completely stuffed - there is no way for them to load ANY other page... until the "session lock" is eventually released by that request. The requests hang and eventually timeout - despite the servers being under no stress at all.
This session locking mechanism is both hogging server resources, and creating horrible user experiences.
Does anyone know a way around the session locking? We DO need to access the session (e.g. user ID) but we don't need to update it from our web service calls.