Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions muted-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,6 @@ tests:
issue: https://github.com/elastic/elasticsearch/issues/120339
- class: org.elasticsearch.xpack.sql.expression.function.scalar.datetime.DateTimeToCharProcessorTests
issue: https://github.com/elastic/elasticsearch/issues/120575
- class: org.elasticsearch.xpack.inference.DefaultEndPointsIT
method: testMultipleInferencesTriggeringDownloadAndDeploy
issue: https://github.com/elastic/elasticsearch/issues/120668
- class: org.elasticsearch.xpack.test.rest.XPackRestIT
method: test {p0=ml/3rd_party_deployment/Test start deployment fails while model download in progress}
issue: https://github.com/elastic/elasticsearch/issues/120810
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
import java.util.concurrent.CountDownLatch;

import static org.hamcrest.Matchers.empty;
import static org.hamcrest.Matchers.equalTo;
import static org.hamcrest.Matchers.hasSize;
import static org.hamcrest.Matchers.is;
import static org.hamcrest.Matchers.oneOf;
Expand Down Expand Up @@ -75,7 +74,7 @@ public void testDefaultModels() throws IOException {

putModel("my-model", mockCompletionServiceModelConfig(TaskType.SPARSE_EMBEDDING, "streaming_completion_test_service"));
var registeredModels = getMinimalConfigs();
assertThat(registeredModels.size(), equalTo(1));
assertThat(registeredModels.size(), is(1));
assertTrue(registeredModels.containsKey("my-model"));
assertFalse(registeredModels.containsKey(ElasticsearchInternalService.DEFAULT_E5_ID));
assertFalse(registeredModels.containsKey(ElasticsearchInternalService.DEFAULT_ELSER_ID));
Expand Down Expand Up @@ -194,7 +193,14 @@ private static void assertDefaultChunkingSettings(Map<String, Object> modelConfi
);
}

public void testMultipleInferencesTriggeringDownloadAndDeploy() throws InterruptedException {
public void testMultipleInferencesTriggeringDownloadAndDeploy() throws InterruptedException, IOException {
var initialEndpointId = "initial-model";
// Creating an inference endpoint to force the backing indices to be created to reduce the likelihood of the test failing
// because it's trying to interact with the indices while they're being created.
putModel(initialEndpointId, mockCompletionServiceModelConfig(TaskType.SPARSE_EMBEDDING, "streaming_completion_test_service"));
// delete model so it doesn't affect other tests
deleteModel(initialEndpointId);

int numParallelRequests = 4;
var latch = new CountDownLatch(numParallelRequests);
var errors = new ArrayList<Exception>();
Expand Down