many: restart snapd from daemon.Stop#16676
Draft
alfonsosanchezbeato wants to merge 2 commits intocanonical:masterfrom
Draft
many: restart snapd from daemon.Stop#16676alfonsosanchezbeato wants to merge 2 commits intocanonical:masterfrom
alfonsosanchezbeato wants to merge 2 commits intocanonical:masterfrom
Conversation
Move snapd service restart logic from AddSnapdSnapServices to daemon.Stop, calling it only when a daemon restart is explicitly requested. This ensures that most system resources are freed before another snapd instance starts, as we could have two for a short period of time. - Add Restart() function to wrappers package for restarting snapd - services Call wrappers.Restart() in daemon.Stop when restart is - requested Update tests to verify systemctl calls during daemon - restart Remove automatic service restart from AddSnapdSnapServices
|
Fri Feb 27 20:13:40 UTC 2026 Failures:Executing:
Restoring:
Skipped tests from snapd-testing-skip
|
… handling Remove the SnapdRestart interface and its implementations as it is not needed anymore (restart.Restart is now called by daemon.Stop). Update function signatures for AddSnapdSnapServices and GenerateSnapdWrappers to return only error instead of (SnapdRestart, error). Simplify related code that previously handled restart callbacks after symlink updates.
75c029a to
7619b7c
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #16676 +/- ##
==========================================
- Coverage 77.58% 77.52% -0.07%
==========================================
Files 1344 1355 +11
Lines 186593 186995 +402
Branches 2449 2449
==========================================
+ Hits 144769 144968 +199
- Misses 33068 33260 +192
- Partials 8756 8767 +11
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
pedronis
reviewed
Feb 27, 2026
| } | ||
| d.overlord.Stop() | ||
|
|
||
| if d.requestedRestart == restart.RestartDaemon { |
Contributor
There was a problem hiding this comment.
shouldn't this go after the if below?
This file contains hidden or 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
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.
Move snapd service restart logic from AddSnapdSnapServices to daemon.Stop,
calling it only when a daemon restart is explicitly requested. This ensures
that most system resources are freed before another snapd instance starts, as
we could have two for a short period of time.