Skip to content

fix(linux-session): replay a read the reconnect stopped, test a restart - #3564

Merged
datlechin merged 2 commits into
mainfrom
test/linux-db-restart
Oct 19, 2026
Merged

datlechin merged 2 commits into
mainfrom
test/linux-db-restart

Conversation

@datlechin

Copy link
Copy Markdown
Member

Why

Release criterion 7 needs a test that restarts the database and checks that reads replay and writes do not. Against a real restart, a read still running when the reconnect landed came back Cancelled: closing the replaced connection stopped it, and only a lost connection was replayed.

Change

  • A read stopped by the reconnect closing its connection counts as a lost connection and runs once more on the new one. A save still never runs again.
  • PostgresFixture::start_restartable picks the host port itself, since Docker maps a published port anew at each start; stop and start_again restart the server on it.
  • A session test restarts PostgreSQL mid-session: the in-flight read replays, the in-flight save does not and its row is absent, and the session comes back online with its data.

Verified

  • The restart test fails on main with Err(Driver(Cancelled)) and passes here; runner unit tests cover a read and a save.

@datlechin
datlechin merged commit 529f89f into main Oct 19, 2026
24 checks passed
@datlechin
datlechin deleted the test/linux-db-restart branch October 19, 2026 02:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant