You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by GitBox <gi...@apache.org> on 2022/01/31 08:57:38 UTC

[GitHub] [cloudstack] sureshanaparti opened a new pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

sureshanaparti opened a new pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911


   ### Description
   
   This PR improves the guest OS hypervisor mappings addition on upgrade. Also, removes the hardcoded guest os ids 305 - 329 in upgrade path 4.14.0 to 4.15.0, and 330 - 349 in upgrade path 4.15.0.0 to 4.15.1.0.
   
   Fixes #5685
   
   <!--- Describe your changes in DETAIL - And how has behaviour functionally changed. -->
   
   <!-- For new features, provide link to FS, dev ML discussion etc. -->
   <!-- In case of bug fix, the expected and actual behaviours, steps to reproduce. -->
   
   <!-- When "Fixes: #<id>" is specified, the issue/PR will automatically be closed when this PR gets merged -->
   <!-- For addressing multiple issues/PRs, use multiple "Fixes: #<id>" -->
   <!-- Fixes: # -->
   
   <!--- ********************************************************************************* -->
   <!--- NOTE: AUTOMATATION USES THE DESCRIPTIONS TO SET LABELS AND PRODUCE DOCUMENTATION. -->
   <!--- PLEASE PUT AN 'X' in only **ONE** box -->
   <!--- ********************************************************************************* -->
   
   ### Types of changes
   
   - [ ] Breaking change (fix or feature that would cause existing functionality to change)
   - [ ] New feature (non-breaking change which adds functionality)
   - [x] Bug fix (non-breaking change which fixes an issue)
   - [x] 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
   - [x] 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 -->
   <!-- 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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1025769816


   @sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032435357


   @sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r795461422



