From 0fc48cd211d79bf979839b2eca0b32a2641a5bc6 Mon Sep 17 00:00:00 2001 From: "j.w.jonkers" Date: Thu, 4 Jun 2026 19:38:26 +0200 Subject: [PATCH] assistant-api: restore V12 migration to its applied content assistant-api and assistant-api-ws were CrashLoopBackOff on: Flyway: Migration checksum mismatch for migration version 12 Applied to database : -1120901032 Resolved locally : -1416040883 The V12 file had its leading comment reworded after it was already applied to the production database (commit 9f17beb9). Flyway checksums the whole file, comments included, so the edit flipped the checksum and validation hard-fails on boot. The ALTER TABLE itself was never touched, so the live schema is correct; only the recorded checksum and the file diverged. This restores V12 to the byte-exact content that produced the applied checksum, so validation passes again with no database change. No flyway repair is used: repairing would bless the edited file, whereas the applied content is the source of truth and an applied migration must not be edited in the first place (a CI guard for that follows separately). --- .../migration/V12__workspace_agent_session_cli_session_id.sql | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/assistant-api/src/main/resources/db/migration/V12__workspace_agent_session_cli_session_id.sql b/services/assistant-api/src/main/resources/db/migration/V12__workspace_agent_session_cli_session_id.sql index 90e8a875..8a51cc93 100644 --- a/services/assistant-api/src/main/resources/db/migration/V12__workspace_agent_session_cli_session_id.sql +++ b/services/assistant-api/src/main/resources/db/migration/V12__workspace_agent_session_cli_session_id.sql @@ -1,5 +1,5 @@ --- Store the native CLI session id for observability and future explicit --- continuation flows. Nullable because: +-- Store the native CLI session id so a resume flag can be passed on +-- wake/re-attach without starting a fresh session. Nullable because: -- - SHELL sessions have no native CLI id -- - Codex session id discovery is async (captured after spawn) -- - Old rows have no id