@@ -83,7 +83,7 @@ public void performDataMigration(Connection conn) {
8383 createPlaceHolderNics (conn );
8484 updateRemoteAccessVpn (conn );
8585 updateSystemVmTemplates (conn );
86- updateCluster_details (conn );
86+ updateOverCommitRatioClusterDetails (conn );
8787 updatePrimaryStore (conn );
8888 addEgressFwRulesForSRXGuestNw (conn );
8989 upgradeEIPNetworkOfferings (conn );
@@ -898,7 +898,7 @@ private void updatePrimaryStore(Connection conn) {
898898 }
899899
900900 //update the cluster_details table with default overcommit ratios.
901- private void updateCluster_details (Connection conn ) {
901+ private void updateOverCommitRatioClusterDetails (Connection conn ) {
902902 PreparedStatement pstmt = null ;
903903 PreparedStatement pstmt1 = null ;
904904 PreparedStatement pstmt2 =null ;
@@ -907,7 +907,7 @@ private void updateCluster_details(Connection conn) {
907907 ResultSet rscpu_global = null ;
908908 ResultSet rsmem_global = null ;
909909 try {
910- pstmt = conn .prepareStatement ("select id, hypervisor_type from `cloud`.`cluster`" );
910+ pstmt = conn .prepareStatement ("select id, hypervisor_type from `cloud`.`cluster` WHERE removed IS NULL " );
911911 pstmt1 =conn .prepareStatement ("INSERT INTO `cloud`.`cluster_details` (cluster_id, name, value) VALUES(?, 'cpuOvercommitRatio', ?)" );
912912 pstmt2 =conn .prepareStatement ("INSERT INTO `cloud`.`cluster_details` (cluster_id, name, value) VALUES(?, 'memoryOvercommitRatio', ?)" );
913913 pstmt3 =conn .prepareStatement ("select value from `cloud`.`configuration` where name=?" );
@@ -926,7 +926,7 @@ private void updateCluster_details(Connection conn) {
926926 while (rs1 .next ()) {
927927 long id = rs1 .getLong (1 );
928928 String hypervisor_type = rs1 .getString (2 );
929- if (hypervisor_type . equalsIgnoreCase ( HypervisorType .VMware .toString ())) {
929+ if (HypervisorType .VMware .toString (). equalsIgnoreCase ( hypervisor_type )) {
930930 pstmt1 .setLong (1 ,id );
931931 pstmt1 .setString (2 ,global_cpu_overprovisioning_factor );
932932 pstmt1 .execute ();
0 commit comments