Skip to content

Conversation

sinclert-canonical
Copy link
Contributor

This PR fixes a subtle bug, where upon cluster initialization, the primary instance was waiting on Patroni member_started, instead on the primary endpoint being available.

This approach falls short when performing further operations on the _start_primary method, as the default database cannot be connected to when trying to list users / groups (see failing CI job). The problem has been surfaced after correctly closing the connection on the PostgreSQL list_users charm lib method.

@sinclert-canonical sinclert-canonical added the bug Something isn't working as expected label Apr 8, 2025
Copy link

codecov bot commented Apr 8, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 72.54%. Comparing base (d35b18d) to head (693d97d).
Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #826   +/-   ##
=======================================
  Coverage   72.54%   72.54%           
=======================================
  Files          15       15           
  Lines        3893     3893           
  Branches      589      589           
=======================================
  Hits         2824     2824           
  Misses        885      885           
  Partials      184      184           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@sinclert-canonical sinclert-canonical force-pushed the sinclert/fix-cluster-initialize branch from 4a42e74 to f76f677 Compare April 8, 2025 10:14
@sinclert-canonical
Copy link
Contributor Author

Subordinate charm tests will remain failing until we fix the PostgreSQL vs UbuntuPro base desync.

Feel free to ignore.

@sinclert-canonical sinclert-canonical marked this pull request as ready for review April 8, 2025 10:44
@sinclert-canonical
Copy link
Contributor Author

Closing PR. Alternative fix proposed in PostgreSQL charm lib (see PR)

@sinclert-canonical sinclert-canonical deleted the sinclert/fix-cluster-initialize branch April 9, 2025 14:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working as expected Libraries: OK

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant