Skip to content

[Feature] Manual Upgrade Mode #1918

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

Merged
merged 1 commit into from
Jul 1, 2025
Merged

Conversation

ajanikow
Copy link
Collaborator

No description provided.

@ajanikow ajanikow requested a review from Copilot June 25, 2025 09:48
@cla-bot cla-bot bot added the cla-signed label Jun 25, 2025
Copilot

This comment was marked as outdated.

@ajanikow ajanikow requested a review from Copilot June 25, 2025 16:03
Copilot

This comment was marked as outdated.

@ajanikow ajanikow requested a review from Copilot July 1, 2025 07:20
Copilot

This comment was marked as outdated.

@ajanikow ajanikow force-pushed the feature/manual_upgrade_mode branch from 42441d9 to 38acb7b Compare July 1, 2025 07:39
@ajanikow ajanikow requested a review from Copilot July 1, 2025 08:00
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR introduces a manual upgrade mode that lets users control upgrade timing via a Pod annotation. It updates plan building logic, API types/CRDs, documentation, and the changelog.

  • Add ManualUpgradeMode field and ConditionTypeUpgradeAllowed to control manual upgrade flow.
  • Extend plan builder to honor annotation-based upgrade permission.
  • Update CRDs, API types, and documentation with the new manual upgrade options.

Reviewed Changes

Copilot reviewed 14 out of 14 changed files in this pull request and generated no comments.

Show a summary per file
File Description
pkg/deployment/reconcile/plan_builder_rotate_upgrade.go Added logic for manual upgrade mode and new plan function
pkg/deployment/reconcile/plan_builder_high.go Hooked new manual-upgrade plan into high-level plan sequence
pkg/crd/crds/database-deployment.schema.generated.yaml Added manualUpgradeMode and manual enum to CRD schemas
pkg/apis/deployment/v2alpha1/zz_generated.deepcopy.go DeepCopy support for ManualUpgradeMode
pkg/apis/deployment/v2alpha1/server_group_spec_upgrade_mode.go Include manual in upgrade mode validation and defaults
pkg/apis/deployment/v2alpha1/server_group_spec.go API type and validation updates for ManualUpgradeMode
pkg/apis/deployment/v2alpha1/conditions.go Added ConditionTypeUpgradeAllowed
pkg/apis/deployment/v1/... (multiple files) Mirrored v2alpha1 changes in v1 API packages
pkg/apis/deployment/annotations.go Added allow-upgrade Pod annotation and updated copyright
docs/api/ArangoDeployment.V1.md Documented manualUpgradeMode across server groups
CHANGELOG.md Added entry for Manual Upgrade Mode feature
Comments suppressed due to low confidence (3)

pkg/deployment/reconcile/plan_builder_rotate_upgrade.go:295

  • [nitpick] The variable name 'dum' is not descriptive. Consider renaming it to something like 'defaultUpgradeMode' for clarity.
			dum := util.BoolSwitch(features.IsUpgradeIndexOrderIssueEnabled(group, d.upgradeDecision.FromVersion, d.upgradeDecision.ToVersion), api.ServerGroupUpgradeModeReplace, api.ServerGroupUpgradeModeInplace)

pkg/deployment/reconcile/plan_builder_rotate_upgrade.go:563

  • The new manual-upgrade annotation logic isn't covered by any unit tests. Please add tests for createMemberAllowUpgradeConditionPlan to verify annotation-based upgrade permission behaves as expected.
func (r *Reconciler) createMemberAllowUpgradeConditionPlan(ctx context.Context,

docs/api/ArangoDeployment.V1.md:237

  • The new Pod annotation upgrade.deployment.arangodb.com/allow isn’t mentioned in the API docs. Please add a section describing this annotation, its format, and its effect on manual upgrades.
UpgradeMode Defines the manually triggered upgrade mode for the Member

@ajanikow ajanikow merged commit 4aaeb60 into master Jul 1, 2025
3 checks passed
@ajanikow ajanikow deleted the feature/manual_upgrade_mode branch July 1, 2025 09:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants