Skip to content

E2E flakiness improvements - #3219

Merged
hughcapet merged 5 commits into
masterfrom
copilot/fix-end-2-end-tests
Nov 5, 2026
Merged

hughcapet merged 5 commits into
masterfrom
copilot/fix-end-2-end-tests

Conversation

Copilot AI commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

Problem description

The End-to-End tests were flaky because Kubernetes reconciliation and PostgreSQL major upgrades can take longer than fixed waits or the original polling window. Operator restarts could also race with pod replacement, causing setup to read an empty pod list.

Changes

  • Extend polling for PostgreSQL 14→15 and 15→16 version checks to allow up to 180 retries.
  • Poll for the successful major-upgrade annotation after each upgrade and verify it changes after the second upgrade.
  • Replace fixed sleeps in owner-reference tests with polling until references are added or removed, treating temporary - Kubernetes API errors during reconciliation as not-yet-ready.
  • During operator restarts, record the previous pod UID and wait for a different Running pod before continuing.

Co-authored-by: hughcapet <27892524+hughcapet@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix failing GitHub Actions job End-2-End tests Allow more time for E2E major-upgrade checks Nov 5, 2026
Copilot AI requested a review from hughcapet November 5, 2026 09:50
@hughcapet hughcapet added the minor label Nov 5, 2026
Co-authored-by: hughcapet <27892524+hughcapet@users.noreply.github.com>
@hughcapet hughcapet changed the title Allow more time for E2E major-upgrade checks E2E flakiness improvements Nov 5, 2026
Copilot stopped work on behalf of hughcapet due to an error November 5, 2026 11:26
Co-authored-by: hughcapet <27892524+hughcapet@users.noreply.github.com>
Co-authored-by: hughcapet <27892524+hughcapet@users.noreply.github.com>
@hughcapet

Copy link
Copy Markdown
Collaborator

@copilot update the PR description to include description of all changes

Copilot AI commented Nov 5, 2026

Copy link
Copy Markdown
Contributor Author

@copilot update the PR description to include description of all changes

I can’t directly edit PR metadata with the GitHub tools available here. Suggested updated PR description:

Problem description

The End-to-End tests were flaky because Kubernetes reconciliation and PostgreSQL major upgrades can take longer than fixed waits or the original polling window. Operator restarts could also race with pod replacement, causing setup to read an empty pod list.

Changes

  • Extend polling for PostgreSQL 14→15 and 15→16 version checks to allow up to 180 retries.
  • Poll for the successful major-upgrade annotation after each upgrade and verify it changes after the second upgrade.
  • Replace fixed sleeps in owner-reference tests with polling until references are added or removed, treating temporary Kubernetes API errors during reconciliation as not-yet-ready.
  • During operator restarts, record the previous pod UID and wait for a different Running pod before continuing.

@hughcapet
hughcapet marked this pull request as ready for review November 5, 2026 14:30
@FxKu FxKu added this to the 2.1.0 milestone Nov 5, 2026
@FxKu FxKu moved this to Good state for merge in Postgres Operator Nov 5, 2026
@hughcapet
hughcapet merged commit 592c336 into master Nov 5, 2026
16 checks passed
@hughcapet
hughcapet deleted the copilot/fix-end-2-end-tests branch November 5, 2026 15:42
@github-project-automation github-project-automation Bot moved this from Good state for merge to Done in Postgres Operator Nov 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

3 participants