nvazquez opened a new pull request, #9427:
URL: https://github.com/apache/cloudstack/pull/9427

   ### Description
   
   This PR adds a fix for an upgrade issue found from 4.17.2 to 4.19.1.
   
   The IDEMPOTENT_ADD_COLUMN procedure was not found and the upgrade has failed 
with the following error:
   ````
   2024-07-21 15:23:22,706 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:) -- 
Add type column to data_center table
   2024-07-21 15:23:22,706 DEBUG [c.c.u.d.ScriptRunner] (main:null) (logid:) 
CALL `cloud`.`IDEMPOTENT_ADD_COLUMN`('cloud.data_center', 'type', 'varchar(32) 
DEFAULT ''Core'' COMMENT ''the type of the zone'' ') 
   2024-07-21 15:23:22,717 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:) 
Error executing: CALL `cloud`.`IDEMPOTENT_ADD_COLUMN`('cloud.data_center', 
'type', 'varchar(32) DEFAULT ''Core'' COMMENT ''the type of the zone'' ') 
   2024-07-21 15:23:22,717 ERROR [c.c.u.d.ScriptRunner] (main:null) (logid:) 
java.sql.SQLSyntaxErrorException: PROCEDURE cloud.IDEMPOTENT_ADD_COLUMN does 
not exist
   2024-07-21 15:23:23,069 ERROR [c.c.u.DatabaseUpgradeChecker] (main:null) 
(logid:) Unable to execute upgrade script
   java.sql.SQLSyntaxErrorException: PROCEDURE cloud.IDEMPOTENT_ADD_COLUMN does 
not exist
           at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:185)
           at com.cloud.utils.db.ScriptRunner.runScript(ScriptRunner.java:87)
           at 
com.cloud.upgrade.DatabaseUpgradeChecker.runScript(DatabaseUpgradeChecker.java:236)
           at 
com.cloud.upgrade.DatabaseUpgradeChecker.upgrade(DatabaseUpgradeChecker.java:320)
           at 
com.cloud.upgrade.DatabaseUpgradeChecker.check(DatabaseUpgradeChecker.java:435)
           at 
org.apache.cloudstack.spring.lifecycle.CloudStackExtendedLifeCycle.checkIntegrity(CloudStackExtendedLifeCycle.java:64)
           at 
org.apache.cloudstack.spring.lifecycle.CloudStackExtendedLifeCycle.start(CloudStackExtendedLifeCycle.java:54)
           at 
org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:178)
   
   ````
   
   ### 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)
   - [ ] build/CI
   - [ ] test (unit or integration test code)
   
   ### 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?
   
   <!-- Please describe in detail how you tested your changes. -->
   <!-- Include details of your testing environment, and the tests you ran to 
-->
   
   #### How did you try to break this feature and the system with this change?
   
   <!-- see how your change affects other areas of the code, etc. -->
   
   
   <!-- Please read the 
[CONTRIBUTING](https://github.com/apache/cloudstack/blob/main/CONTRIBUTING.md) 
document -->
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to