Files
document-haness/docs/clean-architecture-backend-template/tech-log-studio/drift-direction/case/case-documented-uuidv7-generates-v4.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.8 KiB

kind, slug, title, topic, project, status, sourceRevision, rootTreeNode, evidenceCapturedOn, assets, evidence, source
kind slug title topic project status sourceRevision rootTreeNode evidenceCapturedOn assets evidence source
CASE documented-uuidv7-generates-v4 문서가 UUIDv7이라 말하고 생성되는 것은 v4다 drift-direction clean-architecture-backend-template 게시 전 21234e38cdb9a926cbc92bb97a2aee2e4a7d2916 case:documented-uuidv7-generates-v4 2026-09-01
key file
documented-uuidv7-generates-v4 ../../../final/evidence/rendered/documented-uuidv7-generates-v4.svg
../../../final/evidence/raw/documented-uuidv7-generates-v4.txt
원본 분석 절은 final/document.md#7-4 · analysis/07 §5, §6, §7, §8 · analysis/01 §11 이다.

문서가 UUIDv7이라 말하고 생성되는 것은 v4다

식별자 리프의 문서 두 곳이 RFC 9562 UUIDv7 을 명시한다. 실제 생성기는 JDK 의 randomUUID 를 부르고 그것은 v4 다.

관계

  • 과대 진술 문서를 과소보다 먼저 고친다 이 사례가 그 우선순위의 대상이다.
  • 문서와 상수가 서로 일치하는 것으로는 아무것도 증명되지 않는다 같은 계열의 규칙이다.

문제

리프의 문서 두 곳이 같은 주장을 한다.

CLAUDE.md 는 UUID 처리가 JDK 의 java.util.UUID 위에서 RFC 9562 UUIDv7 로 동작한다고 적는다 README.md 는 이 리프가 식별자 생성과 인코딩을 UUIDv7 로 담당한다고 적고, 같은 문장을 한 번 더 반복한다

UUIDv7 은 시간 순서를 갖는 식별자다. 정렬 가능성과 인덱스 지역성이 그 선택의 이유다.

결론

생성기는 v4 를 만든다.

RandomUploadIdentifierFactory 는 두 메서드에서 UUID.randomUUID 를 부른다. 그 메서드는 버전 4 를 만든다. 무작위이고 시간 순서를 갖지 않는다.

같은 클래스의 javadoc 은 randomUUID 가 시드된 SecureRandom 을 쓰므로 공유해도 안전하다고 적는다. 그 서술은 정확하고, 버전에 대해서는 아무 말도 하지 않는다.

드리프트의 방향이 과대 진술이다. 문서를 읽고 시간 순서 식별자를 전제한 설계 — 예를 들어 식별자 순 페이징이나 시간 기반 파티셔닝 — 는 성립하지 않는다.

그리고 이 주장은 두 문서에 각각 적혀 있으므로, 하나를 고쳐도 다른 하나가 남는다.

검증 환경

OpenJDK : 21.0.12 확인 방식 : 문서 문장과 구현 대조 소스 수정 : x

재현 조건

  1. 식별자 리프의 CLAUDE.md 와 README.md 에서 UUIDv7 언급을 찾는다.
  2. 리프의 main 소스에서 UUID 를 생성하는 지점을 찾는다.
  3. 그 호출이 어느 버전을 만드는지 확인한다.

본문

문서는 UUIDv7을 말하고 구현은 v4를 만든다.

문서의 버전과 구현의 버전

:::evidence key="documented-uuidv7-generates-v4" alt="분석 문서 final/document.md 에서 이 기록의 근거 절을 그대로 잘라낸 18줄. 코드베이스를 측정한 것이 아니라 원본 판정이 무엇을 적었는지를 보여 준다." caption="final/document.md 발췌 — 18줄" zoom="true" :::

같은 leaf의 다른 문서 오류들

CLAUDE.md의 의존성 서술 세 항목이 모두 틀렸고, README에 사실 오류가 셋 있으며, CLAUDE.md가 근거로 대는 두 가드 중 하나는 저장소에 없다.

함께 읽어야 할 사실

10 파일짜리 leaf에서 문서 오류가 이만큼 나오는 것은 이 leaf에 production 소비자가 없다는 사실(§7 §3)과 함께 읽어야 한다 — 아무도 쓰지 않으면 문서도 검증되지 않는다.

확인하지 못한 것

생성된 값의 버전 비트를 실제로 읽어 확인하지 않았다. randomUUID 가 v4 를 만든다는 것은 JDK 계약이다.

리프의 다른 식별자 경로가 별도의 v7 생성기를 갖는지 전수 확인하지 않았다. 확인한 것은 업로드 식별자 팩토리다.

없음