Files
document-haness/docs/clean-architecture-backend-template/final/evidence/rendered/a11-f002-pool-route-exceeds-total-shape.svg
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

134 lines
12 KiB
XML

<svg xmlns="http://www.w3.org/2000/svg" width="1200" height="1404" viewBox="0 0 1200 1404" 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="1402" 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
H=/shared/codebase/clean-architecture-backend-template/src/adapter/outb</tspan><tspan x="24" dy="22">ound/httpclient
JAR=$H/build/libs/httpclient-0.0.1+21234e38cdb9.jar
java -version 2&gt;&amp;1 | head -1
javac -encoding UTF-8 -</tspan><tspan x="24" dy="22">cp &quot;$JAR&quot; -d &quot;$D&quot; \
&quot;$H/src/testkit/java/dev/caskeleton/adapter/outbound/httpclient/testkit/ClientProfiles.java&quot;
cat &gt;</tspan><tspan x="24" dy="22"> &quot;$D/PoolViolationProbe.java&quot; &lt;&lt;&#x27;JAVA&#x27;
import dev.caskeleton.adapter.outbound.httpclient.profile.ClientProfile;
import d</tspan><tspan x="24" dy="22">ev.caskeleton.adapter.outbound.httpclient.profile.ClientProfileValidator;
import dev.caskeleton.adapter.outbound.httpcli</tspan><tspan x="24" dy="22">ent.profile.ClientProfileViolation;
import dev.caskeleton.adapter.outbound.httpclient.profile.HttpProtocol;
import dev.c</tspan><tspan x="24" dy="22">askeleton.adapter.outbound.httpclient.profile.PoolSettings;
import dev.caskeleton.adapter.outbound.httpclient.profile.Ru</tspan><tspan x="24" dy="22">ntimeEnvironment;
import dev.caskeleton.adapter.outbound.httpclient.profile.TransportType;
import dev.caskeleton.adapter</tspan><tspan x="24" dy="22">.outbound.httpclient.testkit.ClientProfiles;
import java.time.Duration;
import java.util.List;
public final class PoolV</tspan><tspan x="24" dy="22">iolationProbe {
private static PoolSettings routePool(int total, int perRoute) {
return new PoolSettings(
</tspan><tspan x="24" dy="22"> total, perRoute, 16,
Duration.ofSeconds(2), Duration.ofSeconds(30), Duration.ofMinutes(5),
Duration.ofS</tspan><tspan x="24" dy="22">econds(5), Duration.ofSeconds(15), Duration.ofSeconds(5),
true, false);
}
private static PoolSettings pool(</tspan><tspan x="24" dy="22">int total, int perRoute) {
return new PoolSettings(
total,
perRoute,
16,
Duration.of</tspan><tspan x="24" dy="22">Seconds(2),
Duration.ofSeconds(30),
Duration.ofMinutes(5),
Duration.ofSeconds(5),
Durati</tspan><tspan x="24" dy="22">on.ofSeconds(15),
Duration.ofSeconds(5),
false,
false);
}
private static void report(String</tspan><tspan x="24" dy="22"> label, ClientProfile profile) {
List&lt;ClientProfileViolation&gt; found =
new ClientProfileValidator().validate(</tspan><tspan x="24" dy="22">profile, RuntimeEnvironment.PRODUCTION);
System.out.println(&quot; &quot; + label);
if (found.isEmpty()) {
System.o</tspan><tspan x="24" dy="22">ut.println(&quot; 위반 없음&quot;);
return;
}
for (ClientProfileViolation violation : found) {
System.out</tspan><tspan x="24" dy="22">.println(&quot; &quot; + violation);
}
}
public static void main(String[] args) {
System.out.println(&quot;[검증기가 </tspan><tspan x="24" dy="22">내는 형태] 프로덕션 판정, 정렬된 위반 목록&quot;);
report(&quot;전체 20 / 경로당 5&quot;, ClientProfiles.builder(&quot;payment&quot;).pool(po</tspan><tspan x="24" dy="22">ol(20, 5)).build());
report(&quot;전체 20 / 경로당 20 (같음)&quot;, ClientProfiles.builder(&quot;payment&quot;).pool(pool(20, 20)).build</tspan><tspan x="24" dy="22">());
report(
&quot;전송만 SIMPLE 로 바꾼 프로파일&quot;,
ClientProfiles.builder(&quot;payment&quot;).transport(Transport</tspan><tspan x="24" dy="22">Type.SIMPLE).build());
report(
&quot;전송 JDK + 경로 풀 요구 + HTTP/3 미승인&quot;,
ClientProfiles.builder(&quot;pa</tspan><tspan x="24" dy="22">yment&quot;)
.transport(TransportType.JDK)
.pool(routePool(20, 5))
.protocols(java.util.S</tspan><tspan x="24" dy="22">et.of(HttpProtocol.HTTP_1_1, HttpProtocol.HTTP_3))
.build());
System.out.println();
System.out.prin</tspan><tspan x="24" dy="22">tln(&quot;[POOL_ROUTE_EXCEEDS_TOTAL 조건을 만들려면]&quot;);
try {
PoolSettings unusable = pool(10, 20);
System.ou</tspan><tspan x="24" dy="22">t.println(&quot; 전체 10 / 경로당 20 -&gt; 만들어짐 &quot; + unusable.maxConnectionsPerRoute());
} catch (IllegalArgumentExcepti</tspan><tspan x="24" dy="22">on rejected) {
System.out.println(
&quot; 전체 10 / 경로당 20 -&gt; &quot; + rejected.getClass().getSimpleName() + &quot;</tspan><tspan x="24" dy="22">: &quot; + rejected.getMessage());
}
System.out.println(&quot; 프로파일은 이미 만들어진 PoolSettings 를 들고 있으므로,&quot;);</tspan><tspan x="24" dy="22">
System.out.println(&quot; 검증기에 넘길 프로파일 자체를 만들 수 없다.&quot;);
System.out.println();
System.out.prin</tspan><tspan x="24" dy="22">tln(&quot;[DUPLICATE_CLIENT_NAME 조건을 만들려면]&quot;);
ClientProfile one = ClientProfiles.builder(&quot;payment&quot;).build();
j</tspan><tspan x="24" dy="22">ava.util.Map&lt;dev.caskeleton.adapter.outbound.httpclient.api.ClientProfileName, ClientProfile&gt;
profiles = new jav</tspan><tspan x="24" dy="22">a.util.HashMap&lt;&gt;();
profiles.put(one.name(), one);
profiles.put(one.name(), ClientProfiles.builder(&quot;payment&quot;).bu</tspan><tspan x="24" dy="22">ild());
System.out.println(&quot; 같은 이름을 두 번 넣은 맵의 크기 : &quot; + profiles.size());
System.out.println(&quot;</tspan><tspan x="24" dy="22">증기가 이름 중복을 세는 자리는 이 맵을 순회한다.&quot;);
}
}
JAVA
javac -encoding UTF-8 -cp &quot;$JAR:$D&quot; -d &quot;$D&quot; &quot;$D/PoolViola</tspan><tspan x="24" dy="22">tionProbe.java&quot;
java -Dstdout.encoding=UTF-8 -cp &quot;$JAR:$D&quot; PoolViolationProbe
</tspan></text>
<text x="24" y="860" 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="882" 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-02T13:26:24+00:00 · exit 0</tspan></text>
<line x1="24" y1="896" x2="1176" y2="896" stroke="#30363d"/>
<text x="24" y="936" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">openjdk version &quot;21.0.12&quot; 2026-07-21</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"> 전체 20 / 경로당 5</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"> 위반 없음</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"> 전체 20 / 경로당 20 (같음)</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"> 위반 없음</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"> 전송만 SIMPLE 로 바꾼 프로파일</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"> ClientProfileViolation[code=PRODUCTION_SIMPLE_FACTORY_FORBIDDEN, detail=profile=payment setting=transport]</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"> 전송 JDK + 경로 풀 요구 + HTTP/3 미승인</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"> ClientProfileViolation[code=HTTP3_STABLE_FORBIDDEN, detail=profile=payment setting=protocols]</tspan></text>
<text x="24" y="1156" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> ClientProfileViolation[code=JDK_FINE_GRAINED_POOL_UNSUPPORTED, detail=profile=payment setting=transport]</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"></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">[POOL_ROUTE_EXCEEDS_TOTAL 조건을 만들려면]</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"> 전체 10 / 경로당 20 -&gt; IllegalArgumentException: per-route pool must not exceed the total pool</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"> 프로파일은 이미 만들어진 PoolSettings 를 들고 있으므로,</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">[DUPLICATE_CLIENT_NAME 조건을 만들려면]</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"> 같은 이름을 두 번 넣은 맵의 크기 : 1</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>
</svg>