Skip to content

[DPE-9555] fix(test): add explicit relation endpoints for GLAuth-PostgreSQL integration#1322

Merged
marceloneppel merged 1 commit into16/edgefrom
ldap-test-fix-16
Mar 4, 2026
Merged

[DPE-9555] fix(test): add explicit relation endpoints for GLAuth-PostgreSQL integration#1322
marceloneppel merged 1 commit into16/edgefrom
ldap-test-fix-16

Conversation

@marceloneppel
Copy link
Member

@marceloneppel marceloneppel commented Mar 3, 2026

Issue

The test_glauth_integration integration test fails across PRs with:

juju.errors.JujuAPIError: ambiguous relation: "glauth-k8s glauth-postgresql-k8s" could refer to
  "glauth-k8s:pg-database glauth-postgresql-k8s:database";
  "glauth-postgresql-k8s:ldap glauth-k8s:ldap";
  "glauth-postgresql-k8s:receive-ca-cert glauth-k8s:send-ca-cert"

The test deploys glauth-postgresql-k8s (the backing PostgreSQL for GLAuth) from the 14/stable channel. On March 2, 2026, postgresql-k8s rev 774 was published to 14/stable, which added ldap (requires, interface ldap) and receive-ca-cert (requires, interface certificate_transfer) endpoints. These new endpoints match glauth-k8s's existing ldap (provides) and send-ca-cert (provides) endpoints, creating 3 possible interface pairs between the two charms instead of the previous single one (pg-databasedatabase). This makes the unqualified add_relation("glauth-k8s", "glauth-postgresql-k8s") call ambiguous.

The previous 14/stable revision (rev 494, from February 2025) did not have ldap or receive-ca-cert endpoints, so the relation was unambiguous.

Solution

Specify explicit endpoint names (glauth-k8s:pg-database and glauth-postgresql-k8s:database) when adding the database relation between GLAuth and its backing PostgreSQL instance.

Checklist

  • I have added or updated any relevant documentation.
  • I have cleaned any remaining cloud resources from my accounts.

…gration

Signed-off-by: Marcelo Henrique Neppel <marcelo.neppel@canonical.com>
@github-actions github-actions bot added the Libraries: Out of sync The charm libs used are out-of-sync label Mar 3, 2026
@codecov
Copy link

codecov bot commented Mar 3, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 68.96%. Comparing base (180b37a) to head (6dc805a).
⚠️ Report is 1 commits behind head on 16/edge.

❌ Your project status has failed because the head coverage (68.96%) is below the target coverage (70.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files
@@           Coverage Diff            @@
##           16/edge    #1322   +/-   ##
========================================
  Coverage    68.96%   68.96%           
========================================
  Files           16       16           
  Lines         3809     3809           
  Branches       574      574           
========================================
  Hits          2627     2627           
  Misses         980      980           
  Partials       202      202           

☔ 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.

@marceloneppel marceloneppel added the bug Something isn't working as expected label Mar 3, 2026
@marceloneppel marceloneppel changed the title fix(test): add explicit relation endpoints for GLAuth-PostgreSQL integration [DPE-9555] fix(test): add explicit relation endpoints for GLAuth-PostgreSQL integration Mar 3, 2026
@marceloneppel marceloneppel marked this pull request as ready for review March 3, 2026 20:06
@marceloneppel marceloneppel requested a review from a team as a code owner March 3, 2026 20:06
@marceloneppel marceloneppel requested review from carlcsaposs-canonical, dragomirp, juju-charm-bot and taurus-forever and removed request for a team March 3, 2026 20:06
@marceloneppel marceloneppel merged commit ccb262c into 16/edge Mar 4, 2026
168 of 174 checks passed
@marceloneppel marceloneppel deleted the ldap-test-fix-16 branch March 4, 2026 11:31
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: Out of sync The charm libs used are out-of-sync

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants