Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IngressPerAppRequirer: retry when IP is not available #426

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

weiiwang01
Copy link
Contributor

Issue

We recently encountered a production failure where the ingress requirer temporarily failed to retrieve unit IP information from Juju. As a result, the IP field in the ingress per-app integration unit data bag was missing, causing the ingress provider to fail in generating ingress resources for the ingress requirer. The investigation revealed that the ingress charm library does not attempt to retry retrieving IP information from Juju after the initial failure, thereby preventing the charm from automatically recovering from this situation.

Solution

There are several potential solutions to address this issue. For instance, the charm library could listen to all events and update the integration data on every event, or the charm could defer the integration event when IP retrieval fails, allowing it to retry in the next event. The defer solution appears to require the least modification and is the least invasive option.

Context

Testing Instructions

Unit tests and scenario tests have been updated to validate this new behavior.

Upgrade Notes

Charms that invoke the provide_ingress_requirements method might encounter an exception when IP information is unavailable from Juju due to the current implementation. However, charms using the implicit ingress requirements provisioning will not experience any exceptions.

@weiiwang01 weiiwang01 requested a review from a team as a code owner November 25, 2024 06:57
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.

2 participants