Skip to content

Commit ff4d973

Browse files
committed
HSEARCH-5410 Add compatibility with OpenSearch 3.1.0
1 parent c3d8c59 commit ff4d973

File tree

6 files changed

+17
-8
lines changed

6 files changed

+17
-8
lines changed

Jenkinsfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,8 @@ stage('Configure') {
290290
new LocalOpenSearchBuildEnvironment(version: '2.17.1', condition: TestCondition.ON_DEMAND),
291291
new LocalOpenSearchBuildEnvironment(version: '2.18.0', condition: TestCondition.ON_DEMAND),
292292
new LocalOpenSearchBuildEnvironment(version: '2.19.2', condition: TestCondition.AFTER_MERGE),
293-
new LocalOpenSearchBuildEnvironment(version: '3.0.0', condition: TestCondition.BEFORE_MERGE),
293+
new LocalOpenSearchBuildEnvironment(version: '3.0.0', condition: TestCondition.ON_DEMAND),
294+
new LocalOpenSearchBuildEnvironment(version: '3.1.0', condition: TestCondition.BEFORE_MERGE),
294295
// See https://opensearch.org/lines/2x.html for a list of all 2.x versions
295296
// IMPORTANT: Make sure to update the documentation for any newly supported OpenSearch versions
296297
// See version.org.opensearch.compatible.expected.text

backend/elasticsearch/src/main/java/org/hibernate/search/backend/elasticsearch/dialect/impl/ElasticsearchDialectFactory.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ private ElasticsearchProtocolDialect createProtocolDialectOpenSearchV2(Elasticse
265265
}
266266

267267
private ElasticsearchProtocolDialect createProtocolDialectOpenSearchV3(ElasticsearchVersion version, int minor) {
268-
if ( minor > 0 ) {
268+
if ( minor > 1 ) {
269269
VersionLog.INSTANCE.unknownElasticsearchVersion( version );
270270
}
271271
return new Elasticsearch70ProtocolDialect();

backend/elasticsearch/src/test/java/org/hibernate/search/backend/elasticsearch/dialect/impl/ElasticsearchDialectFactoryTest.java

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -504,14 +504,22 @@ public static List<? extends Arguments> params() {
504504
ElasticsearchDistributionName.OPENSEARCH, "3.0.0", "3.0.0",
505505
OpenSearch214ModelDialect.class, Elasticsearch70ProtocolDialect.class
506506
),
507-
successWithWarning(
507+
success(
508508
ElasticsearchDistributionName.OPENSEARCH, "3.1", "3.1.0",
509509
OpenSearch214ModelDialect.class, Elasticsearch70ProtocolDialect.class
510510
),
511-
successWithWarning(
511+
success(
512512
ElasticsearchDistributionName.OPENSEARCH, "3.1.0", "3.1.0",
513513
OpenSearch214ModelDialect.class, Elasticsearch70ProtocolDialect.class
514514
),
515+
successWithWarning(
516+
ElasticsearchDistributionName.OPENSEARCH, "3.2", "3.2.0",
517+
OpenSearch214ModelDialect.class, Elasticsearch70ProtocolDialect.class
518+
),
519+
successWithWarning(
520+
ElasticsearchDistributionName.OPENSEARCH, "3.2.0", "3.2.0",
521+
OpenSearch214ModelDialect.class, Elasticsearch70ProtocolDialect.class
522+
),
515523
successWithWarning(
516524
ElasticsearchDistributionName.OPENSEARCH, "4", "4.0.0",
517525
OpenSearch214ModelDialect.class, Elasticsearch70ProtocolDialect.class

build/container/search-backend/amazon-opensearch-serverless.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
# IMPORTANT! When updating the version of OpenSearch in this Dockerfile,
55
# make sure to update `version.org.opensearch.latest` property in a POM file,
66
# and to update the version in opensearch.Dockerfile as well.
7-
FROM docker.io/opensearchproject/opensearch:3.0.0
7+
FROM docker.io/opensearchproject/opensearch:3.1.0

build/container/search-backend/opensearch.Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@
44
# IMPORTANT! When updating the version of OpenSearch in this Dockerfile,
55
# make sure to update `version.org.opensearch.latest` property in a POM file,
66
# and to update the version in amazon-opensearch-serverless.Dockerfile as well.
7-
FROM docker.io/opensearchproject/opensearch:3.0.0
7+
FROM docker.io/opensearchproject/opensearch:3.1.0

build/parents/build/pom.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,13 +70,13 @@
7070
-->
7171
<!-- The versions of OpenSearch advertised as compatible with Hibernate Search -->
7272
<!-- Make sure to only mention tested versions here -->
73-
<version.org.opensearch.compatible.regularly-tested.text>1.3, 2.19 or 3.0</version.org.opensearch.compatible.regularly-tested.text>
73+
<version.org.opensearch.compatible.regularly-tested.text>1.3, 2.19 or 3.1</version.org.opensearch.compatible.regularly-tested.text>
7474
<!-- These are the versions same as above, but pointing only to the major part (used in compatibility section of ES backend documentation
7575
as versions that Hibernate Search is compatible with. -->
7676
<!-- NOTE: Adding new major versions would require to update the compatibility table in `backend-elasticsearch-compatibility` section of `backend-elasticsearch.asciidoc`. -->
7777
<version.org.opensearch.compatible.expected.text>1.3, 2.x or 3.x</version.org.opensearch.compatible.expected.text>
7878
<!-- The latest version of OpenSearch tested against by default -->
79-
<version.org.opensearch.latest>3.0.0</version.org.opensearch.latest>
79+
<version.org.opensearch.latest>3.1.0</version.org.opensearch.latest>
8080
<!-- The main compatible version of OpenSearch, advertised by default. Used in documentation links. -->
8181
<version.org.opensearch.compatible.main>${version.org.opensearch.latest}</version.org.opensearch.compatible.main>
8282
<documentation.org.opensearch.url>https://opensearch.org/docs/${parsed-version.org.opensearch.compatible.main.majorVersion}.${parsed-version.org.opensearch.compatible.main.minorVersion}</documentation.org.opensearch.url>

0 commit comments

Comments
 (0)