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

Remove explicit copying of replace label between Service instances #1442

Conversation

rzetelskik
Copy link
Member

@rzetelskik rzetelskik commented Oct 3, 2023

Description of your changes: Currently the replace label is copied explicitly between Service instances. This can result in the replace label being carried over past the end of the replacement procedure in case the replace label is not removed from the original Service on time, which can in turn break the node, as observed in #1240. This PR removes the superfluous explicit copy of the replacement label. It's necessary in neither the old nor the new replacement procedure. In the old procedure, the label will be picked up from ScyllaCluster status, while the new procedure doesn't terminate services. This change should fix the issue for the new replacement procedure, as the replacement label will never be carried over to a new Service instance. Unfortunately, this PR doesn't fix the deprecated procedure.

Which issue is resolved by this Pull Request:
Resolves #1240

@rzetelskik rzetelskik added the kind/bug Categorizes issue or PR as related to a bug. label Oct 3, 2023
@scylla-operator-bot scylla-operator-bot bot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Oct 3, 2023
Copy link
Member

@tnozicka tnozicka left a comment

Choose a reason for hiding this comment

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

I am happy to get rid of this but given @zimnx has been around this area the most lately, I'd like him to sign the change.

/approve
/assign @zimnx

@scylla-operator-bot scylla-operator-bot bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Oct 3, 2023
@tnozicka
Copy link
Member

tnozicka commented Oct 3, 2023

/retest

@rzetelskik rzetelskik force-pushed the replace-remove-explicit-label-copy branch from 21ba9bd to d5da342 Compare October 3, 2023 13:37
@scylla-operator-bot scylla-operator-bot bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Oct 3, 2023
@rzetelskik rzetelskik force-pushed the replace-remove-explicit-label-copy branch from d5da342 to 8f53bc8 Compare October 3, 2023 13:41
@scylla-operator-bot scylla-operator-bot bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Oct 3, 2023
@rzetelskik
Copy link
Member Author

rzetelskik commented Oct 3, 2023

@zimnx the change required some adjustment to unit tests, please check whether the changes to the current behaviour are acceptable. I believe "new service with unsaved IP and existing replace address", "existing initial service" and "existing initial service with IP" don't really test any specific behaviour with these changes, so they might as well be dropped.

@rzetelskik rzetelskik force-pushed the replace-remove-explicit-label-copy branch 2 times, most recently from b8a84f9 to dbfde25 Compare October 3, 2023 13:58
@rzetelskik rzetelskik marked this pull request as draft October 3, 2023 14:01
@scylla-operator-bot scylla-operator-bot bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Oct 3, 2023
@rzetelskik rzetelskik force-pushed the replace-remove-explicit-label-copy branch from dbfde25 to 1215393 Compare October 3, 2023 15:23
@scylla-operator-bot scylla-operator-bot bot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/S Denotes a PR that changes 10-29 lines, ignoring generated files. labels Oct 3, 2023
@rzetelskik rzetelskik marked this pull request as ready for review October 3, 2023 15:30
@scylla-operator-bot scylla-operator-bot bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Oct 3, 2023
@rzetelskik rzetelskik force-pushed the replace-remove-explicit-label-copy branch from 1215393 to aa89840 Compare October 4, 2023 13:04
@rzetelskik rzetelskik force-pushed the replace-remove-explicit-label-copy branch from 6659ff5 to 3a37529 Compare October 4, 2023 14:34
Copy link
Collaborator

@zimnx zimnx left a comment

Choose a reason for hiding this comment

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

/lgtm

@scylla-operator-bot scylla-operator-bot bot added the lgtm Indicates that a PR is ready to be merged. label Oct 4, 2023
@scylla-operator-bot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: rzetelskik, tnozicka, zimnx

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@scylla-operator-bot scylla-operator-bot bot merged commit 639e18c into scylladb:master Oct 4, 2023
11 checks passed
@rzetelskik rzetelskik deleted the replace-remove-explicit-label-copy branch October 4, 2023 15:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/bug Categorizes issue or PR as related to a bug. lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

add node operation fails if a node with it's name was already replaced and decommissioned
3 participants