Files
document-haness/docs/clean-architecture-backend-template/final/evidence/rendered/a-transaction-capability-true-and-its-validator-never-run.svg
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

104 lines
18 KiB
XML

<svg xmlns="http://www.w3.org/2000/svg" width="1200" height="1866" viewBox="0 0 1200 1866" 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="1864" 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">$ M=messaging; K=$M/messaging-kafka/src/main/java/dev/caskeleton/messaging/kafka
S=$M/messaging-spring-boot-starter/src/</tspan><tspan x="24" dy="22">main/java/dev/caskeleton/messaging/autoconfigure
echo &#x27;# 능력 성분의 아홉째 자리&#x27;
grep -n &#x27;boolean brokerTransaction&#x27; $M</tspan><tspan x="24" dy="22">/messaging-core-api/src/main/java/dev/caskeleton/messaging/api/destination/MessagingCapabilities.java
echo &#x27;# Kafka 가</tspan><tspan x="24" dy="22"> 넘기는 열두 값 (아홉째가 참)&#x27;
sed -n &#x27;63,64p&#x27; $K/KafkaMessagingTransport.java
echo &#x27; </tspan><tspan x="24" dy="22"> ^^^^ brokerTransaction&#x27;
echo -n &#x27;# 그 상수 선언이 프로파일을 참조하는가: &#x27;
sed -n &#x27;62,64p&#x27; $K/</tspan><tspan x="24" dy="22">KafkaMessagingTransport.java | grep -c &#x27;profile\|Profile&#x27;
echo -n &#x27;# 이 플래그를 읽는 main 코드: &#x27;
grep -rn &#x27;brokerTra</tspan><tspan x="24" dy="22">nsaction()&#x27; --include=*.java . | grep -c &#x27;/main/&#x27;
echo -n &#x27;# 바로 옆 열째 플래그를 읽는 main 코드: &#x27;
grep -rn &#x27;dedupli</tspan><tspan x="24" dy="22">catedPublish()&#x27; --include=*.java . | grep &#x27;/main/&#x27; | sed &#x27;s|.*/||&#x27;
echo &#x27;# 그 열째가 거짓인 이유&#x27;
sed -n &#x27;53,56p&#x27; $K/K</tspan><tspan x="24" dy="22">afkaMessagingTransport.java
echo
echo &#x27;# 트랜잭션 검증기가 요구하는 다섯&#x27;
grep -n &#x27;if (&#x27; $K/KafkaTransactionProfileValid</tspan><tspan x="24" dy="22">ator.java
sed -n &#x27;46,52p&#x27; $K/KafkaTransactionProfileValidator.java
echo
echo &#x27;# 기동 검증으로 감싸이는 검증기와 직접 불</tspan><tspan x="24" dy="22">리는 검증기&#x27;
grep -rn &#x27;StartupProfileValidation&lt;&#x27; --include=*.java $S | grep -v &#x27;StartupProfileValidation.java&#x27; | grep &#x27;</tspan><tspan x="24" dy="22">public &#x27; | sed &#x27;s|.*/||&#x27;
grep -n &#x27;new DestinationProfileValidator().validateAll&#x27; $S/MessagingCoreAutoConfiguration.java
</tspan><tspan x="24" dy="22">echo &#x27;# 그런데 트랜잭션 검증기는 그냥 빈이다&#x27;
sed -n &#x27;72,77p&#x27; $S/KafkaMessagingAutoConfiguration.java
echo -n &#x27;# 자</tspan><tspan x="24" dy="22">동설정 밖에서 그것을 언급하는 main 코드: &#x27;
grep -rn &#x27;KafkaTransactionProfileValidator&#x27; --include=*.java . | grep &#x27;/main/</tspan><tspan x="24" dy="22">&#x27; | grep -v &#x27;KafkaTransactionProfileValidator.java&#x27; | grep -vc &#x27;KafkaMessagingAutoConfiguration.java&#x27;
echo -n &#x27;# 그것</tspan><tspan x="24" dy="22">을 만드는 test 코드: &#x27;
grep -rn &#x27;KafkaTransactionProfileValidator&#x27; --include=*.java . | grep -c &#x27;/test/&#x27;
echo
echo &#x27;# 감</tspan><tspan x="24" dy="22">쌀 수 없는 이유는 인자 수가 아니다&#x27;
sed -n &#x27;35,40p&#x27; $S/StartupProfileValidation.java
echo -n &#x27;# 두 번째 인자의 출처 —</tspan><tspan x="24" dy="22"> transactionalIdPrefix 가 나오는 곳: &#x27;
grep -rn &#x27;transactionalIdPrefix\|transactional-id-prefix&#x27; --include=*.java --incl</tspan><tspan x="24" dy="22">ude=*.yml --include=*.properties . | grep -v /build/ | sed &#x27;s|.*/||&#x27;
</tspan></text>
<text x="24" y="486" 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="508" 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-02T02:52:53+00:00 · exit 0</tspan></text>
<line x1="24" y1="522" x2="1176" y2="522" stroke="#30363d"/>
<text x="24" y="562" 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="584" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0">33: boolean brokerTransaction,</tspan></text>
<text x="24" y="606" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"># Kafka 가 넘기는 열두 값 (아홉째가 참)</tspan></text>
<text x="24" y="628" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> new MessagingCapabilities(</tspan></text>
<text x="24" y="650" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> true, true, true, true, true, true, true, false, true, false, false, true);</tspan></text>
<text x="24" y="672" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"> ^^^^ brokerTransaction</tspan></text>
<text x="24" y="694" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"># 그 상수 선언이 프로파일을 참조하는가: 0</tspan></text>
<text x="24" y="716" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"># 이 플래그를 읽는 main 코드: 0</tspan></text>
<text x="24" y="738" fill="#e6edf3" font-size="14" font-family="ui-monospace, SFMono-Regular, Menlo, Consolas, monospace" xml:space="preserve"><tspan x="24" dy="0"># 바로 옆 열째 플래그를 읽는 main 코드: DefaultMessagePublisher.java:250: &amp;&amp; !transport.capabilities(profile.name()).ca</tspan><tspan x="24" dy="22">pabilities().deduplicatedPublish()) {</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"># 그 열째가 거짓인 이유</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"> * &lt;p&gt;Declaring it true means {@code PublishDeduplication} is accepted and silently does nothing —</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"> * the caller believes the broker is deduplicating and skips the idempotency it would otherwise</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"> * build. False makes that request a startup failure instead, which is the whole reason the flag</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"> * exists.</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"></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"># 트랜잭션 검증기가 요구하는 다섯</tspan></text>
<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">30: if (transactionalIdPrefix == null || transactionalIdPrefix.isBlank()) {</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">34: if (!brokerProfile.enableIdempotence()) {</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">38: if (!&quot;all&quot;.equals(brokerProfile.acks())) {</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">42: if (brokerProfile.enableAutoCommit()) {</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">46: if (profile.externalSideEffectGuarantee() == ExternalSideEffectGuarantee.INBOX_TRANSACTIONAL) {</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"> if (profile.externalSideEffectGuarantee() == ExternalSideEffectGuarantee.INBOX_TRANSACTIONAL) {</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"> throw new IllegalArgumentException(</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"> &quot;a Kafka transaction does not cover a database side effect; use the Inbox alone: &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"> + profile.name().value());</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"> }</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"> }</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"></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">KafkaMessagingAutoConfiguration.java:54: public StartupProfileValidation&lt;dev.caskeleton.messaging.kafka.KafkaBrokerProfile&gt;</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">MessagingCoreAutoConfiguration.java:216: public StartupProfileValidation&lt;dev.caskeleton.messaging.security.BrokerSecurityProfil</tspan><tspan x="24" dy="22">e&gt;</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">RabbitMessagingAutoConfiguration.java:48: public StartupProfileValidation&lt;dev.caskeleton.messaging.rabbit.RabbitBrokerProfile&gt;</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">134: new DestinationProfileValidator().validateAll(registered);</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"> @Bean</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"> @ConditionalOnMissingBean</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"> public KafkaTransactionProfileValidator kafkaTransactionProfileValidator() {</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"> return new KafkaTransactionProfileValidator();</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"></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"># 자동설정 밖에서 그것을 언급하는 main 코드: 0</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"># 그것을 만드는 test 코드: 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"># 감쌀 수 없는 이유는 인자 수가 아니다</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"> private final Consumer&lt;T&gt; validator;</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"> StartupProfileValidation(Supplier&lt;List&lt;T&gt;&gt; profiles, Consumer&lt;T&gt; validator) {</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"> this.profiles = Objects.requireNonNull(profiles, &quot;profiles must not be null&quot;);</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"> this.validator = Objects.requireNonNull(validator, &quot;validator must not be null&quot;);</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"> }</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"># 두 번째 인자의 출처 — transactionalIdPrefix 가 나오는 곳: KafkaTransactionProfileValidator.java:21: * @param transactiona</tspan><tspan x="24" dy="22">lIdPrefix the configured transactional id prefix</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">KafkaTransactionProfileValidator.java:26: DestinationProfile profile, String transactionalIdPrefix, KafkaBrokerProfile brok</tspan><tspan x="24" dy="22">erProfile) {</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">KafkaTransactionProfileValidator.java:30: if (transactionalIdPrefix == null || transactionalIdPrefix.isBlank()) {</tspan></text>
</svg>