Files
document-haness/docs/clean-architecture-backend-template/tech-log-studio/transaction-and-consistency-models/concept/concept-adapter-outbound-cache-redis-c13.md
T
DongHyeonkaandClaude Fable 5.1 b25357c48a docs(clean-architecture-backend-template): fold analysis into final and re-select one topic
- analysis/·source-index·state.json 을 final/document.md 제2부·제3부로 접었다. SSOT 는 하나다
- 파일럿 — commit-ambiguity-as-a-result 를 새 기준으로 재선별. 후보 14 → 글감 5
  (PROMOTE 5 · MERGE_INTO 3 · KEEP_IN_SSOT 4 · 보류 2). 기록 5건을 다시 썼고 그림 1개를
  techviz 로 만들었다
- 재선별이 잡은 것: 제1부 §6.2·§11.1 이 자기 §13.2 와 어긋나 있었다(레인을 안 돌렸다 vs
  돌렸다) — 정정. 이미 답이 나와 있던 Question 을 HEAD 재실행 질문으로 다시 세웠다.
  Concept 이 인용한 코드가 SSOT 에 없어 뺐다
- candidateScope·sourceRepository 기록. 나머지 43개 주제는 재선별 대기(PENDING 905)

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-07 12:39:20 +09:00

3.2 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 adapter-outbound-cache-redis-c13 등록되지 않은 스크립트는 서버에 닿을 방법이 없다 transaction-and-consistency-models clean-architecture-backend-template 게시 전 21234e38cdb9a926cbc92bb97a2aee2e4a7d2916 concept:adapter-outbound-cache-redis-c13 2026-09-01
key file
adapter-outbound-cache-redis-c13 ../../../final/evidence/rendered/adapter-outbound-cache-redis-c13.svg
key file
adapter-outbound-cache-redis-c13-diagram ../../../final/assets/diagrams/adapter-outbound-cache-redis-c13.svg
../../../final/evidence/raw/adapter-outbound-cache-redis-c13.txt
원본 분석 절은 final/document.md#a10#L701 이다.
adapter-outbound-cache-redis

등록되지 않은 스크립트는 서버에 닿을 방법이 없다

RedisScriptRegistry가 등록을 배포 단계로 두고, 트랜잭션 창은 감시 키에서 정한 노드에 고정된다.

본문

RedisScriptRegistry의 규칙 — "Registration is a deployment step, not a request-time one. A script that was never registered has no digest and therefore no way to reach the server, which is what makes 'only reviewed scripts run' a structural property rather than a convention." 같은 identity에 다른 body를 등록하면 거부하고, 실행 시점에도 body가 등록본과 같은지 다시 본다.

등록과 실행의 분리

:::evidence key="adapter-outbound-cache-redis-c13-diagram" alt="배포 시 스크립트 등록과 digest 대조와 EVALSHA 실행이 왼쪽에서 오른쪽으로 이어지는 구조" caption="등록과 실행의 분리" zoom="false" :::

README가 주장하는 복구 사슬 EVALSHA → NOSCRIPT → SCRIPT LOAD → digest verify → EVALSHA실재한다LettuceRedisScriptOperations:26 javadoc이 "NOSCRIPT is the one failure retried automatically"라고 적고, :129-133RedisNoScriptException 또는 메시지 접두 NOSCRIPT를 잡아 :100에서 registry.forget(script.id())를 호출한다. 다음 호출이 digest(...)에서 다시 SCRIPT LOAD한다.

RedisScriptRegistry 참조 위치

:::evidence key="adapter-outbound-cache-redis-c13" alt="코드베이스에서 RedisScriptRegistry 를 검색한 출력 7줄. 이 기록이 세는 참조가 그 출력에 그대로 보인다." caption="RedisScriptRegistry 코드베이스 검색 — 7줄 · exit 0" zoom="true" :::

Cluster에서 MULTI 창을 노드에 고정하는 방법

RedisTransactionRunner는 Cluster에서의 MULTI 문제를 정면으로 다룬다. javadoc이 문제와 해법을 적는다 — 다른 레인은 명령마다 슬롯 소유 노드로 라우팅하는데 "that is exactly what a MULTI window must not do: the queued commands would be spread across nodes and none of them would be part of the same window." 해법은 연결이 아니라 라우팅 결정이었다 — 감시 키(또는 명시적 슬롯 태그)에서 노드를 정해 레인을 고정한다.

감시 키가 없는 Cluster 트랜잭션을 거부하는 이유

"the keys the callback will queue are not known until the callback runs, which is after the window is open."