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>
196 lines
19 KiB
XML
196 lines
19 KiB
XML
<svg xmlns="http://www.w3.org/2000/svg" width="1200" height="2196" viewBox="0 0 1200 2196" 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="2194" 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 'rm -rf "$D"' EXIT
|
|
C=/shared/codebase/clean-architecture-backend-template
|
|
</tspan><tspan x="24" dy="22">M=$C/src/adapter/inbound/web
|
|
CACHE=/root/.gradle/caches/modules-2/files-2.1
|
|
java -version 2>&1 | grep version
|
|
cp=""
|
|
whil</tspan><tspan x="24" dy="22">e IFS= read -r line; do
|
|
coord=${line%%=*}; confs=${line#*=}
|
|
case ",$confs," in *",testRuntimeClasspath,"*) ;; *) con</tspan><tspan x="24" dy="22">tinue ;; esac
|
|
g=${coord%%:*}; rest=${coord#*:}; n=${rest%%:*}; v=${rest##*:}
|
|
jar=$(find "$CACHE/$g/$n/$v" -name '*.j</tspan><tspan x="24" dy="22">ar' ! -name '*sources*' ! -name '*javadoc*' 2>/dev/null | head -1) || true
|
|
[ -n "$jar" ] && cp="$cp:$jar"
|
|
done < <(gre</tspan><tspan x="24" dy="22">p -E '^[a-zA-Z0-9._-]+:[^=]+=' "$M/gradle.lockfile")
|
|
SIB=$(find "$C/src" -path '*/build/libs/*+21234e38cdb9*.jar' ! -nam</tspan><tspan x="24" dy="22">e '*-testkit.jar' | sort | tr '\n' ':')
|
|
PROC=$(find "$CACHE/org.springframework.boot/spring-boot-configuration-processor</tspan><tspan x="24" dy="22">/4.0.8" -name '*.jar' ! -name '*sources*' | head -1)
|
|
|
|
mkdir -p "$D/meta"
|
|
javac -encoding UTF-8 -proc:only -processorpath</tspan><tspan x="24" dy="22"> "$PROC" -cp "$SIB$cp" -d "$D/meta" \
|
|
"$M/src/main/java/dev/caskeleton/adapter/inbound/web/advanced/mvc/VirtualThreadS</tspan><tspan x="24" dy="22">ettings.java" 2>&1 | head -3
|
|
|
|
cat > "$D/NamePublishProbe.java" <<'JAVA'
|
|
import dev.caskeleton.adapter.inbound.web.advanc</tspan><tspan x="24" dy="22">ed.mvc.VirtualThreadMvcConfiguration;
|
|
import dev.caskeleton.adapter.inbound.web.advanced.mvc.VirtualThreadSettings;
|
|
impo</tspan><tspan x="24" dy="22">rt dev.caskeleton.adapter.inbound.web.advanced.virtualthread.VirtualThreadProfile;
|
|
import java.nio.file.Files;
|
|
import ja</tspan><tspan x="24" dy="22">va.nio.file.Path;
|
|
import java.util.List;
|
|
import org.springframework.boot.context.properties.ConfigurationPropertiesScan;</tspan><tspan x="24" dy="22">
|
|
import org.springframework.boot.test.context.runner.WebApplicationContextRunner;
|
|
import org.springframework.context.ann</tspan><tspan x="24" dy="22">otation.Configuration;
|
|
|
|
/** 발행된 이름과 실제 이름을 각각 두고, 두 가지 구성으로 컨텍스트를 띄운다. */
|
|
public final cla</tspan><tspan x="24" dy="22">ss NamePublishProbe {
|
|
|
|
private static final String PUBLISHED = VirtualThreadProfile.propertyName();
|
|
private static f</tspan><tspan x="24" dy="22">inal String REAL = "backend.web.advanced.mvc-virtual-threads.enabled";
|
|
|
|
/** 예산은 어느 행에서나 같이 준다. 켜짐 여부</tspan><tspan x="24" dy="22">만 가른다. */
|
|
private static final String[] BUDGETS = {
|
|
"backend.web.advanced.mvc-virtual-threads.admission-limit=</tspan><tspan x="24" dy="22">100",
|
|
"backend.web.advanced.mvc-virtual-threads.database-pool-size=20",
|
|
"backend.web.advanced.mvc-virtual-thread</tspan><tspan x="24" dy="22">s.outbound-bulkhead=20",
|
|
};
|
|
|
|
/** 출하 조립 루트가 이 리프에 대해 거는 것과 같은 패키지. CaSkeletonApplication:72. */</tspan><tspan x="24" dy="22">
|
|
@Configuration(proxyBeanMethods = false)
|
|
@ConfigurationPropertiesScan(basePackages = "dev.caskeleton.adapter.inboun</tspan><tspan x="24" dy="22">d.web")
|
|
static class ShippingPropertiesScan {}
|
|
|
|
/** 이 리프에서 값을 요구하는 설정은 하나뿐이다. 이 발견과 무관하지</tspan><tspan x="24" dy="22">만 없으면 기동이 멈춘다. */
|
|
private static final String ISSUER = "ca-skeleton.security.issuer-uri=https://issuer.examp</tspan><tspan x="24" dy="22">le";
|
|
|
|
private static String[] with(String... extra) {
|
|
String[] values = new String[BUDGETS.length + extra.length];</tspan><tspan x="24" dy="22">
|
|
System.arraycopy(BUDGETS, 0, values, 0, BUDGETS.length);
|
|
System.arraycopy(extra, 0, values, BUDGETS.length, ext</tspan><tspan x="24" dy="22">ra.length);
|
|
return values;
|
|
}
|
|
|
|
private static WebApplicationContextRunner base() {
|
|
// 이 설정의 실행기가 요구</tspan><tspan x="24" dy="22">한다. 없으면 어느 이름을 두든 기동이 실패한다.
|
|
return new WebApplicationContextRunner()
|
|
.withBean(org.spring</tspan><tspan x="24" dy="22">framework.core.task.TaskDecorator.class, () -> runnable -> runnable);
|
|
}
|
|
|
|
private static void row(
|
|
WebApplicati</tspan><tspan x="24" dy="22">onContextRunner runner, String label, String property, String... extra) {
|
|
runner
|
|
.withPropertyValues(
|
|
</tspan><tspan x="24" dy="22"> property == null ? with(extra) : with(concat(extra, property)))
|
|
.run(
|
|
context -> {
|
|
</tspan><tspan x="24" dy="22"> if (context.getStartupFailure() != null) {
|
|
Throwable root = context.getStartupFailure();
|
|
</tspan><tspan x="24" dy="22"> while (root.getCause() != null) {
|
|
root = root.getCause();
|
|
}
|
|
System</tspan><tspan x="24" dy="22">.out.printf(" %-12s %-52s %s%n", label,
|
|
property == null ? "(없음)" : property, "기동 실패 : " + ro</tspan><tspan x="24" dy="22">ot.getMessage());
|
|
return;
|
|
}
|
|
boolean gated = context.getBeanNamesForType(Virt</tspan><tspan x="24" dy="22">ualThreadProfile.class).length > 0;
|
|
String settings =
|
|
context.getBeanNamesForType(Virtua</tspan><tspan x="24" dy="22">lThreadSettings.class).length == 0
|
|
? "없음"
|
|
: "enabled=" + context.getBean(V</tspan><tspan x="24" dy="22">irtualThreadSettings.class).isEnabled();
|
|
System.out.printf(" %-12s %-52s %-9s %s%n", label,
|
|
</tspan><tspan x="24" dy="22"> property == null ? "(없음)" : property, gated ? "켜짐" : "안 켜짐", settings);
|
|
});
|
|
}
|
|
|
|
private stati</tspan><tspan x="24" dy="22">c String[] concat(String[] head, String tail) {
|
|
String[] out = new String[head.length + 1];
|
|
System.arraycopy(hea</tspan><tspan x="24" dy="22">d, 0, out, 0, head.length);
|
|
out[head.length] = tail;
|
|
return out;
|
|
}
|
|
|
|
public static void main(String[] args) t</tspan><tspan x="24" dy="22">hrows Exception {
|
|
System.out.println();
|
|
System.out.println("[이 메서드가 발행하는 이름과 실제 게이트 이름]");
|
|
</tspan><tspan x="24" dy="22"> System.out.printf(" %-22s %s%n", "propertyName() 반환값", PUBLISHED);
|
|
System.out.printf(" %-22s %s%n", "게이트와</tspan><tspan x="24" dy="22"> 바인딩", REAL);
|
|
|
|
System.out.println();
|
|
System.out.println("[게이트된 설정 클래스만 올린 구성]");
|
|
System.out</tspan><tspan x="24" dy="22">.println(" 두 구성 모두 예산 세 값을 늘 함께 준다. 그 값이 없으면 켠 행은 바인딩 검증에서 멈춘다.");
|
|
System.out.pri</tspan><tspan x="24" dy="22">ntf(" %-12s %-52s %-9s %s%n", "", "그 밖에 설정한 advanced 속성", "프로파일 빈", "설정 빈");
|
|
WebApplicationContextR</tspan><tspan x="24" dy="22">unner gateOnly =
|
|
base().withUserConfiguration(VirtualThreadMvcConfiguration.class);
|
|
row(gateOnly, "발행한 이</tspan><tspan x="24" dy="22">름", PUBLISHED + "=true");
|
|
row(gateOnly, "실제 이름", REAL + "=true");
|
|
|
|
System.out.println();
|
|
System.out.pri</tspan><tspan x="24" dy="22">ntln("[루트가 이 리프에 거는 속성 스캔을 그대로 올린 구성]");
|
|
System.out.printf(" %-12s %-52s %-9s %s%n", "", "그 </tspan><tspan x="24" dy="22">밖에 설정한 advanced 속성", "프로파일 빈", "설정 빈");
|
|
WebApplicationContextRunner shipping =
|
|
base()
|
|
</tspan><tspan x="24" dy="22"> .withUserConfiguration(
|
|
ShippingPropertiesScan.class, VirtualThreadMvcConfiguration.class);
|
|
row</tspan><tspan x="24" dy="22">(shipping, "아무것도", null);
|
|
System.out.println(" 아래 세 행은 그 한 값만 채우고 나머지는 그대로 둔다.");
|
|
row(</tspan><tspan x="24" dy="22">shipping, "없음", null, ISSUER);
|
|
row(shipping, "발행한 이름", PUBLISHED + "=true", ISSUER);
|
|
row(shipping, "실제 </tspan><tspan x="24" dy="22">이름", REAL + "=true", ISSUER);
|
|
|
|
Path meta = Path.of(args[0], "META-INF", "spring-configuration-metadata.json");
|
|
</tspan><tspan x="24" dy="22"> System.out.println();
|
|
System.out.println("[이 설정 클래스만 고정 소스로 처리해 얻은 설정 메타데이터]");
|
|
if (!Fi</tspan><tspan x="24" dy="22">les.isRegularFile(meta)) {
|
|
System.out.println(" 생성되지 않음");
|
|
return;
|
|
}
|
|
List<String> names =
|
|
</tspan><tspan x="24" dy="22"> Files.readAllLines(meta).stream()
|
|
.map(String::trim)
|
|
.filter(line -> line.startsWith("\"nam</tspan><tspan x="24" dy="22">e\": \"backend."))
|
|
.map(line -> line.substring(line.indexOf(':') + 3, line.lastIndexOf('"')))
|
|
.d</tspan><tspan x="24" dy="22">istinct()
|
|
.sorted()
|
|
.toList();
|
|
names.forEach(name -> System.out.println(" " + name));
|
|
S</tspan><tspan x="24" dy="22">ystem.out.printf("%n 발행한 이름이 그 안에 있는가 : %s%n", names.contains(PUBLISHED) ? "있다" : "없다");
|
|
}
|
|
}
|
|
JAVA
|
|
jav</tspan><tspan x="24" dy="22">ac -encoding UTF-8 -cp "$SIB$cp" -d "$D/out" "$D/NamePublishProbe.java" 2>&1 | head -5
|
|
printf '%s\n' '<configuration><ro</tspan><tspan x="24" dy="22">ot level="OFF"/></configuration>' > "$D/out/logback.xml"
|
|
java -Dstdout.encoding=UTF-8 -cp "$D/out:$SIB$cp" NamePublishPr</tspan><tspan x="24" dy="22">obe "$D/meta"
|
|
</tspan></text>
|
|
<text x="24" y="1432" 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="1454" 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-03T06:15:16+00:00 · exit 0</tspan></text>
|
|
<line x1="24" y1="1468" x2="1176" y2="1468" stroke="#30363d"/>
|
|
<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">openjdk version "21.0.12" 2026-07-21</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"> propertyName() 반환값 backend.web.advanced.virtual-threads.enabled</tspan></text>
|
|
<text x="24" y="1596" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 게이트와 바인딩 backend.web.advanced.mvc-virtual-threads.enabled</tspan></text>
|
|
<text x="24" y="1618" 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="1640" 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="1662" 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="1684" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 그 밖에 설정한 advanced 속성 프로파일 빈 설정 빈</tspan></text>
|
|
<text x="24" y="1706" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 발행한 이름 backend.web.advanced.virtual-threads.enabled=true 안 켜짐 없음</tspan></text>
|
|
<text x="24" y="1728" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 실제 이름 backend.web.advanced.mvc-virtual-threads.enabled=true 켜짐 enabled=true</tspan></text>
|
|
<text x="24" y="1750" 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="1772" 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="1794" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 그 밖에 설정한 advanced 속성 프로파일 빈 설정 빈</tspan></text>
|
|
<text x="24" y="1816" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 아무것도 (없음) 기동 실패 : APP_SECURITY_JWT_ISSUER (ca-skeleton.secur</tspan><tspan x="24" dy="22">ity.issuer-uri) is required</tspan></text>
|
|
<text x="24" y="1860" 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="1882" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 없음 (없음) 안 켜짐 enabled=false</tspan></text>
|
|
<text x="24" y="1904" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 발행한 이름 backend.web.advanced.virtual-threads.enabled=true 안 켜짐 enabled=false</tspan></text>
|
|
<text x="24" y="1926" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> 실제 이름 backend.web.advanced.mvc-virtual-threads.enabled=true 켜짐 enabled=true</tspan></text>
|
|
<text x="24" y="1948" 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="1970" 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="1992" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> backend.web.advanced.mvc-virtual-threads</tspan></text>
|
|
<text x="24" y="2014" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> backend.web.advanced.mvc-virtual-threads.admission-limit</tspan></text>
|
|
<text x="24" y="2036" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> backend.web.advanced.mvc-virtual-threads.admission-wait</tspan></text>
|
|
<text x="24" y="2058" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> backend.web.advanced.mvc-virtual-threads.database-pool-size</tspan></text>
|
|
<text x="24" y="2080" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> backend.web.advanced.mvc-virtual-threads.enabled</tspan></text>
|
|
<text x="24" y="2102" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> backend.web.advanced.mvc-virtual-threads.outbound-bulkhead</tspan></text>
|
|
<text x="24" y="2124" 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="2146" 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>
|