Files
document-haness/docs/clean-architecture-backend-template/tech-log-studio/state-machines-and-ownership/concept/concept-messaging-admin-runtime-c03.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

3.4 KiB

kind, slug, title, topic, project, status, sourceRevision, rootTreeNode, evidenceCapturedOn, assets, evidence, source, module
kind slug title topic project status sourceRevision rootTreeNode evidenceCapturedOn assets evidence source module
CONCEPT messaging-admin-runtime-c03 리드라이브는 재개하고 리플레이는 처음부터 다시 읽는다 state-machines-and-ownership clean-architecture-backend-template 게시 전 21234e38cdb9a926cbc92bb97a2aee2e4a7d2916 concept:messaging-admin-runtime-c03 2026-09-01
key file
messaging-admin-runtime-c03 ../../../final/evidence/rendered/messaging-admin-runtime-c03.svg
key file
messaging-admin-runtime-c03-diagram ../../../final/assets/diagrams/messaging-admin-runtime-c03.svg
../../../final/evidence/raw/messaging-admin-runtime-c03.txt
원본 분석 절은 analysis/messaging/messaging-admin-runtime.md#L163 이다.
messaging-admin-runtime

리드라이브는 재개하고 리플레이는 처음부터 다시 읽는다

리드라이브는 lease.resumeFrom()과 체크포인트 콜백을 실행 측에 넘기지만 리플레이는 넘기지 않는다. ReplayService.replay(...) 시그니처에 resumeFrom이 없다.

본문

검사 순서가 요점이다. 승인이 아직 창 안인지, 계획 승인 이후 토폴로지가 바뀌지 않았는지, 승인이 이미 실행되지 않았는지를 순서대로 보고 그다음에야 무엇이 움직인다. 저널 항목은 작업 전에 쓴다 — 나중에 쓰면 첫 실행이 도는 중에 두 번째 실행이 시작되는 창이 생기고, 그것이 저널이 막으려는 이중 리드라이브다.

재개가 붙는 쪽과 붙지 않는 쪽

:::evidence key="messaging-admin-runtime-c03-diagram" alt="실행 경계 안에 리드라이브가 들어 있고 리플레이가 경계 밖 빗금 상자로 놓인 구조" caption="재개가 붙는 쪽과 붙지 않는 쪽" zoom="false" :::

리플레이와 리드라이브의 비대칭이 하나 있다. 리드라이브는 lease.resumeFrom() 과 체크포인트 콜백을 실행 측에 넘기지만, 리플레이는 넘기지 않는다. ReplayService.replay(...) 시그니처에 resumeFrom 이 없다(ReplayService.java:53-54). 즉 리플레이는 리스를 받지만 재개하지 않는다 — 죽으면 처음부터 다시 읽는다. 클래스 javadoc 의 "a retry continues the same operation instead of either redoing it" 은 리드라이브에만 해당한다.

DestructiveOperationGuard 참조 위치

:::evidence key="messaging-admin-runtime-c03" alt="코드베이스에서 DestructiveOperationGuard 를 검색한 출력 19줄. 이 기록이 세는 참조가 그 출력에 그대로 보인다." caption="DestructiveOperationGuard 코드베이스 검색 — 19줄 · exit 0" zoom="true" :::

격리 리플레이가 dry run인 척으로 통과한다

DestructiveOperationGuard.authorizedryRun 이 참이면 즉시 반환한다(DestructiveOperationGuard.java:54-56). 즉 격리 리플레이는 "승인 불필요" 가 아니라 "dry run 인 척" 으로 통과한다. 감사 이벤트는 그 구분을 남긴다 — approval.map(VerifiedApproval::ticket).orElse("isolated")(:77) — 그러나 guard 쪽에는 남지 않는다. §17 P3.

세 수정 중 세 번째의 인덱스 계산

세 가지 실패를 고쳤다고 javadoc 이 적고, 세 수정이 코드에 있다. 발행 → 확인 → 정산 순서가 이 리프의 핵심 불변식이다. 세 번째 수정 — 재개 — 는 인덱스 계산이 틀렸다. §12.1(a)에서 상술한다.