##########
File path: engine/schema/src/main/java/com/cloud/upgrade/dao/Upgrade41520to41600.java
##########
@@ -71,6 +74,12 @@ public boolean supportsRollingUpgrade() {
     public void performDataMigration(Connection conn) {
         generateUuidForExistingSshKeyPairs(conn);
         populateAnnotationPermissions(conn);
+        correctGuestOsIdsInHypervisorMapping(conn);
+    }
+
+    private void correctGuestOsIdsInHypervisorMapping(final Connection conn) {
+        LOG.debug("Correcting guest OS ids in hypervisor mappings");
+        guestOsMapper.updateGuestOsIdInHypervisorMapping(conn, 10, "Ubuntu 20.04 LTS", new Ternary<String, String, String>("Xenserver", "8.2.0", "Ubuntu Focal Fossa 20.04"));

Review comment:
       This would fix the incorrect guest os mapping in 4.15.0 to 4.15.1 schema, when upgrading to 4.16.0 from existing 4.15.2 env.
   
   https://github.com/apache/cloudstack/blob/571339f8724fc70c472f55f254125f0c6070d5de/engine/schema/src/main/resources/META-INF/db/schema-41500to41510.sql#L55-L57




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032319324


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032371247


   @sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032352345


   Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2512


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032422675


   Packaging result: :heavy_multiplication_x: el7 :heavy_multiplication_x: el8 :heavy_multiplication_x: debian :heavy_multiplication_x: suse15. SL-JID 2515


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032319690


   @sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1025769018


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1026787688


   > LGTM, @sureshanaparti can you see what's wrong with the test failures
   
   which test failures @borisstoyanov


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r795460744



##########
File path: engine/schema/src/main/java/com/cloud/upgrade/dao/Upgrade41510to41520.java
##########
@@ -51,6 +58,12 @@ public boolean supportsRollingUpgrade() {
 
     @Override
     public void performDataMigration(Connection conn) {
+        correctGuestOsIdsInHypervisorMapping(conn);
+    }
+
+    private void correctGuestOsIdsInHypervisorMapping(final Connection conn) {
+        LOG.debug("Correcting guest OS ids in hypervisor mappings");
+        guestOsMapper.updateGuestOsIdInHypervisorMapping(conn, 10, "Ubuntu 20.04 LTS", new Ternary<String, String, String>("Xenserver", "8.2.0", "Ubuntu Focal Fossa 20.04"));

Review comment:
       This would fix the incorrect guest os mapping in 4.15.0 to 4.15.1 schema, when upgrading to 4.15.2.
   
   https://github.com/apache/cloudstack/blob/571339f8724fc70c472f55f254125f0c6070d5de/engine/schema/src/main/resources/META-INF/db/schema-41500to41510.sql#L55-L57




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1025600584


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


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r795539108



##########
File path: engine/schema/src/main/java/com/cloud/upgrade/GuestOsMapper.java
##########
@@ -0,0 +1,193 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+package com.cloud.upgrade;
+
+import org.apache.commons.collections.CollectionUtils;
+import org.apache.log4j.Logger;
+
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.util.List;
+
+import com.cloud.utils.Ternary;
+
+public class GuestOsMapper {
+
+    final static Logger LOG = Logger.getLogger(GuestOsMapper.class);
+
+    private static final String selectGuestOsSql =
+            "SELECT id FROM `cloud`.`guest_os` WHERE category_id = ? AND display_name = ? AND is_user_defined = 0 AND removed IS NULL ORDER BY created DESC";
+    private static final String insertGuestOsSql =
+            "INSERT INTO `cloud`.`guest_os` (uuid, category_id, display_name, created) VALUES (UUID(), ?, ?, now())";
+    private static final String selectGuestOsHypervisorSql =
+            "SELECT guest_os_id FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type = ? AND hypervisor_version = ? AND guest_os_name = ? AND is_user_defined = 0 AND removed IS NULL ORDER BY created DESC";
+    private static final String insertGuestOsHypervisorSql =
+            "INSERT INTO `cloud`.`guest_os_hypervisor` (uuid, hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created) VALUES (UUID(), ?, ?, ?, ?, now())";
+    private static final String updateGuestOsSql =
+            "UPDATE `cloud`.`guest_os` SET display_name = ? WHERE id = ?";

Review comment:
       is the `display_name` the only field we'd want to update?

##########
File path: engine/schema/src/main/resources/META-INF/db/schema-41500to41510.sql
##########
@@ -18,117 +18,20 @@
 --;
 -- Schema upgrade from 4.15.0.0 to 4.15.1.0
 --;
--- Correct guest OS names
-UPDATE `cloud`.`guest_os` SET display_name='Fedora Linux (32 bit)' WHERE id=320;
-UPDATE `cloud`.`guest_os` SET display_name='Mandriva Linux (32 bit)' WHERE id=323;
-UPDATE `cloud`.`guest_os` SET display_name='OpenSUSE Linux (32 bit)' WHERE id=327;
-
--- Add support for SUSE Linux Enterprise Desktop 12 SP3 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (330, UUID(), 5, 'SUSE Linux Enterprise Desktop 12 SP3 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise Desktop 12 SP3 (64-bit)', 330, now(), 0);
--- Add support for SUSE Linux Enterprise Desktop 12 SP4 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (331, UUID(), 5, 'SUSE Linux Enterprise Desktop 12 SP4 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise Desktop 12 SP4 (64-bit)', 331, now(), 0);
--- Add support for SUSE Linux Enterprise Server 12 SP4 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (332, UUID(), 5, 'SUSE Linux Enterprise Server 12 SP4 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise Server 12 SP4 (64-bit)', 332, now(), 0);
--- Add support for Scientific Linux 7 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (333, UUID(), 9, 'Scientific Linux 7', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'Scientific Linux 7', 333, now(), 0);
--- Add support for NeoKylin Linux Server 7 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (334, UUID(), 9, 'NeoKylin Linux Server 7', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'NeoKylin Linux Server 7', 332, now(), 0);
--- Add support CentOS 8 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'CentOS 8', 297, now(), 0);
--- Add support for Debian Buster 10 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'Debian Buster 10', 292, now(), 0);
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'Debian Buster 10', 293, now(), 0);
--- Add support for SUSE Linux Enterprise 15 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise 15 (64-bit)', 291, now(), 0);
 
 -- Add XenServer 8.2.0 hypervisor capabilities
 INSERT IGNORE INTO `cloud`.`hypervisor_capabilities`(uuid, hypervisor_type, hypervisor_version, max_guests_limit, max_data_volumes_limit, max_hosts_per_cluster, storage_motion_supported) values (UUID(), 'XenServer', '8.2.0', 1000, 253, 64, 1);
 
 -- Copy XenServer 8.1.0 hypervisor guest OS mappings to XenServer 8.2.0
 INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'Xenserver', '8.2.0', guest_os_name, guest_os_id, utc_timestamp(), 0 FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='Xenserver' AND hypervisor_version='8.1.0';
 
--- Add support for Ubuntu Focal Fossa 20.04 for Xenserver 8.2.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (335, UUID(), 10, 'Ubuntu 20.04 LTS', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.2.0', 'Ubuntu Focal Fossa 20.04', 330, now(), 0);
-
-ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `ike_version` varchar(5) NOT NULL DEFAULT 'ike' COMMENT 'one of ike, ikev1, ikev2';
-ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `split_connections` int(1) NOT NULL DEFAULT 0;
-
 -- Add support for VMware 7.0
 INSERT IGNORE INTO `cloud`.`hypervisor_capabilities` (uuid, hypervisor_type, hypervisor_version, max_guests_limit, security_group_enabled, max_data_volumes_limit, max_hosts_per_cluster, storage_motion_supported, vm_snapshot_enabled) values (UUID(), 'VMware', '7.0', 1024, 0, 59, 64, 1, 1);
 INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'VMware', '7.0', guest_os_name, guest_os_id, utc_timestamp(), 0  FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='VMware' AND hypervisor_version='6.7';
 
--- Add support for darwin19_64Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (336, UUID(), 7, 'macOS 10.15 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'darwin19_64Guest', 336, now(), 0);
-
--- Add support for debian11_64Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (337, UUID(), 2, 'Debian GNU/Linux 11 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'debian11_64Guest', 337, now(), 0);
-
--- Add support for debian11Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (338, UUID(), 2, 'Debian GNU/Linux 11 (32-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'debian11Guest', 338, now(), 0);
-
--- Add support for windows2019srv_64Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'windows2019srv_64Guest', 276, now(), 0);
-
-
 -- Add support for VMware 7.0.1.0
 INSERT IGNORE INTO `cloud`.`hypervisor_capabilities` (uuid, hypervisor_type, hypervisor_version, max_guests_limit, security_group_enabled, max_data_volumes_limit, max_hosts_per_cluster, storage_motion_supported, vm_snapshot_enabled) values (UUID(), 'VMware', '7.0.1.0', 1024, 0, 59, 64, 1, 1);
 INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'VMware', '7.0.1.0', guest_os_name, guest_os_id, utc_timestamp(), 0  FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='VMware' AND hypervisor_version='7.0';
 
--- Add support for amazonlinux3_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (339, UUID(), 7, 'Amazon Linux 3 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'amazonlinux3_64Guest', 339, now(), 0);
-
--- Add support for asianux9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (340, UUID(), 7, 'Asianux Server 9 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'asianux9_64Guest', 340, now(), 0);
-
--- Add support for centos9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (341, UUID(), 1, 'CentOS 9', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'centos9_64Guest', 341, now(), 0);
-
--- Add support for darwin20_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (342, UUID(), 7, 'macOS 11 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'darwin20_64Guest', 342, now(), 0);
-
--- Add support for darwin21_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'darwin21_64Guest', 342, now(), 0);
-
--- Add support for freebsd13_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (343, UUID(), 9, 'FreeBSD 13 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'freebsd13_64Guest', 343, now(), 0);
-
--- Add support for freebsd13Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (344, UUID(), 9, 'FreeBSD 13 (32-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'freebsd13Guest', 344, now(), 0);
-
--- Add support for oracleLinux9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (345, UUID(), 3, 'Oracle Linux 9', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'oracleLinux9_64Guest', 345, now(), 0);
-
--- Add support for other5xLinux64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (346, UUID(), 2, 'Linux 5.x Kernel (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'other5xLinux64Guest', 346, now(), 0);
-
--- Add support for other5xLinuxGuest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (347, UUID(), 2, 'Linux 5.x Kernel (32-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'other5xLinuxGuest', 347, now(), 0);
-
--- Add support for rhel9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (348, UUID(), 4, 'Red Hat Enterprise Linux 9.0', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'rhel9_64Guest', 348, now(), 0);
-
--- Add support for sles16_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (349, UUID(), 5, 'SUSE Linux Enterprise Server 16 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'sles16_64Guest', 349, now(), 0);
-
--- Add support for windows2019srvNext_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'windows2019srvNext_64Guest', 276, now(), 0);
+ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `ike_version` varchar(5) NOT NULL DEFAULT 'ike' COMMENT 'one of ike, ikev1, ikev2';
+ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `split_connections` int(1) NOT NULL DEFAULT 0;

Review comment:
       are these two lines related to this change?




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032543988


   Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2524


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1033177567


   <b>Trillian test result (tid-3236)</b>
   Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
   Total time taken: 35289 seconds
   Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5911-t3236-kvm-centos7.zip
   Smoke tests completed. 92 look OK, 0 have errors
   Only failed tests results shown below:
   
   
   Test | Result | Time (s) | Test File
   --- | --- | --- | ---
   


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r802757838



##########
File path: api/src/main/java/com/cloud/storage/GuestOS.java
##########
@@ -33,5 +33,5 @@
 
     Date getRemoved();
 
-    boolean isUserDefined();
+    boolean getIsUserDefined();

Review comment:
       field name has to be `<property-name>`, not `is`+`<property-name>`




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r803669425



##########
File path: api/src/main/java/com/cloud/storage/GuestOS.java
##########
@@ -33,5 +33,5 @@
 
     Date getRemoved();
 
-    boolean isUserDefined();
+    boolean getIsUserDefined();

Review comment:
       ok, this is bad technmical debt, but for the fix now, ok, you convinced me (off-line)

##########
File path: api/src/main/java/com/cloud/storage/GuestOS.java
##########
@@ -33,5 +33,5 @@
 
     Date getRemoved();
 
-    boolean isUserDefined();
+    boolean getIsUserDefined();

Review comment:
       ok, this is bad technical debt, but for the fix now, ok, you convinced me (off-line)




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032484061


   Packaging result: :heavy_multiplication_x: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2520


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti removed a comment on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti removed a comment on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032222888


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032619229


   @blueorangutan test keepEnv


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti removed a comment on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti removed a comment on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032280728


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1025600248


   @blueorangutan test keepEnv


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r795469259



##########
File path: engine/schema/src/main/java/com/cloud/upgrade/dao/Upgrade41500to41510.java
##########
@@ -235,6 +242,138 @@ public void updateSystemVmTemplates(final Connection conn) {
         LOG.debug("Updating System Vm Template IDs Complete");
     }
 
+    private void correctGuestOsNames(final Connection conn) {
+        guestOsMapper.updateGuestOsName(conn, 7, "Fedora Linux", "Fedora Linux (32 bit)");
+        guestOsMapper.updateGuestOsName(conn, 7, "Mandriva Linux", "Mandriva Linux (32 bit)");
+
+        Ternary<String, String, String> mapping = new Ternary<String, String, String>("VMware", "6.7.3", "opensuseGuest");
+        guestOsMapper.updateGuestOsNameFromMapping(conn, "OpenSUSE Linux (32 bit)", mapping);
+    }
+
+    private void updateGuestOsMappings(final Connection conn) {
+        LOG.debug("Updating guest OS mappings");
+
+        // Add support for SUSE Linux Enterprise Desktop 12 SP3 (64-bit) for Xenserver 8.1.0
+        List<Ternary<String, String, String>> mappings = new ArrayList<Ternary<String, String, String>>();
+        mappings.add(new Ternary<String, String, String>("Xenserver", "8.1.0", "SUSE Linux Enterprise Desktop 12 SP3 (64-bit)"));
+        guestOsMapper.addGuestOsAndHypervisorMappings (conn, 5, "SUSE Linux Enterprise Desktop 12 SP3 (64-bit)", mappings);
+        mappings.clear();
+
+        // Add support for SUSE Linux Enterprise Desktop 12 SP4 (64-bit) for Xenserver 8.1.0
+        mappings.add(new Ternary<String, String, String>("Xenserver", "8.1.0", "SUSE Linux Enterprise Desktop 12 SP4 (64-bit)"));
+        guestOsMapper.addGuestOsAndHypervisorMappings (conn, 5, "SUSE Linux Enterprise Desktop 12 SP4 (64-bit)", mappings);
+        mappings.clear();
+
+        // Add support for SUSE Linux Enterprise Server 12 SP4 (64-bit) for Xenserver 8.1.0
+        mappings.add(new Ternary<String, String, String>("Xenserver", "8.1.0", "SUSE Linux Enterprise Server 12 SP4 (64-bit)"));
+        mappings.add(new Ternary<String, String, String>("Xenserver", "8.1.0", "NeoKylin Linux Server 7"));
+        guestOsMapper.addGuestOsAndHypervisorMappings(conn, 5, "SUSE Linux Enterprise Server 12 SP4 (64-bit)", mappings);
+        mappings.clear();
+
+        // Add support for Scientific Linux 7 for Xenserver 8.1.0
+        mappings.add(new Ternary<String, String, String>("Xenserver", "8.1.0", "Scientific Linux 7"));
+        guestOsMapper.addGuestOsAndHypervisorMappings (conn, 9, "Scientific Linux 7", mappings);
+        mappings.clear();
+
+        // Add support for NeoKylin Linux Server 7 for Xenserver 8.1.0
+        guestOsMapper.addGuestOsAndHypervisorMappings(conn, 9, "NeoKylin Linux Server 7", mappings); //334
+        mappings.clear();
+
+        // Pass Guest OS Ids to update pre-4.14 mappings
+        // Add support CentOS 8 for Xenserver 8.1.0

Review comment:
       Please note, the hypervisor mapping for the guest OSes added pre-4.14 (with hardcoded ids < 305), are updated using the same ids.




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1029856884


   @rohityadavcloud I think we will have to use this utility from here on in always. same for the annotations utility.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rohityadavcloud commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
rohityadavcloud commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1029765547


   @sureshanaparti it appears this fixes only for specific upgrade paths, while it may fix the mapping for an existing env, say in future the mapping issue happens again - then we would need to use the utility again in the upgrade path?


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032261666


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


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032225142


   Packaging result: :heavy_multiplication_x: el7 :heavy_multiplication_x: el8 :heavy_multiplication_x: debian :heavy_multiplication_x: suse15. SL-JID 2506


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032227818


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032270770


   <b>Trillian Build Failed (tid-3221)<b/>


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r795466115



##########
File path: engine/schema/src/main/java/com/cloud/upgrade/dao/Upgrade41500to41510.java
##########
@@ -235,6 +242,138 @@ public void updateSystemVmTemplates(final Connection conn) {
         LOG.debug("Updating System Vm Template IDs Complete");
     }
 
+    private void correctGuestOsNames(final Connection conn) {

Review comment:
       This corrects the guest os names added in 4.14.0 to 4.15.0 schema.
   
   https://github.com/apache/cloudstack/blob/571339f8724fc70c472f55f254125f0c6070d5de/engine/schema/src/main/resources/META-INF/db/schema-41400to41500.sql#L729
   
   https://github.com/apache/cloudstack/blob/571339f8724fc70c472f55f254125f0c6070d5de/engine/schema/src/main/resources/META-INF/db/schema-41400to41500.sql#L739
   
   https://github.com/apache/cloudstack/blob/571339f8724fc70c472f55f254125f0c6070d5de/engine/schema/src/main/resources/META-INF/db/schema-41400to41500.sql#L805-L807
   
   https://github.com/apache/cloudstack/blob/571339f8724fc70c472f55f254125f0c6070d5de/engine/schema/src/main/resources/META-INF/db/schema-41500to41510.sql#L21-L24




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1025512577


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] weizhouapache commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
weizhouapache commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r795553306



##########
File path: engine/schema/src/main/resources/META-INF/db/schema-41500to41510.sql
##########
@@ -18,117 +18,20 @@
 --;
 -- Schema upgrade from 4.15.0.0 to 4.15.1.0
 --;
--- Correct guest OS names
-UPDATE `cloud`.`guest_os` SET display_name='Fedora Linux (32 bit)' WHERE id=320;
-UPDATE `cloud`.`guest_os` SET display_name='Mandriva Linux (32 bit)' WHERE id=323;
-UPDATE `cloud`.`guest_os` SET display_name='OpenSUSE Linux (32 bit)' WHERE id=327;
-
--- Add support for SUSE Linux Enterprise Desktop 12 SP3 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (330, UUID(), 5, 'SUSE Linux Enterprise Desktop 12 SP3 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise Desktop 12 SP3 (64-bit)', 330, now(), 0);
--- Add support for SUSE Linux Enterprise Desktop 12 SP4 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (331, UUID(), 5, 'SUSE Linux Enterprise Desktop 12 SP4 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise Desktop 12 SP4 (64-bit)', 331, now(), 0);
--- Add support for SUSE Linux Enterprise Server 12 SP4 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (332, UUID(), 5, 'SUSE Linux Enterprise Server 12 SP4 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise Server 12 SP4 (64-bit)', 332, now(), 0);
--- Add support for Scientific Linux 7 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (333, UUID(), 9, 'Scientific Linux 7', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'Scientific Linux 7', 333, now(), 0);
--- Add support for NeoKylin Linux Server 7 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (334, UUID(), 9, 'NeoKylin Linux Server 7', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'NeoKylin Linux Server 7', 332, now(), 0);
--- Add support CentOS 8 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'CentOS 8', 297, now(), 0);
--- Add support for Debian Buster 10 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'Debian Buster 10', 292, now(), 0);
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'Debian Buster 10', 293, now(), 0);
--- Add support for SUSE Linux Enterprise 15 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise 15 (64-bit)', 291, now(), 0);
 
 -- Add XenServer 8.2.0 hypervisor capabilities
 INSERT IGNORE INTO `cloud`.`hypervisor_capabilities`(uuid, hypervisor_type, hypervisor_version, max_guests_limit, max_data_volumes_limit, max_hosts_per_cluster, storage_motion_supported) values (UUID(), 'XenServer', '8.2.0', 1000, 253, 64, 1);
 
 -- Copy XenServer 8.1.0 hypervisor guest OS mappings to XenServer 8.2.0
 INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'Xenserver', '8.2.0', guest_os_name, guest_os_id, utc_timestamp(), 0 FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='Xenserver' AND hypervisor_version='8.1.0';
 
--- Add support for Ubuntu Focal Fossa 20.04 for Xenserver 8.2.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (335, UUID(), 10, 'Ubuntu 20.04 LTS', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.2.0', 'Ubuntu Focal Fossa 20.04', 330, now(), 0);
-
-ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `ike_version` varchar(5) NOT NULL DEFAULT 'ike' COMMENT 'one of ike, ikev1, ikev2';
-ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `split_connections` int(1) NOT NULL DEFAULT 0;
-
 -- Add support for VMware 7.0
 INSERT IGNORE INTO `cloud`.`hypervisor_capabilities` (uuid, hypervisor_type, hypervisor_version, max_guests_limit, security_group_enabled, max_data_volumes_limit, max_hosts_per_cluster, storage_motion_supported, vm_snapshot_enabled) values (UUID(), 'VMware', '7.0', 1024, 0, 59, 64, 1, 1);
 INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'VMware', '7.0', guest_os_name, guest_os_id, utc_timestamp(), 0  FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='VMware' AND hypervisor_version='6.7';
 
--- Add support for darwin19_64Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (336, UUID(), 7, 'macOS 10.15 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'darwin19_64Guest', 336, now(), 0);
-
--- Add support for debian11_64Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (337, UUID(), 2, 'Debian GNU/Linux 11 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'debian11_64Guest', 337, now(), 0);
-
--- Add support for debian11Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (338, UUID(), 2, 'Debian GNU/Linux 11 (32-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'debian11Guest', 338, now(), 0);
-
--- Add support for windows2019srv_64Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'windows2019srv_64Guest', 276, now(), 0);
-
-
 -- Add support for VMware 7.0.1.0
 INSERT IGNORE INTO `cloud`.`hypervisor_capabilities` (uuid, hypervisor_type, hypervisor_version, max_guests_limit, security_group_enabled, max_data_volumes_limit, max_hosts_per_cluster, storage_motion_supported, vm_snapshot_enabled) values (UUID(), 'VMware', '7.0.1.0', 1024, 0, 59, 64, 1, 1);
 INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'VMware', '7.0.1.0', guest_os_name, guest_os_id, utc_timestamp(), 0  FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='VMware' AND hypervisor_version='7.0';
 
--- Add support for amazonlinux3_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (339, UUID(), 7, 'Amazon Linux 3 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'amazonlinux3_64Guest', 339, now(), 0);
-
--- Add support for asianux9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (340, UUID(), 7, 'Asianux Server 9 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'asianux9_64Guest', 340, now(), 0);
-
--- Add support for centos9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (341, UUID(), 1, 'CentOS 9', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'centos9_64Guest', 341, now(), 0);
-
--- Add support for darwin20_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (342, UUID(), 7, 'macOS 11 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'darwin20_64Guest', 342, now(), 0);
-
--- Add support for darwin21_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'darwin21_64Guest', 342, now(), 0);
-
--- Add support for freebsd13_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (343, UUID(), 9, 'FreeBSD 13 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'freebsd13_64Guest', 343, now(), 0);
-
--- Add support for freebsd13Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (344, UUID(), 9, 'FreeBSD 13 (32-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'freebsd13Guest', 344, now(), 0);
-
--- Add support for oracleLinux9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (345, UUID(), 3, 'Oracle Linux 9', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'oracleLinux9_64Guest', 345, now(), 0);
-
--- Add support for other5xLinux64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (346, UUID(), 2, 'Linux 5.x Kernel (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'other5xLinux64Guest', 346, now(), 0);
-
--- Add support for other5xLinuxGuest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (347, UUID(), 2, 'Linux 5.x Kernel (32-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'other5xLinuxGuest', 347, now(), 0);
-
--- Add support for rhel9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (348, UUID(), 4, 'Red Hat Enterprise Linux 9.0', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'rhel9_64Guest', 348, now(), 0);
-
--- Add support for sles16_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (349, UUID(), 5, 'SUSE Linux Enterprise Server 16 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'sles16_64Guest', 349, now(), 0);
-
--- Add support for windows2019srvNext_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'windows2019srvNext_64Guest', 276, now(), 0);
+ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `ike_version` varchar(5) NOT NULL DEFAULT 'ike' COMMENT 'one of ike, ikev1, ikev2';
+ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `split_connections` int(1) NOT NULL DEFAULT 0;

Review comment:
       4.15.1.0 already contains these two lines. this PR just moves the lines to the end of the sql file.
   it should be ok.




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] rohityadavcloud commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
rohityadavcloud commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r799262441



##########
File path: engine/schema/src/main/java/com/cloud/upgrade/GuestOsMapper.java
##########
@@ -0,0 +1,193 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+package com.cloud.upgrade;
+
+import org.apache.commons.collections.CollectionUtils;
+import org.apache.log4j.Logger;
+
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.util.List;
+
+import com.cloud.utils.Ternary;
+
+public class GuestOsMapper {
+
+    final static Logger LOG = Logger.getLogger(GuestOsMapper.class);
+
+    private static final String selectGuestOsSql =

Review comment:
       @sureshanaparti could we use Daos instead of manually created raw sql command?

##########
File path: engine/schema/src/main/java/com/cloud/upgrade/GuestOsMapper.java
##########
@@ -0,0 +1,193 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+package com.cloud.upgrade;
+
+import org.apache.commons.collections.CollectionUtils;
+import org.apache.log4j.Logger;
+
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.util.List;
+
+import com.cloud.utils.Ternary;
+
+public class GuestOsMapper {
+
+    final static Logger LOG = Logger.getLogger(GuestOsMapper.class);
+
+    private static final String selectGuestOsSql =

Review comment:
       @sureshanaparti could we use Daos instead of manually created raw sql statements?




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r795558234



##########
File path: engine/schema/src/main/java/com/cloud/upgrade/GuestOsMapper.java
##########
@@ -0,0 +1,193 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements.  See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership.  The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License.  You may obtain a copy of the License at
+//
+//   http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied.  See the License for the
+// specific language governing permissions and limitations
+// under the License.
+package com.cloud.upgrade;
+
+import org.apache.commons.collections.CollectionUtils;
+import org.apache.log4j.Logger;
+
+import java.sql.Connection;
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+import java.sql.SQLException;
+import java.util.List;
+
+import com.cloud.utils.Ternary;
+
+public class GuestOsMapper {
+
+    final static Logger LOG = Logger.getLogger(GuestOsMapper.class);
+
+    private static final String selectGuestOsSql =
+            "SELECT id FROM `cloud`.`guest_os` WHERE category_id = ? AND display_name = ? AND is_user_defined = 0 AND removed IS NULL ORDER BY created DESC";
+    private static final String insertGuestOsSql =
+            "INSERT INTO `cloud`.`guest_os` (uuid, category_id, display_name, created) VALUES (UUID(), ?, ?, now())";
+    private static final String selectGuestOsHypervisorSql =
+            "SELECT guest_os_id FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type = ? AND hypervisor_version = ? AND guest_os_name = ? AND is_user_defined = 0 AND removed IS NULL ORDER BY created DESC";
+    private static final String insertGuestOsHypervisorSql =
+            "INSERT INTO `cloud`.`guest_os_hypervisor` (uuid, hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created) VALUES (UUID(), ?, ?, ?, ?, now())";
+    private static final String updateGuestOsSql =
+            "UPDATE `cloud`.`guest_os` SET display_name = ? WHERE id = ?";

Review comment:
       > is the `display_name` the only field we'd want to update?
   
   yes @DaanHoogland 




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1026085717


   <b>Trillian test result (tid-3070)</b>
   Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
   Total time taken: 26888 seconds
   Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5911-t3070-kvm-centos7.zip
   Smoke tests completed. 74 look OK, 18 have errors
   Only failed tests results shown below:
   
   
   Test | Result | Time (s) | Test File
   --- | --- | --- | ---
   test_01_redundant_vpc_site2site_vpn | `Failure` | 7.43 | test_vpc_vpn.py
   test_01_vpc_site2site_vpn_multiple_options | `Failure` | 6.35 | test_vpc_vpn.py
   test_01_vpc_remote_access_vpn | `Failure` | 3.16 | test_vpc_vpn.py
   test_01_vpc_site2site_vpn | `Failure` | 5.34 | test_vpc_vpn.py
   test_02_deploy_vm_from_direct_download_template | `Error` | 1.21 | test_templates.py
   ContextSuite context=TestTemplates>:setup | `Error` | 17.80 | test_templates.py
   ContextSuite context=TestRemoteDiagnostics>:setup | `Error` | 0.00 | test_diagnostics.py
   test_01_deploy_vm_from_direct_download_template_nfs_storage | `Error` | 1.20 | test_direct_download.py
   ContextSuite context=TestDirectDownloadTemplates>:teardown | `Error` | 1.07 | test_direct_download.py
   ContextSuite context=TestCreateVolume>:setup | `Error` | 0.00 | test_volumes.py
   ContextSuite context=TestVolumes>:setup | `Error` | 0.00 | test_volumes.py
   test_deploy_vm_from_iso | `Error` | 11.87 | test_deploy_vm_iso.py
   ContextSuite context=TestDeployVirtioSCSIVM>:setup | `Error` | 0.00 | test_deploy_virtio_scsi_vm.py
   ContextSuite context=TestIsolatedNetworksPasswdServer>:setup | `Error` | 0.00 | test_password_server.py
   test_02_deploy_vm_with_extraconfig_kvm | `Error` | 1.30 | test_deploy_vm_extra_config_data.py
   test_03_update_vm_with_extraconfig_kvm | `Error` | 1.28 | test_deploy_vm_extra_config_data.py
   test_01_isolated_persistent_network | `Error` | 3.60 | test_persistent_network.py
   test_03_deploy_and_destroy_VM_and_verify_network_resources_persist | `Failure` | 2.40 | test_persistent_network.py
   test_03_deploy_and_destroy_VM_and_verify_network_resources_persist | `Error` | 2.40 | test_persistent_network.py
   ContextSuite context=TestL2PersistentNetworks>:teardown | `Error` | 2.44 | test_persistent_network.py
   test_list_vms_metrics | `Error` | 1.42 | test_metrics_api.py
   test_00_deploy_vm_root_resize | `Error` | 1.33 | test_deploy_vm_root_resize.py
   test_deployvm_userdata | `Error` | 1.27 | test_deploy_vm_with_userdata.py
   test_deployvm_userdata_post | `Error` | 1.22 | test_deploy_vm_with_userdata.py
   test_deployvm_firstfit | `Error` | 1.24 | test_deploy_vms_with_varied_deploymentplanners.py
   test_deployvm_userconcentrated | `Error` | 1.17 | test_deploy_vms_with_varied_deploymentplanners.py
   test_deployvm_userdispersing | `Error` | 1.18 | test_deploy_vms_with_varied_deploymentplanners.py
   ContextSuite context=TestResetVmOnReboot>:setup | `Error` | 0.00 | test_reset_vm_on_reboot.py
   test_01_so_removal_resource_update | `Error` | 1.45 | test_resource_accounting.py
   test_03_create_vpc_domain_vpc_offering | `Error` | 6.08 | test_domain_vpc_offerings.py
   test_02_redundant_VPC_default_routes | `Failure` | 55.00 | test_vpc_redundant.py
   test_03_create_redundant_VPC_1tier_2VMs_2IPs_2PF_ACL_reboot_routers | `Error` | 7.76 | test_vpc_redundant.py
   test_04_rvpc_network_garbage_collector_nics | `Error` | 7.87 | test_vpc_redundant.py
   test_05_rvpc_multi_tiers | `Error` | 6.77 | test_vpc_redundant.py
   


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] nvazquez commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
nvazquez commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1026237212


   @blueorangutan test


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan removed a comment on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan removed a comment on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032280985






-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan removed a comment on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan removed a comment on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032225142






-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032261395


   @blueorangutan test keepEnv


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan removed a comment on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan removed a comment on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1026085717


   <b>Trillian test result (tid-3070)</b>
   Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
   Total time taken: 26888 seconds
   Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5911-t3070-kvm-centos7.zip
   Smoke tests completed. 74 look OK, 18 have errors
   Only failed tests results shown below:
   
   
   Test | Result | Time (s) | Test File
   --- | --- | --- | ---
   test_01_redundant_vpc_site2site_vpn | `Failure` | 7.43 | test_vpc_vpn.py
   test_01_vpc_site2site_vpn_multiple_options | `Failure` | 6.35 | test_vpc_vpn.py
   test_01_vpc_remote_access_vpn | `Failure` | 3.16 | test_vpc_vpn.py
   test_01_vpc_site2site_vpn | `Failure` | 5.34 | test_vpc_vpn.py
   test_02_deploy_vm_from_direct_download_template | `Error` | 1.21 | test_templates.py
   ContextSuite context=TestTemplates>:setup | `Error` | 17.80 | test_templates.py
   ContextSuite context=TestRemoteDiagnostics>:setup | `Error` | 0.00 | test_diagnostics.py
   test_01_deploy_vm_from_direct_download_template_nfs_storage | `Error` | 1.20 | test_direct_download.py
   ContextSuite context=TestDirectDownloadTemplates>:teardown | `Error` | 1.07 | test_direct_download.py
   ContextSuite context=TestCreateVolume>:setup | `Error` | 0.00 | test_volumes.py
   ContextSuite context=TestVolumes>:setup | `Error` | 0.00 | test_volumes.py
   test_deploy_vm_from_iso | `Error` | 11.87 | test_deploy_vm_iso.py
   ContextSuite context=TestDeployVirtioSCSIVM>:setup | `Error` | 0.00 | test_deploy_virtio_scsi_vm.py
   ContextSuite context=TestIsolatedNetworksPasswdServer>:setup | `Error` | 0.00 | test_password_server.py
   test_02_deploy_vm_with_extraconfig_kvm | `Error` | 1.30 | test_deploy_vm_extra_config_data.py
   test_03_update_vm_with_extraconfig_kvm | `Error` | 1.28 | test_deploy_vm_extra_config_data.py
   test_01_isolated_persistent_network | `Error` | 3.60 | test_persistent_network.py
   test_03_deploy_and_destroy_VM_and_verify_network_resources_persist | `Failure` | 2.40 | test_persistent_network.py
   test_03_deploy_and_destroy_VM_and_verify_network_resources_persist | `Error` | 2.40 | test_persistent_network.py
   ContextSuite context=TestL2PersistentNetworks>:teardown | `Error` | 2.44 | test_persistent_network.py
   test_list_vms_metrics | `Error` | 1.42 | test_metrics_api.py
   test_00_deploy_vm_root_resize | `Error` | 1.33 | test_deploy_vm_root_resize.py
   test_deployvm_userdata | `Error` | 1.27 | test_deploy_vm_with_userdata.py
   test_deployvm_userdata_post | `Error` | 1.22 | test_deploy_vm_with_userdata.py
   test_deployvm_firstfit | `Error` | 1.24 | test_deploy_vms_with_varied_deploymentplanners.py
   test_deployvm_userconcentrated | `Error` | 1.17 | test_deploy_vms_with_varied_deploymentplanners.py
   test_deployvm_userdispersing | `Error` | 1.18 | test_deploy_vms_with_varied_deploymentplanners.py
   ContextSuite context=TestResetVmOnReboot>:setup | `Error` | 0.00 | test_reset_vm_on_reboot.py
   test_01_so_removal_resource_update | `Error` | 1.45 | test_resource_accounting.py
   test_03_create_vpc_domain_vpc_offering | `Error` | 6.08 | test_domain_vpc_offerings.py
   test_02_redundant_VPC_default_routes | `Failure` | 55.00 | test_vpc_redundant.py
   test_03_create_redundant_VPC_1tier_2VMs_2IPs_2PF_ACL_reboot_routers | `Error` | 7.76 | test_vpc_redundant.py
   test_04_rvpc_network_garbage_collector_nics | `Error` | 7.87 | test_vpc_redundant.py
   test_05_rvpc_multi_tiers | `Error` | 6.77 | test_vpc_redundant.py
   


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1025841335


   Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2407


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1026237754


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


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032434661


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032502786


   @sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032257930


   Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_multiplication_x: debian :heavy_check_mark: suse15. SL-JID 2507


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032501734


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r803397500



##########
File path: api/src/main/java/com/cloud/storage/GuestOS.java
##########
@@ -33,5 +33,5 @@
 
     Date getRemoved();
 
-    boolean isUserDefined();
+    boolean getIsUserDefined();

Review comment:
       correct, changed the accessor to be in line with GuestOSHypervisor. May be, have to fix this in Dao later.
   
   https://github.com/apache/cloudstack/blob/850714c1fcce7ae68533eac522f7a1f9748641c0/api/src/main/java/com/cloud/storage/GuestOSHypervisor.java#L39
   
   https://github.com/apache/cloudstack/blob/850714c1fcce7ae68533eac522f7a1f9748641c0/engine/schema/src/main/java/com/cloud/storage/GuestOSHypervisorVO.java#L128




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r802757838



##########
File path: api/src/main/java/com/cloud/storage/GuestOS.java
##########
@@ -33,5 +33,5 @@
 
     Date getRemoved();
 
-    boolean isUserDefined();
+    boolean getIsUserDefined();

Review comment:
       field name has to be _<property-name>_, not _is+<property-name>_




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r803390683



##########
File path: api/src/main/java/com/cloud/storage/GuestOS.java
##########
@@ -33,5 +33,5 @@
 
     Date getRemoved();
 
-    boolean isUserDefined();
+    boolean getIsUserDefined();

Review comment:
       I see @sureshanaparti , In that case I think we should rename the field, not the accessor.




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032283631


   Packaging result: :heavy_multiplication_x: el7 :heavy_multiplication_x: el8 :heavy_multiplication_x: debian :heavy_multiplication_x: suse15. SL-JID 2510


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032370432


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r803397500



##########
File path: api/src/main/java/com/cloud/storage/GuestOS.java
##########
@@ -33,5 +33,5 @@
 
     Date getRemoved();
 
-    boolean isUserDefined();
+    boolean getIsUserDefined();

Review comment:
       correct, changed the accessor to be in line with GuestOSHypervisor. May be, have to fix this is Dao later.
   
   https://github.com/apache/cloudstack/blob/850714c1fcce7ae68533eac522f7a1f9748641c0/api/src/main/java/com/cloud/storage/GuestOSHypervisor.java#L39
   
   https://github.com/apache/cloudstack/blob/850714c1fcce7ae68533eac522f7a1f9748641c0/engine/schema/src/main/java/com/cloud/storage/GuestOSHypervisorVO.java#L128




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland merged pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
DaanHoogland merged pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911


   


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032223364


   @sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032222888


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1025574327


   Packaging result: :heavy_check_mark: el7 :heavy_check_mark: el8 :heavy_check_mark: debian :heavy_check_mark: suse15. SL-JID 2399


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r795461668



##########
File path: engine/schema/src/main/java/com/cloud/upgrade/dao/Upgrade41600to41610.java
##########
@@ -57,6 +60,12 @@ public boolean supportsRollingUpgrade() {
 
     @Override
     public void performDataMigration(Connection conn) {
+        correctGuestOsIdsInHypervisorMapping(conn);
+    }
+
+    private void correctGuestOsIdsInHypervisorMapping(final Connection conn) {
+        LOG.debug("Correcting guest OS ids in hypervisor mappings");
+        guestOsMapper.updateGuestOsIdInHypervisorMapping(conn, 10, "Ubuntu 20.04 LTS", new Ternary<String, String, String>("Xenserver", "8.2.0", "Ubuntu Focal Fossa 20.04"));

Review comment:
       This would fix the incorrect guest os mapping in 4.15.0 to 4.15.1 schema, when upgrading to 4.16.1 from existing 4.16.0 env.
   
   https://github.com/apache/cloudstack/blob/571339f8724fc70c472f55f254125f0c6070d5de/engine/schema/src/main/resources/META-INF/db/schema-41500to41510.sql#L55-L57




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1025513547


   @sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1026573970


   <b>Trillian test result (tid-3086)</b>
   Environment: kvm-centos7 (x2), Advanced Networking with Mgmt server 7
   Total time taken: 36504 seconds
   Marvin logs: https://github.com/blueorangutan/acs-prs/releases/download/trillian/pr5911-t3086-kvm-centos7.zip
   Smoke tests completed. 92 look OK, 0 have errors
   Only failed tests results shown below:
   
   
   Test | Result | Time (s) | Test File
   --- | --- | --- | ---
   


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r802717992



##########
File path: api/src/main/java/com/cloud/storage/GuestOS.java
##########
@@ -33,5 +33,5 @@
 
     Date getRemoved();
 
-    boolean isUserDefined();
+    boolean getIsUserDefined();

Review comment:
       why this rename? convention on primitive boolean getters is `is`+`<property-name>`.

##########
File path: engine/schema/src/main/java/com/cloud/storage/GuestOSVO.java
##########
@@ -113,7 +113,7 @@ public Date getRemoved() {
     }
 
     @Override
-    public boolean isUserDefined() {
+    public boolean getIsUserDefined() {

Review comment:
       not a good rename




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1025770193


   > @sureshanaparti I've hit some sql exceptions around adding guestoss during upgrade. can you have a look pls.
   > [sql-upgrade-exceptions.txt](https://github.com/apache/cloudstack/files/7971183/sql-upgrade-exceptions.txt)
   
   fixed @borisstoyanov 


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r795557938



##########
File path: engine/schema/src/main/resources/META-INF/db/schema-41500to41510.sql
##########
@@ -18,117 +18,20 @@
 --;
 -- Schema upgrade from 4.15.0.0 to 4.15.1.0
 --;
--- Correct guest OS names
-UPDATE `cloud`.`guest_os` SET display_name='Fedora Linux (32 bit)' WHERE id=320;
-UPDATE `cloud`.`guest_os` SET display_name='Mandriva Linux (32 bit)' WHERE id=323;
-UPDATE `cloud`.`guest_os` SET display_name='OpenSUSE Linux (32 bit)' WHERE id=327;
-
--- Add support for SUSE Linux Enterprise Desktop 12 SP3 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (330, UUID(), 5, 'SUSE Linux Enterprise Desktop 12 SP3 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise Desktop 12 SP3 (64-bit)', 330, now(), 0);
--- Add support for SUSE Linux Enterprise Desktop 12 SP4 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (331, UUID(), 5, 'SUSE Linux Enterprise Desktop 12 SP4 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise Desktop 12 SP4 (64-bit)', 331, now(), 0);
--- Add support for SUSE Linux Enterprise Server 12 SP4 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (332, UUID(), 5, 'SUSE Linux Enterprise Server 12 SP4 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise Server 12 SP4 (64-bit)', 332, now(), 0);
--- Add support for Scientific Linux 7 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (333, UUID(), 9, 'Scientific Linux 7', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'Scientific Linux 7', 333, now(), 0);
--- Add support for NeoKylin Linux Server 7 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (334, UUID(), 9, 'NeoKylin Linux Server 7', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'NeoKylin Linux Server 7', 332, now(), 0);
--- Add support CentOS 8 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'CentOS 8', 297, now(), 0);
--- Add support for Debian Buster 10 for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'Debian Buster 10', 292, now(), 0);
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'Debian Buster 10', 293, now(), 0);
--- Add support for SUSE Linux Enterprise 15 (64-bit) for Xenserver 8.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.1.0', 'SUSE Linux Enterprise 15 (64-bit)', 291, now(), 0);
 
 -- Add XenServer 8.2.0 hypervisor capabilities
 INSERT IGNORE INTO `cloud`.`hypervisor_capabilities`(uuid, hypervisor_type, hypervisor_version, max_guests_limit, max_data_volumes_limit, max_hosts_per_cluster, storage_motion_supported) values (UUID(), 'XenServer', '8.2.0', 1000, 253, 64, 1);
 
 -- Copy XenServer 8.1.0 hypervisor guest OS mappings to XenServer 8.2.0
 INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'Xenserver', '8.2.0', guest_os_name, guest_os_id, utc_timestamp(), 0 FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='Xenserver' AND hypervisor_version='8.1.0';
 
--- Add support for Ubuntu Focal Fossa 20.04 for Xenserver 8.2.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (335, UUID(), 10, 'Ubuntu 20.04 LTS', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'Xenserver', '8.2.0', 'Ubuntu Focal Fossa 20.04', 330, now(), 0);
-
-ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `ike_version` varchar(5) NOT NULL DEFAULT 'ike' COMMENT 'one of ike, ikev1, ikev2';
-ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `split_connections` int(1) NOT NULL DEFAULT 0;
-
 -- Add support for VMware 7.0
 INSERT IGNORE INTO `cloud`.`hypervisor_capabilities` (uuid, hypervisor_type, hypervisor_version, max_guests_limit, security_group_enabled, max_data_volumes_limit, max_hosts_per_cluster, storage_motion_supported, vm_snapshot_enabled) values (UUID(), 'VMware', '7.0', 1024, 0, 59, 64, 1, 1);
 INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'VMware', '7.0', guest_os_name, guest_os_id, utc_timestamp(), 0  FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='VMware' AND hypervisor_version='6.7';
 
--- Add support for darwin19_64Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (336, UUID(), 7, 'macOS 10.15 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'darwin19_64Guest', 336, now(), 0);
-
--- Add support for debian11_64Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (337, UUID(), 2, 'Debian GNU/Linux 11 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'debian11_64Guest', 337, now(), 0);
-
--- Add support for debian11Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (338, UUID(), 2, 'Debian GNU/Linux 11 (32-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'debian11Guest', 338, now(), 0);
-
--- Add support for windows2019srv_64Guest from VMware 7.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0', 'windows2019srv_64Guest', 276, now(), 0);
-
-
 -- Add support for VMware 7.0.1.0
 INSERT IGNORE INTO `cloud`.`hypervisor_capabilities` (uuid, hypervisor_type, hypervisor_version, max_guests_limit, security_group_enabled, max_data_volumes_limit, max_hosts_per_cluster, storage_motion_supported, vm_snapshot_enabled) values (UUID(), 'VMware', '7.0.1.0', 1024, 0, 59, 64, 1, 1);
 INSERT IGNORE INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) SELECT UUID(),'VMware', '7.0.1.0', guest_os_name, guest_os_id, utc_timestamp(), 0  FROM `cloud`.`guest_os_hypervisor` WHERE hypervisor_type='VMware' AND hypervisor_version='7.0';
 
--- Add support for amazonlinux3_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (339, UUID(), 7, 'Amazon Linux 3 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'amazonlinux3_64Guest', 339, now(), 0);
-
--- Add support for asianux9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (340, UUID(), 7, 'Asianux Server 9 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'asianux9_64Guest', 340, now(), 0);
-
--- Add support for centos9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (341, UUID(), 1, 'CentOS 9', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'centos9_64Guest', 341, now(), 0);
-
--- Add support for darwin20_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (342, UUID(), 7, 'macOS 11 (64 bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'darwin20_64Guest', 342, now(), 0);
-
--- Add support for darwin21_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'darwin21_64Guest', 342, now(), 0);
-
--- Add support for freebsd13_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (343, UUID(), 9, 'FreeBSD 13 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'freebsd13_64Guest', 343, now(), 0);
-
--- Add support for freebsd13Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (344, UUID(), 9, 'FreeBSD 13 (32-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'freebsd13Guest', 344, now(), 0);
-
--- Add support for oracleLinux9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (345, UUID(), 3, 'Oracle Linux 9', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'oracleLinux9_64Guest', 345, now(), 0);
-
--- Add support for other5xLinux64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (346, UUID(), 2, 'Linux 5.x Kernel (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'other5xLinux64Guest', 346, now(), 0);
-
--- Add support for other5xLinuxGuest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (347, UUID(), 2, 'Linux 5.x Kernel (32-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'other5xLinuxGuest', 347, now(), 0);
-
--- Add support for rhel9_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (348, UUID(), 4, 'Red Hat Enterprise Linux 9.0', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'rhel9_64Guest', 348, now(), 0);
-
--- Add support for sles16_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os` (id, uuid, category_id, display_name, created) VALUES (349, UUID(), 5, 'SUSE Linux Enterprise Server 16 (64-bit)', now());
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'sles16_64Guest', 349, now(), 0);
-
--- Add support for windows2019srvNext_64Guest from VMware 7.0.1.0
-INSERT INTO `cloud`.`guest_os_hypervisor` (uuid,hypervisor_type, hypervisor_version, guest_os_name, guest_os_id, created, is_user_defined) VALUES (UUID(),'VMware', '7.0.1.0', 'windows2019srvNext_64Guest', 276, now(), 0);
+ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `ike_version` varchar(5) NOT NULL DEFAULT 'ike' COMMENT 'one of ike, ikev1, ikev2';
+ALTER TABLE `cloud`.`s2s_customer_gateway` ADD COLUMN `split_connections` int(1) NOT NULL DEFAULT 0;

Review comment:
       correct @weizhouapache 




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] DaanHoogland commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
DaanHoogland commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1026789367


   > > LGTM, @sureshanaparti can you see what's wrong with the test failures
   > 
   > which test failures @borisstoyanov
   
   older test results, I had deleted. the newest are fine @sureshanaparti 


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032228684


   @sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032280985


   @sureshanaparti a Jenkins job has been kicked to build packages. I'll keep you posted as I make progress.


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032280728


   @blueorangutan package


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] blueorangutan commented on pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
blueorangutan commented on pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#issuecomment-1032619781


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


-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [cloudstack] sureshanaparti commented on a change in pull request #5911: Improve the guest OS hypervisor mappings addition on upgrade.

Posted by GitBox <gi...@apache.org>.
sureshanaparti commented on a change in pull request #5911:
URL: https://github.com/apache/cloudstack/pull/5911#discussion_r802756067



##########
File path: engine/schema/src/main/java/com/cloud/storage/GuestOSVO.java
##########
@@ -113,7 +113,7 @@ public Date getRemoved() {
     }
 
     @Override
-    public boolean isUserDefined() {
+    public boolean getIsUserDefined() {

Review comment:
       agree, but i think it works if field name is _userDefined_
   
   https://github.com/apache/cloudstack/blob/41d25d54a79c21877b4c493261ab6a60251b9f34/framework/db/src/main/java/com/cloud/utils/db/SearchBase.java#L484-L486
   
   https://github.com/apache/cloudstack/blob/41d25d54a79c21877b4c493261ab6a60251b9f34/framework/db/src/main/java/com/cloud/utils/db/SqlGenerator.java#L83-L84




-- 
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: commits-unsubscribe@cloudstack.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org