Skip to content

Commit c63dbb8

Browse files
committed
db: Refactor new change in create-schema/premium to schema40-410.sql
- Move changes since 4.0 to schema upgrade path (schema40-410.sql) - Comment out some table names where we're trying to copy uuid from id, they don't exists - We don't run above step for tables which are newly created for 410 and don't exist in 4.0 for example autoscale related ones, code is commented and not removed - Drop indexes which are removed before dropping the column - Comment out insertion, as for default region we're inserting the same in code, in ConfigurationServerImpl:createDefaultRegion(), fix same in premium Testing; Deployed fresh 4.0 database, compiled and ran mgmt server. It did a smooth rolling upgrade from 4.0 to 4.1.0 with no database exceptions or any other db error. TODO: - 4.2.0 relates changes like ipv6 should go into its schema-410to420.sql Signed-off-by: Rohit Yadav <bhaisaab@apache.org>
1 parent 8094e93 commit c63dbb8

3 files changed

Lines changed: 288 additions & 338 deletions

File tree

setup/db/create-schema-premium.sql

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,6 @@ CREATE TABLE `cloud_usage`.`account` (
137137
`cleanup_needed` tinyint(1) NOT NULL default '0',
138138
`network_domain` varchar(100) COMMENT 'Network domain name of the Vms of the account',
139139
`default_zone_id` bigint unsigned,
140-
`region_id` int unsigned NOT NULL,
141140
CONSTRAINT `uc_account__uuid` UNIQUE (`uuid`),
142141
PRIMARY KEY (`id`)
143142
) ENGINE=InnoDB DEFAULT CHARSET=utf8;

0 commit comments

Comments
 (0)