Reuse authorized read pages without stale presentation or CSRF masks

Transfer the C completed-response cache lesson into Rails, keeping authentication, room checks and cookies per request. A persistent read-only SQLite observer detects local and foreign commits and rejects racing admission. Whole-page misses render fresh to avoid stale nested fragments; message ETags reflect token-neutral presentation.
This commit is contained in:
GPT on behalf of DHH
2026-10-07 20:02:20 +02:00
parent ee5fe3717a
commit ac73267b07
10 changed files with 381 additions and 2 deletions
@@ -1,5 +1,6 @@
class Users::SidebarsController < ApplicationController
DIRECT_PLACEHOLDERS = 20
around_action :cache_read_response, only: :show
def show
visible_memberships = Current.user.memberships.visible