Files
document-haness/docs/clean-architecture-backend-template/final/evidence/rendered/a14-f005-publicpaths-restrictedpathrule-mgmtport.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

125 lines
12 KiB
XML

<svg xmlns="http://www.w3.org/2000/svg" width="1200" height="1360" viewBox="0 0 1200 1360" 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="1358" 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
set -o pipefail
D=$(mktemp -d); trap &#x27;rm -rf &quot;$D&quot;&#x27; EXIT
C=/shared/codebase/clean-architecture-backend-template
</tspan><tspan x="24" dy="22">M=$C/src/app-bootstrap
CACHE=/root/.gradle/caches/modules-2/files-2.1
java -version 2&gt;&amp;1 | head -1
cp=&quot;&quot;
while IFS= read</tspan><tspan x="24" dy="22"> -r line; do
coord=${line%%=*}; confs=${line#*=}
case &quot;,$confs,&quot; in *&quot;,runtimeClasspath,&quot;*) ;; *) continue ;; esac
</tspan><tspan x="24" dy="22"> g=${coord%%:*}; rest=${coord#*:}; n=${rest%%:*}; v=${rest##*:}
jar=$(find &quot;$CACHE/$g/$n/$v&quot; -name &#x27;*.jar&#x27; ! -name &#x27;*s</tspan><tspan x="24" dy="22">ources*&#x27; ! -name &#x27;*javadoc*&#x27; 2&gt;/dev/null | head -1)
[ -n &quot;$jar&quot; ] &amp;&amp; cp=&quot;$cp:$jar&quot;
done &lt; &lt;(grep -E &#x27;^[a-zA-Z0-9._-]+:</tspan><tspan x="24" dy="22">[^=]+=&#x27; &quot;$M/gradle.lockfile&quot;)
CP=${cp#:}
cat &gt; &quot;$D/ManagementPortProbe.java&quot; &lt;&lt;&#x27;JAVA&#x27;
package org.springframework.boot.a</tspan><tspan x="24" dy="22">ctuate.autoconfigure.web.server;
import java.lang.reflect.Constructor;
import java.lang.reflect.Method;
import org.spri</tspan><tspan x="24" dy="22">ngframework.core.type.AnnotationMetadata;
import java.util.LinkedHashMap;
import java.util.Map;
import org.springframewo</tspan><tspan x="24" dy="22">rk.core.env.MapPropertySource;
import org.springframework.core.env.StandardEnvironment;
/** 관리 포트가 같을 때 관리 컨</tspan><tspan x="24" dy="22">텍스트 설정이 어디로 가는지 프레임워크에 직접 물어본다. */
public final class ManagementPortProbe {
private static vo</tspan><tspan x="24" dy="22">id portType(String app, String mgmt) {
Map&lt;String, Object&gt; values = new LinkedHashMap&lt;&gt;();
values.put(&quot;server.po</tspan><tspan x="24" dy="22">rt&quot;, app);
if (mgmt != null) {
values.put(&quot;management.server.port&quot;, mgmt);
}
StandardEnvironment env =</tspan><tspan x="24" dy="22"> new StandardEnvironment();
env.getPropertySources().addFirst(new MapPropertySource(&quot;probe&quot;, values));
System.ou</tspan><tspan x="24" dy="22">t.printf(&quot; server.port=%-6s management.server.port=%-10s %s%n&quot;,
app, mgmt == null ? &quot;(없음)&quot; : mgmt, Management</tspan><tspan x="24" dy="22">PortType.get(env));
}
public static void main(String[] args) throws Exception {
System.out.println();
Syste</tspan><tspan x="24" dy="22">m.out.println(&quot;[출하값과 두 포트를 같게 둔 값으로 ManagementPortType 을 부른다]&quot;);
portType(&quot;8080&quot;, &quot;9001&quot;);
por</tspan><tspan x="24" dy="22">tType(&quot;8080&quot;, &quot;8080&quot;);
portType(&quot;8080&quot;, &quot;&quot;);
portType(&quot;8080&quot;, null);
System.out.println();
System.out.p</tspan><tspan x="24" dy="22">rintln(&quot;[SAME 일 때 부트가 켜는 설정과 그 설정이 고르는 타입]&quot;);
Class&lt;?&gt; same = Class.forName(
&quot;org.springf</tspan><tspan x="24" dy="22">ramework.boot.actuate.autoconfigure.web.server&quot;
+ &quot;.ManagementContextAutoConfiguration$SameManagementContext</tspan><tspan x="24" dy="22">Configuration&quot;);
Class&lt;?&gt; enabler = Class.forName(same.getName() + &quot;$EnableSameManagementContextConfiguration&quot;);
</tspan><tspan x="24" dy="22"> System.out.println(&quot; &quot; + same.getSimpleName() + &quot; 조건 : &quot;
+ same.getAnnotation(ConditionalOnManagementPort.cl</tspan><tspan x="24" dy="22">ass).value());
System.out.println(&quot; &quot; + enabler.getSimpleName() + &quot; 가 켜는 것 : &quot;
+ enabler.getAnnotation(</tspan><tspan x="24" dy="22">EnableManagementContext.class).value());
System.out.println();
System.out.println(&quot;[그 설정이 고르는 클래스. 조</tspan><tspan x="24" dy="22">건 평가는 이 단계에 없다]&quot;);
Constructor&lt;?&gt; ctor = ManagementContextConfigurationImportSelector.class
.getDe</tspan><tspan x="24" dy="22">claredConstructor();
ctor.setAccessible(true);
Object selector = ctor.newInstance();
Method select = Managem</tspan><tspan x="24" dy="22">entContextConfigurationImportSelector.class
.getDeclaredMethod(&quot;selectImports&quot;, AnnotationMetadata.class);
s</tspan><tspan x="24" dy="22">elect.setAccessible(true);
String[] selected = (String[]) select.invoke(selector, AnnotationMetadata.introspect(enab</tspan><tspan x="24" dy="22">ler));
for (String name : selected) {
boolean ours = name.startsWith(&quot;dev.caskeleton&quot;);
String suffix = </tspan><tspan x="24" dy="22">&quot;&quot;;
if (ours) {
Object annotation = Class.forName(name).getAnnotation(
org.springframework.boo</tspan><tspan x="24" dy="22">t.actuate.autoconfigure.web.ManagementContextConfiguration.class);
suffix = &quot; 등록 타입 &quot; + ((org.springframew</tspan><tspan x="24" dy="22">ork.boot.actuate.autoconfigure.web
.ManagementContextConfiguration) annotation).value();
}
Syste</tspan><tspan x="24" dy="22">m.out.println(&quot; &quot; + (ours ? &quot;*&quot; : &quot; &quot;) + &quot; &quot; + name + suffix);
}
}
}
JAVA
# 선택자가 읽을 클래스는 고정 리비전 소</tspan><tspan x="24" dy="22">스에서 직접 컴파일한다. 빌드 산출물은 쓰지 않는다.
SIB=$(find &quot;$C/src&quot; -path &#x27;*/build/libs/*+21234e38cdb9.jar&#x27; ! -name &#x27;</tspan><tspan x="24" dy="22">*-testkit.jar&#x27; | tr &#x27;\n&#x27; &#x27;:&#x27;)
javac -encoding UTF-8 -cp &quot;$SIB$CP&quot; -d &quot;$D/out&quot; \
&quot;$M/src/main/java/dev/caskeleton/boots</tspan><tspan x="24" dy="22">trap/autoconfigure/fileserver/FileserverAdminManagementContextConfiguration.java&quot; \
&quot;$D/ManagementPortProbe.java&quot; 2&gt;&amp;1</tspan><tspan x="24" dy="22"> | head -5
java -Dstdout.encoding=UTF-8 -cp &quot;$D/out:$SIB$CP:$M/src/main/resources&quot; \
org.springframework.boot.actuate.</tspan><tspan x="24" dy="22">autoconfigure.web.server.ManagementPortProbe
</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">cwd: /shared/codebase/clean-architecture-backend-template/src</tspan></text>
<text x="24" y="904" 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-02T22:24:25+00:00 · exit 0</tspan></text>
<line x1="24" y1="918" x2="1176" y2="918" stroke="#30363d"/>
<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">openjdk version &quot;21.0.12&quot; 2026-07-21</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">[출하값과 두 포트를 같게 둔 값으로 ManagementPortType 을 부른다]</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"> server.port=8080 management.server.port=9001 DIFFERENT</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"> server.port=8080 management.server.port=8080 SAME</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"> server.port=8080 management.server.port= SAME</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"> server.port=8080 management.server.port=(없음) SAME</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"></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">[SAME 일 때 부트가 켜는 설정과 그 설정이 고르는 타입]</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"> SameManagementContextConfiguration 조건 : SAME</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"> EnableSameManagementContextConfiguration 가 켜는 것 : SAME</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">[그 설정이 고르는 클래스. 조건 평가는 이 단계에 없다]</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"> org.springframework.boot.security.autoconfigure.actuate.web.servlet.SecurityRequestMatchersManagementContextConfiguration</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"> org.springframework.boot.servlet.autoconfigure.actuate.web.ServletEndpointManagementContextConfiguration</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"> org.springframework.boot.webmvc.autoconfigure.actuate.web.WebMvcEndpointManagementContextConfiguration</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"> * dev.caskeleton.bootstrap.autoconfigure.fileserver.FileserverAdminManagementContextConfiguration 등록 타입 ANY</tspan></text>
</svg>