Skip to content

Commit 1ffa7d6

Browse files
Multiple minor changes: drop precommit for win CI, refator BWC, added changelog
Signed-off-by: Martin Gaievski <gaievski@amazon.com>
1 parent 333cd31 commit 1ffa7d6

File tree

6 files changed

+8
-31
lines changed

6 files changed

+8
-31
lines changed

.github/workflows/CI.yml

-22
Original file line numberDiff line numberDiff line change
@@ -117,28 +117,6 @@ jobs:
117117
name: coverage-report-${{ matrix.os }}-${{ matrix.java }}
118118
path: ./jacocoTestReport.xml
119119

120-
Precommit-neural-search-windows:
121-
strategy:
122-
matrix:
123-
java: [21, 23]
124-
os: [windows-latest]
125-
126-
name: Pre-commit Windows
127-
runs-on: ${{ matrix.os }}
128-
129-
steps:
130-
- uses: actions/checkout@v4
131-
132-
- name: Setup Java ${{ matrix.java }}
133-
uses: actions/setup-java@v4
134-
with:
135-
distribution: 'temurin'
136-
java-version: ${{ matrix.java }}
137-
138-
- name: Run build
139-
run: |
140-
./gradlew precommit --parallel
141-
142120
Precommit-codecov:
143121
needs: Precommit-neural-search-linux
144122
strategy:

.github/workflows/test_aggregations.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ jobs:
5454
Check-neural-search-windows:
5555
strategy:
5656
matrix:
57-
java: [21, 23]
57+
java: [23]
5858
os: [windows-latest]
5959

6060
name: Integ Tests Windows

CHANGELOG.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
66
## [Unreleased 3.0](https://github.com/opensearch-project/neural-search/compare/2.x...HEAD)
77
### Features
88
### Enhancements
9-
- Set neural-search plugin 3.0.0 baseline JDK version to JDK-2 ([#838](https://github.com/opensearch-project/neural-search/pull/838))
9+
- Set neural-search plugin 3.0.0 baseline JDK version to JDK-23 ([#838](https://github.com/opensearch-project/neural-search/pull/838))
1010
### Bug Fixes
1111
### Infrastructure
12+
- [3.0] Update neural-search for OpenSearch 3.0 compatibility ([#1141](https://github.com/opensearch-project/neural-search/pull/1141))
1213
### Documentation
1314
### Maintenance
1415
### Refactoring

qa/rolling-upgrade/src/test/java/org/opensearch/neuralsearch/bwc/rolling/BatchIngestionIT.java

-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
import java.nio.file.Path;
1212
import java.util.List;
1313
import java.util.Map;
14-
import java.util.Set;
1514

1615
import static org.opensearch.neuralsearch.util.BatchIngestionUtils.prepareDataForBulkIngestion;
1716
import static org.opensearch.neuralsearch.util.TestUtils.NODES_BWC_CLUSTER;

src/testFixtures/java/org/opensearch/neuralsearch/BaseNeuralSearchIT.java

+4-4
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@
7474
import com.google.common.collect.ImmutableList;
7575

7676
import static org.opensearch.neuralsearch.util.TestUtils.INGEST_PIPELINE_TYPE;
77-
import static org.opensearch.neuralsearch.util.TestUtils.MAX_TASK_RESULT_QUERY_TIME_IN_SECOND;
77+
import static org.opensearch.neuralsearch.util.TestUtils.MAX_TASK_RETRIES;
7878
import static org.opensearch.neuralsearch.util.TestUtils.DEFAULT_TASK_RESULT_QUERY_INTERVAL_IN_MILLISECOND;
7979
import static org.opensearch.neuralsearch.util.TestUtils.DEFAULT_USER_AGENT;
8080
import static org.opensearch.neuralsearch.util.TestUtils.DEFAULT_NORMALIZATION_METHOD;
@@ -214,7 +214,7 @@ protected String uploadModel(final String requestBody) throws Exception {
214214

215215
Map<String, Object> taskQueryResult = getTaskQueryResponse(taskId);
216216
boolean isComplete = checkComplete(taskQueryResult);
217-
for (int i = 0; !isComplete && i < MAX_TASK_RESULT_QUERY_TIME_IN_SECOND; i++) {
217+
for (int i = 0; !isComplete && i < MAX_TASK_RETRIES; i++) {
218218
taskQueryResult = getTaskQueryResponse(taskId);
219219
isComplete = checkComplete(taskQueryResult);
220220
Thread.sleep(DEFAULT_TASK_RESULT_QUERY_INTERVAL_IN_MILLISECOND);
@@ -243,12 +243,12 @@ protected void loadModel(final String modelId) throws Exception {
243243

244244
Map<String, Object> taskQueryResult = getTaskQueryResponse(taskId);
245245
boolean isComplete = checkComplete(taskQueryResult);
246-
for (int i = 0; !isComplete && i < MAX_TASK_RESULT_QUERY_TIME_IN_SECOND; i++) {
246+
for (int i = 0; !isComplete && i < MAX_TASK_RETRIES; i++) {
247247
taskQueryResult = getTaskQueryResponse(taskId);
248248
isComplete = checkComplete(taskQueryResult);
249249
Thread.sleep(DEFAULT_TASK_RESULT_QUERY_INTERVAL_IN_MILLISECOND);
250250
}
251-
assertTrue(isComplete);
251+
assertTrue(String.format(Locale.ROOT, "failed to load the model, last task finished with status %s", taskQueryResult.get("state")), isComplete);
252252
}
253253

254254
/**

src/testFixtures/java/org/opensearch/neuralsearch/util/TestUtils.java

+1-2
Original file line numberDiff line numberDiff line change
@@ -59,14 +59,13 @@ public class TestUtils {
5959
public static final String SEARCH_PIPELINE_TYPE = "_search";
6060
public static final String TEXT_EMBEDDING_PROCESSOR = "text_embedding";
6161
public static final String TEXT_IMAGE_EMBEDDING_PROCESSOR = "text_image_embedding";
62-
public static final int MAX_TASK_RESULT_QUERY_TIME_IN_SECOND = 60 * 5;
62+
public static final int MAX_TASK_RETRIES = 30;
6363
public static final int DEFAULT_TASK_RESULT_QUERY_INTERVAL_IN_MILLISECOND = 1000;
6464
public static final String DEFAULT_USER_AGENT = "Kibana";
6565
public static final String DEFAULT_NORMALIZATION_METHOD = "min_max";
6666
public static final String DEFAULT_COMBINATION_METHOD = "arithmetic_mean";
6767
public static final String PARAM_NAME_WEIGHTS = "weights";
6868
public static final String SPARSE_ENCODING_PROCESSOR = "sparse_encoding";
69-
public static final String TEXT_CHUNKING_PROCESSOR = "text_chunking";
7069
public static final int MAX_TIME_OUT_INTERVAL = 3000;
7170
public static final int MAX_RETRY = 5;
7271

0 commit comments

Comments
 (0)