Keycloak commits the login INSERT with synchronous_commit off, so a crash loses whole sessions and not just refresh timestamps. Measured 4 of 153 lost, matching the default wal_writer_delay window. Two injections failed silently first: --grace-period=0 --force lets the container runtime send SIGTERM so PostgreSQL flushes and shuts down cleanly, and SIGKILL to PID 1 from inside its own namespace is ignored by the kernel. Killing a backend makes the postmaster reinitialize, which is a real crash recovery. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
20 lines
941 B
Plaintext
20 lines
941 B
Plaintext
=== 크래시 전후 대조 ===
|
|
클라이언트가 200 과 토큰을 받은 로그인 : 153 건
|
|
그중 DB 에 실제로 존재 : 149 건
|
|
★ 유실 : 4 건
|
|
DB 전체 온라인 세션 : 150 건
|
|
|
|
=== 유실된 sid 목록 ===
|
|
★ CQUfg9HLH29xvhiu6pVlfWOo ← 토큰은 발급됐는데 세션이 없다
|
|
★ 5gLP4fqmpZBbjhH_d-0TPMMr ← 토큰은 발급됐는데 세션이 없다
|
|
★ hkcOv1QskUFmYveMLB6Hljra ← 토큰은 발급됐는데 세션이 없다
|
|
★ p5XybeQIYmAs818gO4Vl_5ea ← 토큰은 발급됐는데 세션이 없다
|
|
|
|
=== 그 토큰이 지금 실제로 쓰이는가 (마지막 sid 로 확인) ===
|
|
마지막 sid: 8do0Bw6tkVLDVxgxotE7GosH
|
|
user_session_id | created_on | last_session_refresh
|
|
--------------------------+------------+----------------------
|
|
8do0Bw6tkVLDVxgxotE7GosH | 1788490958 | 1788490958
|
|
(1 row)
|
|
|