-
Notifications
You must be signed in to change notification settings - Fork 11
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
[DPE-5591] Rework status handling #141
Open
Batalex
wants to merge
15
commits into
main
Choose a base branch
from
feat/dpe-5591-status
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Batalex
force-pushed
the
feat/dpe-5591-status
branch
from
October 8, 2024 13:49
4d0cf61
to
4a63963
Compare
Batalex
requested review from
marcoppenheimer and
deusebio
and removed request for
marcoppenheimer
October 15, 2024 11:25
Batalex
force-pushed
the
feat/dpe-5591-status
branch
from
October 31, 2024 11:52
1054264
to
c4b7b25
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes:
Changed the way we set the unit status. Now, the unit status is evaluated in a post event hook handler and then set once per charm instantiation.
I am pretty sure that the original issues come from rollingops setting the application status, whereas our event handlers only set the unit status. After a successful restart, the application status would be set to Active until a new event triggered the rollingsops libs. With these changes, the same method handles both the unit and the application status. The best thing, in my opinion, would be to avoid setting the app status everywhere (including the libs), but that's a discussion for another time.
Migrated all unit tests to scenario V7. I took this opportunity to properly patch sys calls triggering the auth desktop portal when running locally. Now we can run the tests without being interrupted.
Fixed an issue where we would silently ignore rebalance actions on non-leader units by moving the action event listener before the init early return
Pro tip: I recommend using the side-by-side display option for the units tests (instead of the default unified), I find it easier on the eyes to keep track of what changed regardless of the boilerplate.