Files
document-haness/docs/keycloak-session-store/final/assets/session-sharing-path/session-sharing-path.alt.md
T
DongHyeonkaandClaude Opus 5 b2963105a8 docs(keycloak-session-store): import the session-storage lab as a new project
The keycloak project ended with four open questions that design could not
settle. A two-VM lab was built to answer them by measurement, and this is
that material: 26 experiments, 125 raw command outputs, 22 browser captures.

Follows the import procedure in README.md.

  source/     the originating repository verbatim — 78 documents, 28 SVGs,
              8 manifests, plus .source-revision recording the commit
  final/      the SSOT
    document.md   729 lines written from the 29 experiment documents, not
                  concatenated: what was predicted, what was measured, and
                  where the measurement itself was wrong
    evidence/raw    125 outputs, flattened to <experiment>__<file> because
                    the originals collided (01-baseline.txt appeared three
                    times) and the audit only globs the top level
    evidence/meta   one per raw file; command and exitCode are null and the
                    README says why rather than inventing them
    evidence/browser  22 captures
    assets/       three diagrams through techviz
    .techviz/     their VizSpecs

A separate project rather than an addition to keycloak: the B-layer answers
that project's four questions, but the A, C and D layers are about cluster
failure, SSO and operations, and one document.md should hold one subject.
The four question records there can point here through 관계.

Recorded rather than papered over: only three of the 28 diagrams were
remade. The repository forbids hand-drawn SVG and forbids titles inside the
canvas; all 28 originals carry both, so converting them is redrawing, not
reformatting. They stay in source/ and the gap is written into the document.

verify-pipeline.py passes. audit-records.py reports no issues.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-04 22:51:59 +09:00

1.6 KiB
Raw Blame History

세션 공유가 실제로 지나는 경로

Alternative text

keycloak-0 과 keycloak-1 이 각자 캐시를 갖고 PostgreSQL 을 함께 읽는 구성. 두 캐시 사이에는 세션 복제 경로가 없다.

Long description

keycloak-0 과 keycloak-1 은 JGROUPS_PING 테이블을 통해 서로를 발견하고 클러스터 뷰를 형성한다. 그러나 sessions 캐시의 엔트리는 노드 사이로 복제되지 않으며, 각 노드는 자기가 처리한 로그인만 캐시한다. 노드 A 로 로그인한 세션을 노드 B 가 아는 이유는 노드 B 가 PostgreSQL 의 OFFLINE_USER_SESSION 을 직접 읽기 때문이고, 이는 반대편 노드가 날린 SQL 을 문장 로깅으로 잡아 확인했다.

Elements and evidence

  • keycloak-0 (service): 로그인을 처리하고 자기 sessions 캐시에만 엔트리를 남긴다. Evidence: L49L51.
  • PostgreSQL (datastore): OFFLINE_USER_SESSION 에 세션 행을 보관한다. 두 노드가 같은 행을 본다. Evidence: L48L52.
  • keycloak-1 (service): 다른 노드가 만든 세션을 캐시로 받지 않고 데이터베이스에서 읽는다. Evidence: L48L51.
  • JGROUPS_PING (datastore): 노드가 서로를 발견하는 자리. 여기 등록되어 있다는 것과 세션이 복제된다는 것은 다른 사건이다. Evidence: L44L46.

Relationships

  • keycloak-0 → JGROUPS_PING: 멤버 등록. Evidence: L44L45.
  • keycloak-0 → PostgreSQL: 세션 INSERT. Evidence: L49L52.
  • keycloak-1 → JGROUPS_PING: 멤버 등록. Evidence: L44L45.
  • keycloak-1 → PostgreSQL: 세션 SELECT. Evidence: L48L50.