PR #3155 review history
Unit 1A · identity, Account and public JOIN
Review rounds
Three-number pills mean: found (raw) / accepted here (useful) / routed
Recorded review history
Reviews and findings
- CLI Review 1 CompletedRuntime 3m 04sFound: 6 Accepted: 2/3/1 Routed: 0
- Extract the duplicated authority-bundle fixture builder.Trivial
At least 11 new or changed test classes contain almost the same canonical
authorityEvidenceBundle/v1builder. Each copy has the same scope, projection, operation identity, authority tuple, and human-evidence maps. The copies are in these files:AccountStartSessionWorldParticipationHistoricalReadServiceTestAccountStartSessionWorldParticipationSettlementServiceTestAccountStartSessionWorldParticipationAcquisitionGrpcServiceTestAccountStartSessionWorldParticipationRepositoryTestAccountStartSessionWorldOriginalAttemptEvidenceRepositoryTestAccountStartSessionOperatorAuthorizationRepositoryTestWorldStartSessionExecutionTerminalTestWorldStartSessionExecutionTerminalReadGrpcCodecTestAccountStartSessionWorldParticipationHistoricalReadGrpcCodecTestAccountStartSessionWorldParticipationAcquisitionClientMtlsTest
A future change to the closed
ROOT_FIELDSorHUMAN_TENANT_FIELDSsets inStartSessionAuthorityEvidenceBundlewould require the same edit in every copy.Move one parameterized builder into a test-fixtures source set that all three modules can use. Its parameters can include the tuple, issuance fence, source version, and evaluated/expiry instants.
- Accepted Verified11 repeated canonical bundle scenario builders across Account/Core/Security. Share a test-only parameterized data fixture, preserving every explicit scenario value, independent decoder oracle and terminal golden bytes; no production schema/behavior changes.
- Name the capability row that owns the new World participation preparation.Minor
Every other preparation subsection in this tracker names its owning capability, for example "owned by AA-1.3 in Capability Status". The new subsection names no owner. Add that line, and update the matching
Capability Statusrow with the new production anchors and theNo focused executable proof:limits. Use V158–V160 and the participation repositories as the anchors.As per coding guidelines: "Keep its status, implementation record, validation, gaps, decisions, and service-map sections aligned when a domain boundary changes."
- Accepted The new World participation preparation lacks its existing AA-1.3 owner and row anchors. Add V158–V160 and capture/participation/original-attempt repositories, preserving partial/drift-found status and explicit genuine-owner/composed-execution proof gaps.
- Allow bounded clock skew when Account compares Logging's
observedAtwith its own clock.MajorobservedAtEpochMilliscomes from the Logging & Admin clock.nowcomes from the Accountclock. The conditionnow < observedAtrejects the claim when Account's clock is behind Logging's by more than the RPC latency. A lag of a few milliseconds is enough.The check runs up to six times per ISSUE and RECOVER call. Ordinary cross-host clock drift therefore makes StartSession issuance and recovery fail with
FAILED_PRECONDITIONon otherwise valid claims. The failure is intermittent or persistent, depending on the drift direction.Allow a small, explicit future skew for
observedAt. Keep the strictnow >= expiresAtexpiry check.Proposed fix
+ private static final long MAX_CLAIM_OBSERVATION_SKEW_MILLIS = 1_000L; + private void requireFreshClaimEvidence(ReadCurrentClaimEvidenceResponse evidence) { Objects.requireNonNull(evidence, "Logging/Admin claim evidence is required"); long observedAt = evidence.getObservedAtEpochMillis(); long expiresAt = evidence.getClaimExpiresAtEpochMillis(); long now = clock.millis(); - if (observedAt <= 0L || expiresAt <= observedAt || now < observedAt || now >= expiresAt) { + if (observedAt <= 0L + || expiresAt <= observedAt + || now < observedAt - MAX_CLAIM_OBSERVATION_SKEW_MILLIS + || now >= expiresAt) {- Accepted Overseer decision1223: remove only unsupported producer-observation versus Account-now ordering in both checks; preserve strict local expiry, positive ordered producer evidence, exact bindings and all authority gates.
- Make the "current-parent gate" proof claim match the recorded runs.Minor
Line 25 says "The current-parent gate passed six physical PostgreSQL disclosure-handoff storage cases". The recorded runs do not support that wording:
- Line 21 says the local current-parent full gate at
c7a61401…failed. - Line 23 says the later current-parent carry at
932f2e13…ran only five targeted physical integration cases. Those five cases came fromAccountGameplayDelegationRedisIntegrationTest.
Neither run is a passing current-parent gate that included six disclosure-handoff cases. Name the exact run that executed these cases, for example the
0a84bfa2…exact-head CI run 38276405663. Otherwise, state that the cases passed inside the failed local gate.As per coding guidelines, "a historical broad test run does not substitute for focused proof".
- Accepted The six disclosure-handoff physical cases passed within the failed c7a local aggregate and in exact0a84 CI38276405663. The later932 targeted5 did not include this suite; name exact proof rather than claiming a passing current-parent aggregate.
- Line 21 says the local current-parent full gate at
- Confirm that every committed participation reaches settlement, including after a failed acquisition response.Major
The participation commits inside
withCurrentWorldReceivingParticipationCurrentness. The later readback callsattemptEvidenceRepository.findCurrentExact, and that method requires the original Game Session lease to be unexpired. Two paths leave a committed, unsettled participation behind a failed response:- The lease expires between commit and readback.
toResponsein the gRPC adapter rejects the result.
In both cases World receives
FAILED_PRECONDITION. An exact retry also fails, because both the lease check and the insert-time reference-expiry trigger fail closed.The unsettled participation has downstream effects:
DraftAuthorizationFenceRepository.allAffectedSettledreturns false for its sources.- The V159 source-change and hosted-terms guards block those sources.
- The source vector includes the actor's Account source. Password reset for that account therefore stays
WAITINGand returnsAUTH_UNAVAILABLEuntil settlement.
Settlement requires a World-owned terminal. No expiry-based abort path exists.
Verify one of the following:
- World Management always produces an
ABORTEDterminal for a participation it never started, even when it received an acquisition failure. - Account must expose a bounded abort path that settles never-started participations.
If neither exists, add one before registration.
- Accepted Decision1223: correct Account original-tuple historical discovery in3155; genuine World COMMITTED/fenced-ABORTED producer remains separately OPEN pre-activation. Account correction must not claim compound finding wholly fixed.
- Skip the World participation check when the handoff is already
DISPATCHAUTHORIZED.MinorSkip the World participation check when the handoff is already `DISPATCH_AUTHORIZED`.
authorizeDispatchcallsrequireWorldParticipationDisclosureAdmissionbefore it reads the row status. The Javadoc says an existingDISPATCH_AUTHORIZEDrow "is recovered by readback". That recovery now throws if any handoff source has a pending World participation.This state is reachable:
- The handoff vector can contain non-hosted-terms sources, for example
ACCOUNT. - V159
assert_exclusiveblocks participation only on the exact disclosed hosted-terms evidence. - A participation can therefore become pending on another vector source after dispatch was authorized.
The V159 trigger blocks only the
PREPARED/AMBIGUOUS→DISPATCH_AUTHORIZEDtransition. Apply the participation check only to those transitions.Proposed fix
- fenceRepository.requireWorldParticipationDisclosureAdmission(handoff.sources()); - Record row = requireExactRow(handoff); + fenceRepository.lockDisclosureSources(handoff.sources()); + Record row = requireExactRow(handoff); Status status = Status.valueOf(row.get("status", String.class)); boolean newlyAuthorized = false; + if (status == Status.PREPARED || status == Status.AMBIGUOUS) { + fenceRepository.requireWorldParticipationDisclosureAdmission(handoff.sources()); + }- Accepted Verified authorizeDispatch applies World exclusion before status lookup, incorrectly denying exact DISPATCH_AUTHORIZED readback. Keep sorted source locks before journal and guard only PREPARED/AMBIGUOUS authorization transitions, with immutable SQL and no new dispatch on recovered authorization.
- The handoff vector can contain non-hosted-terms sources, for example
- Hosted Review 1 CompletedRuntime 10m 15sFound: 6 Accepted: 1/1/3 Routed: 0
- Check the named source-fence constraint when an invalid fence is rejected.Trivial
The loop only checks for SQLSTATE
23514. Any CHECK constraint or guard trigger that raisescheck_violationmeets that check. For example, an insert guard that compares the bundle with its reference would also pass the test. This test means to proveaccount_ss_operator_bundle_source_fence_canonical_check, so check that name in the PostgreSQL server diagnostic.♻️ Proposed assertion
.satisfies( - failure -> assertThat(findSqlException(failure).getSQLState()).isEqualTo("23514")); + failure -> { + SQLException sqlFailure = findSqlException(failure); + assertThat(sqlFailure.getSQLState()).isEqualTo("23514"); + assertThat(sqlFailure) + .isInstanceOfSatisfying( + org.postgresql.util.PSQLException.class, + postgres -> + assertThat(postgres.getServerErrorMessage().getConstraint()) + .isEqualTo( + "account_ss_operator_bundle_source_fence_canonical_check")); + });- Accepted SQLState23514 alone does not prove the named source-fence CHECK. Require its actual Postgres server constraint diagnostic, alongside immutable V160→160.1 identity proof.
- Plan for unsettled World participation before any runtime registration.Trivial
With this change,
allAffectedSettledreturnsfalsewhile any overlapping World participation is unsettled. Such a participation blockssourceMutationPermitted,sourceAbortPermitted,markSourceCommitted, andmarkSourceAbortedfor every source in its captured vector. That vector includes the actor'sACCOUNTsource.The docs state that Account expiry does not settle a participation. Only a World
COMMITTEDor fencedABORTEDterminal settles it, and that producer is still open. If a World terminal is never produced, Account source changes for that actor stayWAITINGwith no end condition. Password reset and other source writers would return retryableAUTH_UNAVAILABLEuntil settlement.The methods are not registered today, so nothing reaches this state yet. Before activation, define and document one of these:
- A bounded settlement or reconciliation path.
- An operator-visible metric or alert for participations that stay pending.
- Rejected Duplicate of the already-owned World terminal/reconciliation readiness obligation39aaOPEN/unassigned; no new passiveAccount source fix or expiry-abort is authorized/needed. Existing route/producer activation hold stays explicit, not waived or counted fixed.
- Bind the complete Account reference at each consumer boundary.Major
requireReferenceBindingchecks onlybundleVersionandsourceVersion. Account binds all four fields when it creates the reference, butStartSessionOperatorAuthorizationClient.validateResponseandStartSessionPostAuthorizationExecutionTuple.createHumanaccept supplied references after only the partial check. A reference with the correctsourceVersionbut substitutedsourceFenceorlinearizationcan therefore enter the tuple and pass later Game Session checks.The source fence does not need to equal the issuance fence. Bind it and
linearizationto the immutable Account capture before accepting the tuple, and add rejection coverage for substituted values. The accepted test case should remain accepted.- Accepted Root decision1234 requires complete Account-derived original post-tuple evidence in authenticated ISSUE/RECOVER/REDEEM replies and comparison at Logging/GS redemption/launch. Earlier partial bindings need owned correction; no sourceFence=issuanceFence or inactive-only deferral.
- Replace the
/tmplog path with a resolvable proof reference, and record the current proof run.MinorLine 19 cites
/tmp/gameplay3155-reconciled-account-proof.logas captured evidence. Readers cannot open that path, and it is not in the repository. The tracker guideline requires evidence targets to be "repository-local and resolvable".The proof record is also behind the PR description. The tracker records 1,255 or 1,280 unit cases and five targeted physical cases. The PR description reports 1,289 Account unit cases and ten selected real PostgreSQL/Redis cases, including the new after-expiry recovery case.
Make these changes:
- Remove the
/tmppath, or replace it with a CI run or artifact link. - Record the latest focused proof and its exact scope. Keep the statement that this proof is not an unfiltered physical run.
As per coding guidelines, "Evidence targets must be repository-local and resolvable".
- Accepted Tracker temporary evidence and proof scope are stale; verified selected10 current cases and later224/4 endpoint failures must be recorded honestly with repository test anchors, preserving prior history.
- Remove the
- Correct the “V128” migration labels to “V158”.Trivial
The capture migration is
V158__account_start_session_authority_captures.sql. Rename the Javadoc and assertion messages so they identify the migration that creates these objects.-/** PostgreSQL proof of V128 allocator ownership and capture-table statement protection. */ +/** PostgreSQL proof of V158 allocator ownership and capture-table statement protection. */ ... - "V128 protection trigger query must return a row") + "V158 protection trigger query must return a row") ... - "V128 capture guard function must exist") + "V158 capture guard function must exist") ... - "V128 capture count query must return a row") + "V158 capture count query must return a row")- Accepted Capture migration is receivingV158; correct stale donorV128 Javadoc/assertion labels with testbehavior unchanged.
- Check guard diagnostics in the new SQL-guard tests, not only
RuntimeException.TrivialThese PostgreSQL tests prove database guards, but each one passes on any
RuntimeException. A plainTRUNCATEon a table that a foreign key references fails with SQLSTATE0A000before any trigger runs. This PR shows that behavior inAccountStartSessionOperatorAuthorizationRepositoryIntegrationTest. A missing trigger therefore stays undetected. Reuse theassertImmutableGuardRejectedpattern, which checks SQLSTATE23514and the server message, and useTRUNCATE ... CASCADEto reach the no-truncate trigger.services/account-service/src/test/java/integration/net/firedevops/firemud/accountservice/repository/AccountStartSessionWorldParticipationPostgresIntegrationTest.java#L420-L436: UseTRUNCATE <table> CASCADE. Check SQLSTATE23514for each table, because the sources and settlements tables referenceaccount_start_session_world_participations.services/account-service/src/test/java/integration/net/firedevops/firemud/accountservice/service/session/AccountStartSessionAuthorityCapturePostgresIntegrationTest.java#L108-L118: UseTRUNCATE account_start_session_authority_captures CASCADE. Check the guard SQLSTATE and message for the allocatorUPDATE/DELETEand for the truncate.services/account-service/src/test/java/integration/net/firedevops/firemud/accountservice/repository/AccountStartSessionWorldOriginalAttemptEvidencePostgresIntegrationTest.java#L205-L221: Check the lease-guard SQLSTATE and message for the expiredINSERT. Apply the same check inassertAppendOnly(L275-L291).services/account-service/src/test/java/integration/net/firedevops/firemud/accountservice/service/session/AccountStartSessionWorldParticipationPostgresIntegrationTest.java#L448-L454: Check the settlement immutability guard's SQLSTATE and message for the directUPDATE.
📍 Affects 4 files
services/account-service/src/test/java/integration/net/firedevops/firemud/accountservice/repository/AccountStartSessionWorldParticipationPostgresIntegrationTest.java#L420-L436(this comment)services/account-service/src/test/java/integration/net/firedevops/firemud/accountservice/service/session/AccountStartSessionAuthorityCapturePostgresIntegrationTest.java#L108-L118services/account-service/src/test/java/integration/net/firedevops/firemud/accountservice/repository/AccountStartSessionWorldOriginalAttemptEvidencePostgresIntegrationTest.java#L205-L221services/account-service/src/test/java/integration/net/firedevops/firemud/accountservice/service/session/AccountStartSessionWorldParticipationPostgresIntegrationTest.java#L448-L454
- Accepted Generic runtime errors/plain TRUNCATE can pass on foreign-key failure instead of owned guards; strengthen exactSQLState/message/CASCADE focusedphysical proof, preserving publishedSQL.
- CLI Review 2 CompletedRuntime 3m 04sFound: 4 Accepted: 1/2/0 Routed: 0
- Add
V160.1and the new focused tests to the AA-1.3 record.Minor- Line 17 maps receiving migrations only through V160. It does not record
V160.1__start_session_operator_bundle_source_fence.sql. That migration changes a constraint on the retained operator-authorization table, so it is a real change to the domain boundary. - The AA-1.3 implementation-anchor cell lists V158–V160 and three repositories. It does not list
V160.1or the new acquisition, historical-read, and settlement services. - The AA-1.3 proof-anchor cell lists none of the new focused PostgreSQL tests:
AccountStartSessionWorldParticipationPostgresIntegrationTestAccountStartSessionWorldOriginalAttemptEvidencePostgresIntegrationTestAccountStartSessionAuthorityCapturePostgresIntegrationTestHostedTermsDisclosureHandoffPostgresIntegrationTest- Line 19 cites
/tmp/gameplay3155-reconciled-account-proof.logas evidence. That file is outside the repository and cannot be resolved by a reader.
The guidelines require the tracker sections to stay aligned when a domain boundary changes. They also say evidence targets "must be repository-local and resolvable."
Add
V160.1to the migration-intake paragraph and to the implementation anchors. Add the focused tests to the proof anchors. Replace the/tmppath with a CI run or artifact ID, or remove it.As per coding guidelines: "Keep its status, implementation record, validation, gaps, decisions, and service-map sections aligned when a domain boundary changes" and "Evidence targets must be repository-local and resolvable."
Also applies to: 137-137
- Accepted Verified AA-1.3 intake/implementation/proof anchors omit V160.1 and owning services/tests; remove unreachable temporary evidence reference and record bounded actual proof/current limits.
- Line 17 maps receiving migrations only through V160. It does not record
- Return a non-retryable status for permanent denials. Do not return
UNAVAILABLE.MinorOnly
IllegalArgumentExceptionmaps toFAILED_PRECONDITION. Every otherRuntimeExceptionmaps toUNAVAILABLE. That catch-all also receives permanent denials:AccountStartSessionOperatorAuthorizationService.denied(...)throwsIllegalStateException. Examples are a changed tuple, an expired reference, the wrong target owner, or a mismatched redeemed projection.AccountStartSessionOperatorAuthorizationService.NotFoundExceptionis thrown when no original issuance exists.AccountStartSessionWorldParticipationRepository.conflict()andunavailable()throwIllegalStateException. So doAccountStartSessionWorldOriginalAttemptEvidenceRepository.conflict()andunavailable().
A World caller treats
UNAVAILABLEas transient. It would retry these terminal denials forever and never classify the failure. The historical-read receiver in this PR handles the same exceptions correctly:AccountStartSessionWorldParticipationHistoricalReadGrpcServicemapsIllegalStateExceptiontoFAILED_PRECONDITION. Make both receivers classify errors the same way.🐛 Proposed status mapping
- } catch (IllegalArgumentException invalidEvidence) { + } catch (AccountStartSessionOperatorAuthorizationService.NotFoundException missing) { + observer.onError(Status.NOT_FOUND.asRuntimeException()); + } catch (org.springframework.transaction.CannotCreateTransactionException + | org.springframework.dao.DataAccessException + | org.jooq.exception.DataAccessException unavailable) { + observer.onError(Status.UNAVAILABLE.asRuntimeException()); + } catch (IllegalArgumentException | IllegalStateException invalidEvidence) { observer.onError(Status.FAILED_PRECONDITION.asRuntimeException()); } catch (RuntimeException unavailable) { - observer.onError(Status.UNAVAILABLE.asRuntimeException()); + observer.onError(Status.INTERNAL.asRuntimeException()); }Keep connection-level
08xxxSQL failures mapped toUNAVAILABLE, asStartSessionOperatorAuthorizationGrpcService.invokealready does.As per path instructions: "Flag changes that violate documented FireMUD invariants, especially gRPC application-error handling."
- Accepted Verified receiver maps permanent owner IllegalState/NotFound denials to transientUNAVAILABLE; bounded redacted canonical error classification and meaningful tests required.
- Close jOOQ ignore blocks with
[jooq ignore stop].TrivialTwo new migrations end their ignore blocks with
[jooq ignore end]. V158 and V159 use[jooq ignore stop], which is jOOQ's default parser stop token. An unrecognized end marker leaves the block open. Today this is harmless only because each marker is the last line of its file. Any DDL appended after the marker later would be skipped silently by jOOQ generation.services/account-service/src/main/resources/db/migration/V160.1__start_session_operator_bundle_source_fence.sql#L12-L12: replace-- [jooq ignore end]with-- [jooq ignore stop].services/account-service/src/main/resources/db/migration/V160__start_session_world_original_attempt_evidence.sql#L73-L73: replace-- [jooq ignore end]with-- [jooq ignore stop].
- Rejected Both blocks end at immutable published EOF; no following DDL is lost. Current Account generateJooq passed. Future appends are prohibited by SQL-history immutability; no existing projection loss justifies rewriting checksummed files or speculative generator compatibility.
- Confirm which constraint
accountstartsessionoperatorauthorizationschecknames before dropping it by that name.MajorConfirm which constraint `account_start_session_operator_authorizations_check` names before dropping it by that name.
PostgreSQL generates names for unnamed table-level checks:
<table>_check, then_check1,_check2, and so on, in declaration order. This migration drops the first generated name blindly. If V126 or a later migration declared more than one unnamed table-level check, this name could belong to a different invariant than thebundle_source_fence = issuance_fenceequality. Examples are a timestamp-ordering check or a redemption-shape check. That invariant would then disappear silently. TherealPostgresEnforcesCanonicalPositiveLongRangeForBundleSourceFencetest only proves that the new constraint exists and the old name does not. It does not prove which expression was removed.V126.3 already handles this case safely: it locates its guard by definition and fails closed if the match is absent or ambiguous. Use the same pattern here. Find the check by
pg_get_constraintdefcontent that references bothbundle_source_fenceandissuance_fence. Require exactly one match, then drop that constraint.Inspect the result with
SELECT conname, pg_get_constraintdef(oid) FROM pg_constraint WHERE conrelid = 'account_start_session_operator_authorizations'::regclass AND contype = 'c' ORDER BY conname;at target V160.♻️ Definition-matched drop
DO $migration$ DECLARE matched TEXT[]; BEGIN SELECT array_agg(conname) INTO matched FROM pg_constraint WHERE conrelid = 'account_start_session_operator_authorizations'::regclass AND contype = 'c' AND pg_get_constraintdef(oid) LIKE '%bundle_source_fence%' AND pg_get_constraintdef(oid) LIKE '%issuance_fence%'; IF coalesce(array_length(matched, 1), 0) <> 1 THEN RAISE EXCEPTION 'Expected exactly one bundle source-fence/issuance-fence check'; END IF; EXECUTE format('ALTER TABLE account_start_session_operator_authorizations DROP CONSTRAINT %I', matched[1]); END; $migration$;- Accepted Useful exact legacy-constraint identity and preservation proof gap. Existing distinct-fence PG proof confirms canonical effect; strengthen targetV160→160.1 catalogue/prepost proof while preserving published SQL, not blindly rewrite immutable history.
- Hosted Review 2 CompletedRuntime 9m 46sFound: 3 Accepted: 0/1/1 Routed: 0
- Do not report every unexpected failure as retryable
UNAVAILABLE.MinorThe final
catch (RuntimeException unavailable)maps all other runtime failures toUNAVAILABLE. These failures include programming errors such asNullPointerException, non-connection jOOQ/SpringDataAccessExceptions, andClassCastException. A World caller treatsUNAVAILABLEas transient. A deterministic defect therefore causes unbounded retries, not a terminal failure.The sibling receiver
AccountStartSessionWorldParticipationAcquisitionGrpcService(Lines 109-121) already uses the stricter contract:CannotCreateTransactionExceptionmaps toUNAVAILABLE.- A
DataAccessExceptionwith SQLSTATE08*maps toUNAVAILABLE. - Every other failure maps to
INTERNAL.
Use the same mapping here. The two World-facing Account receivers then share one gRPC application-error contract. As per path instructions, flag "changes that violate documented FireMUD invariants, especially gRPC application-error handling".
Proposed fix
--- "a/services/account-service/src/main/java/net/firedevops/firemud/accountservice/service/session/AccountStartSessionWorldParticipationHistoricalReadGrpcService.java" +++ "b/services/account-service/src/main/java/net/firedevops/firemud/accountservice/service/session/AccountStartSessionWorldParticipationHistoricalReadGrpcService.java" @@ -71,12 +71,30 @@ AccountStartSessionWorldParticipationHistoricalReadGrpcCodec.toResponse( decoded, evidence)); observer.onCompleted(); } catch (StatusRuntimeException failure) { observer.onError(failure); } catch (IllegalArgumentException | IllegalStateException mismatch) { observer.onError(Status.FAILED_PRECONDITION.asRuntimeException()); - } catch (RuntimeException unavailable) { - observer.onError(Status.UNAVAILABLE.asRuntimeException()); + } catch (org.springframework.transaction.CannotCreateTransactionException unavailable) { + observer.onError(Status.UNAVAILABLE.asRuntimeException()); + } catch (org.jooq.exception.DataAccessException + | org.springframework.dao.DataAccessException failure) { + observer.onError( + (hasConnectionFailureSqlState(failure) ? Status.UNAVAILABLE : Status.INTERNAL) + .asRuntimeException()); + } catch (RuntimeException failure) { + observer.onError(Status.INTERNAL.asRuntimeException()); } } + + private static boolean hasConnectionFailureSqlState(Throwable failure) { + for (Throwable cause = failure; cause != null; cause = cause.getCause()) { + if (cause instanceof java.sql.SQLException sql + && sql.getSQLState() != null + && sql.getSQLState().startsWith("08")) { + return true; + } + } + return false; + } }- Accepted Minor: historical receiver maps deterministic runtime/non-connection DB defects to retryable UNAVAILABLE. Align with existing acquisition transport contract: connection08*/transaction-unavailable transient, other failures INTERNAL; retain mismatch denial.
- Reuse one static strict
JsonMapper.TrivialparseObjectbuilds a newJsonMapperon every call. OneprepareOrReadExactor lock call runsparseObjectat least three times. Two calls come fromrequireStoredColumnsMatchPayload(once indecodeand once inrequireSameRequestAndSnapshot), and one comes fromrequireSameRequestAndSnapshot. Building a mapper is expensive, and it discards the mapper's deserializer caches. Each call does this work while it holds the row lock.AccountStartSessionAuthorityCaptureandAccountStartSessionOperatorAuthorityBundlealready use a static strict mapper.♻️ Proposed refactor
--- "a/services/account-service/src/main/java/net/firedevops/firemud/accountservice/service/session/AccountStartSessionAuthorityCaptureRepository.java" +++ "b/services/account-service/src/main/java/net/firedevops/firemud/accountservice/service/session/AccountStartSessionAuthorityCaptureRepository.java" @@ -511,14 +511,15 @@ && targetNamespace.equals(peer.namespace()); } + private static final tools.jackson.databind.json.JsonMapper JSON = + tools.jackson.databind.json.JsonMapper.builder() + .enable(tools.jackson.core.StreamReadFeature.STRICT_DUPLICATE_DETECTION) + .enable(tools.jackson.databind.DeserializationFeature.FAIL_ON_TRAILING_TOKENS) + .build(); + private static Map<?, ?> parseObject(byte[] bytes) { try { - Object value = - tools.jackson.databind.json.JsonMapper.builder() - .enable(tools.jackson.core.StreamReadFeature.STRICT_DUPLICATE_DETECTION) - .enable(tools.jackson.databind.DeserializationFeature.FAIL_ON_TRAILING_TOKENS) - .build() - .readValue(new String(bytes, StandardCharsets.UTF_8), Object.class); + Object value = JSON.readValue(new String(bytes, StandardCharsets.UTF_8), Object.class); if (value instanceof Map<?, ?> map) return map; throw unavailable(); } catch (RuntimeException malformed) {- Accepted Trivial: verified repeated strict JsonMapper construction during locked capture reads. Reuse one immutable static mapper retaining duplicate/trailing-token rejection; no wire/storage semantic change.
- Close the jOOQ ignore block with
[jooq ignore stop].MinorjOOQ 3.21 recognizes
[jooq ignore start]and[jooq ignore stop]by default. The codegen configuration does not define a custom terminator, so[jooq ignore end]leaves the ignore region open. The migration glob can then suppress later migrations during code generation.--- [jooq ignore end] +-- [jooq ignore stop]Check whether V160 has been applied in any shared environment before editing it. Editing an applied Flyway migration changes its checksum.
- Rejected Minor: exactjOOQ3.21.9 DDLDatabase loads/parses each Source separately, not concatenatedglobs; jar/sourceverified. Bothignoredregions endatEOF, no laterDDL suppressed. Publishedmigrations immutable; changingchecksum adds no useful correction.
- CLI Review 3 CompletedRuntime 3m 17sFound: 3 Accepted: 0/1/0 Routed: 0
- Use the standard
[jooq ignore stop]terminator in both new migrations.TrivialV158, V159, and the jOOQ
DDLDatabasedefault close ignore regions with[jooq ignore stop]. These two files use[jooq ignore end]. If the generator does not recognizeend, each ignore region runs to the end of its file. That is harmless now, but later DDL could silently disappear from the generated model if scripts are combined. Confirm the configuredparseIgnoreCommentStoptoken, or align the markers.services/account-service/src/main/resources/db/migration/V160.1__start_session_operator_bundle_source_fence.sql#L12-L12: replace-- [jooq ignore end]with-- [jooq ignore stop].services/account-service/src/main/resources/db/migration/V160__start_session_world_original_attempt_evidence.sql#L73-L73: replace-- [jooq ignore end]with-- [jooq ignore stop].
- Rejected Trivial: both immutable published migrations end their ignored regions at EOF with no later DDL. Current jOOQ model includes V160 table and physical SQL proof passes; future DDL belongs new migrations. Changing published bytes is unjustified.
- Use the required entry format for the new observation.Minor
The new entry uses a
##heading and one prose paragraph. The file requires a dated bullet withContext,Observation, andExpected patternsub-bullets. Every earlier entry uses that form. Keep the reconsideration trigger as a sub-bullet if the entry stays as a retained blocker.📝 Proposed format
-## 2026-10-13 — Local PostgreSQL readiness does not prove mapped endpoint availability - -During the otherwise-required Account correction gate on 2026-10-12 UTC, two participation repository cases refused ... +- `2026-10-13`: Local PostgreSQL readiness does not prove mapped endpoint availability + - Context: during the Account correction gate on 2026-10-12 UTC, two participation repository cases refused the mapped `localhost:57828` endpoint before Flyway. + - Observation: the bounded capture tied the port to its PostgreSQL 18 container. Final TCP readiness and Testcontainers startup preceded the failures, and the recorded kill followed suite completion. This rules out a simple pre-readiness attempt, but it does not identify the refusal cause or the cleanup initiator. + - Expected pattern: preserve correlated port, readiness, case, and teardown evidence during required gates. Do not infer a source defect, early cleanup, or OOM from a generic refusal. Do not add speculative wait or configuration changes, and do not start a diagnostics-only rerun. Report passing subsets and missing full proof separately. Matching current-candidate CI remains a qualification path.As per coding guidelines: "Entry format: -
YYYY-MM-DD: short title / - Context / - Observation / - Expected pattern".- Accepted Minor: newest Gameplay observation violates dated-bullet Context/Observation/Expected-pattern format. Preserve all facts and prior entries; prepare formatting correction locally while Hosted is active.
- Check whether the new source-writer guard blocks exact acquisition retries.Major
This block adds a check to
account_control_ui_hold_required_sources(TEXT[]). The check raises55P03whenever any unsettled World participation shares a required source key.AccountStartSessionWorldParticipationAcquisitionService.acquiredocuments that an unknown commit is propagated "for a later retry with this same original request". The retry path callswithCurrentWorldReceivingParticipationCurrentness, which callsactors.withCurrentCommitted. SupposewithCurrentCommitted, or the Control-UI actor hold it runs, callsaccount_control_ui_hold_required_sources. In that case, every retry after the first committed participation fails at this guard beforecreateOrReadExactcan return the existing participation. The participation stays pending until World settles it.The same guard would also deny ISSUE, RECOVER, REDEEM, and
ReadRedeemedOperationProjectionfor the same actor and tenant sources while the participation is pending. That includes the Game Session read/pin continuation that ADR 0047 now allows.The question to resolve: does
AccountControlUiActorService.withCurrentCommitted(or its source-hold path) executeaccount_control_ui_hold_required_sources? If it does, exempt the exact participation owner's own receiving path, or restrict the guard to real source writers. Then add a physical retry case toAccountStartSessionWorldParticipationPostgresIntegrationTestthat callsacquiretwice with the same request.- Rejected Major hypothesis disproved: withCurrentCommitted uses locked source reads and SELECT FOR UPDATE, not the source-writer trigger/hold function. Physical World-currentness exact retry already returns the same pending participation; no guard exemption is needed.
Routed Findings
Route 1 · PR #3155 → Unassigned target OpenFinding summary unavailable
Route 2 · PR #3155 → PR #3183 Accepted/FixedFinding summary unavailable
Earlier routing and proof
- Earlier disposition: accepted and fixed
- Earlier proof: Published3183 ccf0528c352d6e57f790d6c3a0e007c23ddfeaa7 exact30 verified consumerpostimages: Core/Security600, Account1291+13PG, GS2136+45PG and4units; static/docs pass. Independent Account tuple retained and launchchecked; no activation.
Unlinked items
no items unlinked