Fix 172 migrations by avoiding throwing errors (#21697)

This commit is contained in:
IceS2 2025-06-12 23:49:26 +02:00 committed by GitHub
parent 2803e62f0b
commit a3968d40b0
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -34,10 +34,8 @@ public class MigrationUtil {
deleteIndexTemplate(searchClient);
deleteComponentTemplate(searchClient);
deleteIlmPolicy(searchClient, null);
LOG.info("Successfully completed Data Insights objects cleanup");
} catch (Exception e) {
LOG.error("Error deleting Data Insights objects", e);
throw e;
}
} else {
LOG.info("No CLUSTER_ALIAS found, skipping cleanup");
@ -72,7 +70,6 @@ public class MigrationUtil {
}
} catch (Exception e) {
LOG.error("Error deleting data insights data streams", e);
throw e;
}
}
@ -87,7 +84,6 @@ public class MigrationUtil {
searchClient.deleteILMPolicy(getClusteredPrefix(clusterAlias, ILM_POLICY_NAME));
} catch (Exception e) {
LOG.error("Error deleting ILM policies", e);
throw e;
}
}
@ -97,7 +93,6 @@ public class MigrationUtil {
searchClient.deleteIndexTemplate(INDEX_TEMPLATE_NAME);
} catch (Exception e) {
LOG.error("Error deleting index template", e);
throw e;
}
}
@ -108,7 +103,6 @@ public class MigrationUtil {
searchClient.deleteComponentTemplate(componentName);
} catch (Exception e) {
LOG.error("Error deleting component template", e);
throw e;
}
}
}