Skip to content

Commit

Permalink
make restart and upgrade base tests same
Browse files Browse the repository at this point in the history
  • Loading branch information
will-hwang committed Jan 8, 2025
1 parent 3066082 commit c02b6d8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ protected final ClusterType getClusterType() {
}

protected final boolean isFirstMixedRound() {
return Boolean.parseBoolean(System.getProperty(ROLLING_UPGRADE_FIRST_ROUND, "false"));
return Boolean.parseBoolean(System.getProperty(ROLLING_UPGRADE_FIRST_ROUND));
}

protected final Optional<String> getBWCVersion() {
Expand Down Expand Up @@ -131,13 +131,13 @@ protected void createPipelineForSparseEncodingProcessor(String modelId, String p
createPipelineProcessor(requestBody, pipelineName, modelId);
}

@Override
protected void updateClusterSettings() {
updateClusterSettings("plugins.ml_commons.only_run_on_ml_node", false);
// default threshold for native circuit breaker is 90, it may be not enough on test runner machine
updateClusterSettings("plugins.ml_commons.native_memory_threshold", 100);
updateClusterSettings("plugins.ml_commons.allow_registering_model_via_url", true);
}
// @Override
// protected void updateClusterSettings() {
// updateClusterSettings("plugins.ml_commons.only_run_on_ml_node", false);
// // default threshold for native circuit breaker is 90, it may be not enough on test runner machine
// updateClusterSettings("plugins.ml_commons.native_memory_threshold", 100);
// updateClusterSettings("plugins.ml_commons.allow_registering_model_via_url", true);
// }

protected void createPipelineForTextChunkingProcessor(String pipelineName) throws Exception {
String requestBody = Files.readString(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,14 +32,7 @@ public class MultiModalSearchIT extends AbstractRollingUpgradeTestCase {
// Create Text Image Embedding Processor, Ingestion Pipeline and add document
// Validate process , pipeline and document count in rolling-upgrade scenario
public void testTextImageEmbeddingProcessor_E2EFlow() throws Exception {
int count = 0;
int maxCount = 3;
Response response;
do {
response = waitForClusterHealthGreen(NODES_BWC_CLUSTER);
count++;
} while (count < maxCount && response.getStatusLine().getStatusCode() == 200 );

waitForClusterHealthGreen(NODES_BWC_CLUSTER);
switch (getClusterType()) {
case OLD:
modelId = uploadTextImageEmbeddingModel();
Expand Down

0 comments on commit c02b6d8

Please sign in to comment.