Skip to content

upgrade a backported patch#6728

Merged
shwstppr merged 1 commit intoapache:4.17from
shapeblue:addBackportedPatch
Sep 13, 2022
Merged

upgrade a backported patch#6728
shwstppr merged 1 commit intoapache:4.17from
shapeblue:addBackportedPatch

Conversation

@DaanHoogland
Copy link
Copy Markdown
Contributor

Description

This PR tries to fix a problem with a privately backported feature. The columns added for the feature are not added idem potent so people can not backport them. I propose that all DB alteration from here on in will be done with the IDEM_POTENT_...() set of stored procedures that we have to prevent these kind of issues for users.

So far this has only been done with one feature but I propose to regirously do this for all code.

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

Screenshots (if appropriate):

How Has This Been Tested?

@borisstoyanov
Copy link
Copy Markdown
Contributor

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@borisstoyanov a Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 4169

Copy link
Copy Markdown
Member

@yadvr yadvr left a comment

Choose a reason for hiding this comment

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

LGTM (but hey this only fixes if someone upgrades to 4.17.1.0 or 4.18.0.0++, it may break still for 4.17.0.1, 4.17.0.0 releases)

ALTER TABLE `cloud`.`event`
ADD COLUMN `resource_id` bigint unsigned COMMENT 'ID of the resource associated with the event' AFTER `domain_id`,
ADD COLUMN `resource_type` varchar(32) COMMENT 'Type of the resource associated with the event' AFTER `resource_id`;
CALL `cloud`.`IDEMPOTENT_ADD_COLUMN`('cloud.event','resource_id', 'bigint unsigned COMMENT "ID of the resource associated with the event" AFTER `domain_id`');
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

@DaanHoogland is this IDEMPOTENT_ADD_COLUMN method declared in this sql ?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

sure, but also it should already be present in the server. We have re-defined it in several upgrade steps.

@shwstppr
Copy link
Copy Markdown
Contributor

@blueorangutan test

@blueorangutan
Copy link
Copy Markdown

@shwstppr a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests

@codecov
Copy link
Copy Markdown

codecov bot commented Sep 12, 2022

Codecov Report

Merging #6728 (b899ab4) into 4.17 (d3bfdac) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##               4.17    #6728   +/-   ##
=========================================
  Coverage      5.88%    5.88%           
  Complexity     3927     3927           
=========================================
  Files          2451     2451           
  Lines        242338   242338           
  Branches      37923    37923           
=========================================
  Hits          14261    14261           
  Misses       226502   226502           
  Partials       1575     1575           

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Copy Markdown
Contributor

@borisstoyanov borisstoyanov left a comment

Choose a reason for hiding this comment

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

LGTM, just upgraded this manually and it's working fine

@DaanHoogland DaanHoogland marked this pull request as ready for review September 12, 2022 10:42
@blueorangutan
Copy link
Copy Markdown

Trillian test result (tid-4870)
Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
Total time taken: 39815 seconds
Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr6728-t4870-kvm-centos7.zip
Smoke tests completed. 101 look OK, 0 have errors
Only failed tests results shown below:

Test Result Time (s) Test File

@shwstppr shwstppr merged commit a45a4a5 into apache:4.17 Sep 13, 2022
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.

5 participants