Add postpone-cut-over-flag-file interactive command#1561
Merged
meiji163 merged 5 commits intogithub:masterfrom Jul 1, 2025
Merged
Add postpone-cut-over-flag-file interactive command#1561meiji163 merged 5 commits intogithub:masterfrom
meiji163 merged 5 commits intogithub:masterfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds support for the postpone-cut-over-flag-file interactive command, allowing users to postpone the cut-over phase by creating a flag file at runtime rather than on startup.
- Introduces
Server.createPostponeCutOverFlagFileand hooks it into the interactive command handler - Adds documentation for the new command in
interactive-commands.md - Provides unit tests for the flag-file creation logic in
server_test.go
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| go/logic/server.go | Added createPostponeCutOverFlagFile and interactive command handling for postponing cut-over |
| go/logic/server_test.go | Added tests covering successful creation and idempotence of the postpone-flag file |
| doc/interactive-commands.md | Documented the new postpone-cut-over-flag-file=<path> command |
Comments suppressed due to low confidence (1)
go/logic/server_test.go:72
- Consider adding a test case where
createPostponeCutOverFlagFileis called with a path in a non-existent directory to assert that an appropriate error is returned.
func TestServerCreatePostponeCutOverFlagFile(t *testing.T) {
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Contributor
Author
|
@meiji163 Thanks for updating the branch. |
meiji163
approved these changes
Jul 1, 2025
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.
A Pull Request should be associated with an Issue.
Related issue: #1560
Description
This PR enable specifying postpone-cut-over-flag-file via the interactive command.
This allows postponing the cut-over even after execution has started, eliminating the need to restart the process.
script/cibuildreturns with no formatting errors, build errors or unit test errors.Testing
After starting the gh-ost execution without
postpone-cut-over-flag-fileoption, a second session is launched to send thepostpone-cut-over-flag-filecommand.First session:
Details
Second session:
Details