Files
kevinveenbirkenbachandClaude Opus 5.5 9fab251ffc fix(web-app-moodle): keep sessions in the database so swarm replicas share them
Under swarm, three Moodle PHP replicas served one site from a shared NFS moodledata, and Moodle's default file session handler kept every session under $CFG->dataroot/sessions. CI run 44532889020 (PR 2243, Moodle#0 swarm) logged 'session_start(): Failed to decode session object. Session has been destroyed' nine times across the replicas, each one to two seconds before a failed spec attempt: the browser lost its session, the file picker's repository_ajax call answered requireloginerror and course navigation was sent to the login page (ERR_ABORTED). config.php now selects Moodle's core database session handler, so every replica reads the same session row from the shared MariaDB. Switching handlers signs every user out once.

ConfigTest.php runs config.php against a stub setup.php and asserts the handler class; without the line the suite fails exactly that test (negative control). The new test is the mirrored unit test of config.php, so its nocheck: mirrored-unit-test exemption goes.

🎯 Fix: 88 %
💥 Break: 4 %
💸 Tokens: –
⏱️ Velocity: –
🛡️ Security: 100 %
🏆 Score: 84
🚦 Gate: ⛔ fix 88 % < 90

Created-with: https://s.veen.world/skills
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-20 19:04:09 +00:00
..