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>
This commit is contained in:
DongHyeonka
2026-09-04 22:51:59 +09:00
co-authored by Claude Opus 5
parent 43bccd08a8
commit b2963105a8
5017 changed files with 372751 additions and 4943 deletions
@@ -0,0 +1,140 @@
<svg xmlns="http://www.w3.org/2000/svg" width="1200" height="1624" viewBox="0 0 1200 1624" role="img">
<title>terminal evidence</title>
<desc>Terminal-style rendering generated from retained command output. Sensitive-looking values are redacted in the visual asset.</desc>
<rect x="1" y="1" width="1198" height="1622" rx="14" fill="#0d1117" stroke="#30363d"/>
<rect x="1" y="1" width="1198" height="44" rx="14" fill="#161b22"/>
<rect x="1" y="30" width="1198" height="14" fill="#161b22"/>
<circle cx="24" cy="22" r="6" fill="#ff5f57"/>
<circle cx="44" cy="22" r="6" fill="#febc2e"/>
<circle cx="64" cy="22" r="6" fill="#28c840"/>
<text x="92" y="27" fill="#8b949e" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace">terminal evidence</text>
<text x="24" y="68" fill="#c9d1d9" font-size="15" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">$ set -e
D=$(mktemp -d)
trap &#x27;rm -rf &quot;$D&quot;&#x27; EXIT
CP=src/adapter/outbound/identifier/build/classes/java/main
SRC=src/adap</tspan><tspan x="24" dy="22">ter/outbound/identifier/src/main/java/dev/caskeleton/adapter/outbound/identifier/UuidCodec.java
echo &quot;# 클래스 산출물이 </tspan><tspan x="24" dy="22">소스보다 새로운가 : $([ &quot;$CP/dev/caskeleton/adapter/outbound/identifier/UuidCodec.class&quot; -nt &quot;$SRC&quot; ] &amp;&amp; echo yes || ech</tspan><tspan x="24" dy="22">o no)&quot;
cat &gt; &quot;$D/NormalizeProbe.java&quot; &lt;&lt;&#x27;JAVA&#x27;
import dev.caskeleton.adapter.outbound.identifier.UuidCodec;
import java</tspan><tspan x="24" dy="22">.util.LinkedHashMap;
import java.util.List;
import java.util.Map;
public final class NormalizeProbe {
private static</tspan><tspan x="24" dy="22"> final String CANONICAL = &quot;0190bd6e-7c3e-7abc-8def-0123456789ab&quot;;
public static void main(String[] args) {
System</tspan><tspan x="24" dy="22">.out.println(&quot;java.version = &quot; + System.getProperty(&quot;java.version&quot;));
System.out.println();
System.out.println(</tspan><tspan x="24" dy="22">&quot;[계약이 말하는 두 갈래]&quot;);
show(CANONICAL);
show(&quot;0190BD6E-7C3E-7ABC-8DEF-0123456789AB&quot;);
show(&quot;not-a-uuid&quot;</tspan><tspan x="24" dy="22">);
show(&quot;0190bd6e7c3e7abc8def0123456789ab&quot;);
System.out.println();
System.out.println(&quot;[정규형에서 한 글자</tspan><tspan x="24" dy="22">를 지운다]&quot;);
for (String input : List.of(
&quot;0190bd6e-7c3e-7abc-8def-123456789ab&quot;,
&quot;0190bd6e-7c3e-7ab</tspan><tspan x="24" dy="22">c-8def-0123456789a&quot;,
&quot;0190bd6e-7c3e-7abc-8def-012345678ab&quot;,
&quot;0190bd6e7c3e-7abc-8def-0123456789ab&quot;)) {
</tspan><tspan x="24" dy="22"> show(input);
System.out.println(&quot; 원본과 같은가 : &quot; + CANONICAL.equals(safe(input)));
}
System.ou</tspan><tspan x="24" dy="22">t.println();
System.out.println(&quot;[길이가 36이어도 대시 위치가 다르면 같은 경로로 떨어진다]&quot;);
show(&quot;0000001-000</tspan><tspan x="24" dy="22">01-0001-0001-000000000001&quot;);
System.out.println();
System.out.println(&quot;[그룹이 규정 자릿수를 넘으면 상위 비트를</tspan><tspan x="24" dy="22"> 버린다]&quot;);
show(&quot;100000001-1-1-1-1&quot;);
show(&quot;1-1-1-1-1000000000001&quot;);
System.out.println();
System.out.</tspan><tspan x="24" dy="22">println(&quot;[십육진이 아닌 것도 통과한다]&quot;);
show(&quot;+1-1-1-1-1&quot;);
show(&quot;١-1-1-1-1&quot;);
System.out.println();
</tspan><tspan x="24" dy="22">System.out.println(&quot;[서로 다른 입력이 같은 식별자가 된다]&quot;);
Map&lt;String, String&gt; byOutput = new LinkedHashMap&lt;&gt;();
</tspan><tspan x="24" dy="22"> for (String input : List.of(&quot;1-1-1-1-1&quot;, &quot;01-01-01-01-01&quot;, &quot;+1-1-1-1-1&quot;,
&quot;00000001-0001-0001-0001-00000000000</tspan><tspan x="24" dy="22">1&quot;, &quot;1-1-1-1-2&quot;)) {
byOutput.merge(safe(input), &quot;\&quot;&quot; + input + &quot;\&quot;&quot;, (a, b) -&gt; a + &quot;, &quot; + b);
}
byOutput.f</tspan><tspan x="24" dy="22">orEach((output, inputs) -&gt; System.out.println(&quot; &quot; + output + &quot; &lt;- &quot; + inputs));
System.out.println();
System.</tspan><tspan x="24" dy="22">out.println(&quot;[같은 파서를 쓰는 형제 메서드]&quot;);
System.out.println(&quot; toUuid(\&quot;1-1-1-1-1\&quot;) = &quot; + UuidCodec.toUuid(&quot;1</tspan><tspan x="24" dy="22">-1-1-1-1&quot;));
}
private static String safe(String input) {
try {
return UuidCodec.normalize(input);
} </tspan><tspan x="24" dy="22">catch (RuntimeException rejected) {
return rejected.getClass().getSimpleName();
}
}
private static void s</tspan><tspan x="24" dy="22">how(String input) {
String pad = &quot; &quot;.repeat(Math.max(1, 40 - input.length()));
try {
System.out.println(&quot; </tspan><tspan x="24" dy="22"> normalize(\&quot;&quot; + input + &quot;\&quot;)&quot; + pad
+ &quot;-&gt; \&quot;&quot; + UuidCodec.normalize(input) + &quot;\&quot;&quot;);
} catch (RuntimeExcep</tspan><tspan x="24" dy="22">tion rejected) {
System.out.println(&quot; normalize(\&quot;&quot; + input + &quot;\&quot;)&quot; + pad
+ &quot;-&gt; &quot; + rejected.getClass()</tspan><tspan x="24" dy="22">.getSimpleName() + &quot;: &quot; + rejected.getMessage());
}
}
}
JAVA
javac -encoding UTF-8 -cp &quot;$CP&quot; -d &quot;$D&quot; &quot;$D/Normaliz</tspan><tspan x="24" dy="22">eProbe.java&quot;
java -Dstdout.encoding=UTF-8 -cp &quot;$D:$CP&quot; NormalizeProbe</tspan></text>
<text x="24" y="684" fill="#8b949e" font-size="13" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">cwd: /shared/codebase/clean-architecture-backend-template</tspan></text>
<text x="24" y="706" fill="#8b949e" font-size="13" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">time: 2026-09-02T09:21:32+00:00 · exit 0</tspan></text>
<line x1="24" y1="720" x2="1176" y2="720" stroke="#30363d"/>
<text x="24" y="760" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"># 클래스 산출물이 소스보다 새로운가 : yes</tspan></text>
<text x="24" y="782" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">java.version = 21.0.12</tspan></text>
<text x="24" y="804" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"></tspan></text>
<text x="24" y="826" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">[계약이 말하는 두 갈래]</tspan></text>
<text x="24" y="848" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;0190bd6e-7c3e-7abc-8def-0123456789ab&quot;) -&gt; &quot;0190bd6e-7c3e-7abc-8def-0123456789ab&quot;</tspan></text>
<text x="24" y="870" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;0190BD6E-7C3E-7ABC-8DEF-0123456789AB&quot;) -&gt; &quot;0190bd6e-7c3e-7abc-8def-0123456789ab&quot;</tspan></text>
<text x="24" y="892" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;not-a-uuid&quot;) -&gt; IllegalArgumentException: Invalid UUID string: not-a-uuid</tspan></text>
<text x="24" y="914" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;0190bd6e7c3e7abc8def0123456789ab&quot;) -&gt; IllegalArgumentException: Invalid UUID string: 0190bd6e7c3e7abc8def012</tspan><tspan x="24" dy="22">3456789ab</tspan></text>
<text x="24" y="958" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"></tspan></text>
<text x="24" y="980" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">[정규형에서 한 글자를 지운다]</tspan></text>
<text x="24" y="1002" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;0190bd6e-7c3e-7abc-8def-123456789ab&quot;) -&gt; &quot;0190bd6e-7c3e-7abc-8def-0123456789ab&quot;</tspan></text>
<text x="24" y="1024" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 원본과 같은가 : true</tspan></text>
<text x="24" y="1046" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;0190bd6e-7c3e-7abc-8def-0123456789a&quot;) -&gt; &quot;0190bd6e-7c3e-7abc-8def-00123456789a&quot;</tspan></text>
<text x="24" y="1068" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 원본과 같은가 : false</tspan></text>
<text x="24" y="1090" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;0190bd6e-7c3e-7abc-8def-012345678ab&quot;) -&gt; &quot;0190bd6e-7c3e-7abc-8def-0012345678ab&quot;</tspan></text>
<text x="24" y="1112" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 원본과 같은가 : false</tspan></text>
<text x="24" y="1134" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;0190bd6e7c3e-7abc-8def-0123456789ab&quot;) -&gt; IllegalArgumentException: Invalid UUID string: 0190bd6e7c3e-7abc-8def-</tspan><tspan x="24" dy="22">0123456789ab</tspan></text>
<text x="24" y="1178" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 원본과 같은가 : false</tspan></text>
<text x="24" y="1200" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"></tspan></text>
<text x="24" y="1222" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">[길이가 36이어도 대시 위치가 다르면 같은 경로로 떨어진다]</tspan></text>
<text x="24" y="1244" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;0000001-00001-0001-0001-000000000001&quot;) -&gt; &quot;00000001-0001-0001-0001-000000000001&quot;</tspan></text>
<text x="24" y="1266" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"></tspan></text>
<text x="24" y="1288" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">[그룹이 규정 자릿수를 넘으면 상위 비트를 버린다]</tspan></text>
<text x="24" y="1310" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;100000001-1-1-1-1&quot;) -&gt; &quot;00000001-0001-0001-0001-000000000001&quot;</tspan></text>
<text x="24" y="1332" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;1-1-1-1-1000000000001&quot;) -&gt; &quot;00000001-0001-0001-0001-000000000001&quot;</tspan></text>
<text x="24" y="1354" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"></tspan></text>
<text x="24" y="1376" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">[십육진이 아닌 것도 통과한다]</tspan></text>
<text x="24" y="1398" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;+1-1-1-1-1&quot;) -&gt; &quot;00000001-0001-0001-0001-000000000001&quot;</tspan></text>
<text x="24" y="1420" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> normalize(&quot;١-1-1-1-1&quot;) -&gt; &quot;00000001-0001-0001-0001-000000000001&quot;</tspan></text>
<text x="24" y="1442" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"></tspan></text>
<text x="24" y="1464" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">[서로 다른 입력이 같은 식별자가 된다]</tspan></text>
<text x="24" y="1486" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 00000001-0001-0001-0001-000000000001 &lt;- &quot;1-1-1-1-1&quot;, &quot;01-01-01-01-01&quot;, &quot;+1-1-1-1-1&quot;, &quot;00000001-0001-0001-0001-000000000001&quot;</tspan></text>
<text x="24" y="1508" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 00000001-0001-0001-0001-000000000002 &lt;- &quot;1-1-1-1-2&quot;</tspan></text>
<text x="24" y="1530" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"></tspan></text>
<text x="24" y="1552" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">[같은 파서를 쓰는 형제 메서드]</tspan></text>
<text x="24" y="1574" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> toUuid(&quot;1-1-1-1-1&quot;) = 00000001-0001-0001-0001-000000000001</tspan></text>
</svg>

After

Width:  |  Height:  |  Size: 15 KiB