Skip to content

Commit

Permalink
Dependency updates: Spring Boot 3.4.0, Spring Framework 6.2, Spring D…
Browse files Browse the repository at this point in the history
…ata Elasticsearch 5.4.0

Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
  • Loading branch information
reta committed Sep 13, 2024
1 parent 31c1b04 commit 20571bf
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 7 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ The Spring Data OpenSearch follows the release model of the Spring Data Elastics

| Spring Data Release Train | Spring Data OpenSearch | Spring Data Elasticsearch | OpenSearch Server | OpenSearch Client | Spring Framework | Spring Boot |
|---------------------------|------------------------|---------------------------|-------------------|-------------------|------------------|---------------|
| 2024.1 | 1.6.x | 5.4.x | 1.x / 2.x | 2.10.x and above | 6.2.x | 3.4.x |
| 2024.0 | 1.5.x | 5.3.x | 1.x / 2.x | 2.10.x and above | 6.1.x | 3.2.x / 3.3.x |
| 2023.1 (Vaughan) | 1.4.x | 5.2.x | 1.x / 2.x | 2.10.x and above | 6.1.x | 3.2.x |
| 2023.1 (Vaughan) | 1.3.x | 5.2.x | 1.x / 2.x | 2.7.x and above | 6.1.x | 3.2.x |
Expand Down
14 changes: 10 additions & 4 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ dependencyResolutionManagement {
}

create("springLibs") {
version("spring", "6.1.12")
version("spring-boot", "3.3.3")
library("data-commons", "org.springframework.data:spring-data-commons:3.3.3")
library("data-elasticsearch", "org.springframework.data:spring-data-elasticsearch:5.3.3")
version("spring", "6.2.0-RC1")
version("spring-boot", "3.4.0-M2")
library("data-commons", "org.springframework.data:spring-data-commons:3.4.0-M1")
library("data-elasticsearch", "org.springframework.data:spring-data-elasticsearch:5.4.0-M1")
library("web", "org.springframework", "spring-web").versionRef("spring")
library("context", "org.springframework", "spring-context").versionRef("spring")
library("tx", "org.springframework", "spring-tx").versionRef("spring")
Expand Down Expand Up @@ -72,12 +72,18 @@ pluginManagement {
maven {
url = uri("https://repo.spring.io/release/")
}
maven {
url = uri("https://repo.spring.io/milestone/")
}
}
}

dependencyResolutionManagement {
repositories {
mavenCentral()
maven {
url = uri("https://repo.spring.io/milestone/")
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,12 @@
import org.springframework.data.elasticsearch.core.query.IndexQuery;
import org.springframework.data.elasticsearch.core.query.MoreLikeThisQuery;
import org.springframework.data.elasticsearch.core.query.Query;
import org.springframework.data.elasticsearch.core.query.SqlQuery;
import org.springframework.data.elasticsearch.core.query.UpdateQuery;
import org.springframework.data.elasticsearch.core.query.UpdateResponse;
import org.springframework.data.elasticsearch.core.reindex.ReindexRequest;
import org.springframework.data.elasticsearch.core.reindex.ReindexResponse;
import org.springframework.data.elasticsearch.core.sql.SqlResponse;
import org.springframework.lang.Nullable;
import org.springframework.util.Assert;

Expand Down Expand Up @@ -631,6 +633,11 @@ protected MultiSearchResponse.Item[] getMultiSearchResult(MultiSearchRequest req
return items;
}

@Override
public SqlResponse search(SqlQuery query) {
throw new UnsupportedOperationException("The operation search(SqlQuery query) is not supported");
}

// endregion

// region ClientCallback
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,13 @@
import org.springframework.data.elasticsearch.core.query.MoreLikeThisQuery;
import org.springframework.data.elasticsearch.core.query.Query;
import org.springframework.data.elasticsearch.core.query.SearchTemplateQuery;
import org.springframework.data.elasticsearch.core.query.SqlQuery;
import org.springframework.data.elasticsearch.core.query.UpdateQuery;
import org.springframework.data.elasticsearch.core.query.UpdateResponse;
import org.springframework.data.elasticsearch.core.reindex.ReindexRequest;
import org.springframework.data.elasticsearch.core.reindex.ReindexResponse;
import org.springframework.data.elasticsearch.core.script.Script;
import org.springframework.data.elasticsearch.core.sql.SqlResponse;
import org.springframework.lang.Nullable;
import org.springframework.util.Assert;

Expand Down Expand Up @@ -642,6 +644,11 @@ public List<PitInfo> listPointInTime() {
.toList();
}

@Override
public SqlResponse search(SqlQuery query) {
throw new UnsupportedOperationException("The operation search(SqlQuery query) is not supported");
}

// endregion

// region script methods
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
import org.junit.jupiter.api.DisplayName;
import org.junit.jupiter.api.Order;
import org.junit.jupiter.api.Test;
import org.opensearch.data.client.EnabledIfOpenSearchVersion;
import org.opensearch.data.client.junit.jupiter.OpenSearchRestTemplateConfiguration;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Bean;
Expand Down Expand Up @@ -92,6 +93,13 @@ void setUp() {
void cleanup() {
operations.indexOps(IndexCoordinates.of(indexNameProvider.getPrefix() + "*")).delete();
}

@Test
@EnabledIfOpenSearchVersion(onOrAfter = "2.15.0", reason = "https://github.com/opensearch-project/OpenSearch/issues/5639")
public void shouldSupportAllTypes() {
IndexOperations indexOperations = operations.indexOps(EntityWithAllTypes.class);
indexOperations.createWithMapping();
}

@Test
public void shouldNotFailOnCircularReference() {
Expand Down Expand Up @@ -853,7 +861,7 @@ private static class EntityWithAllTypes {
@Nullable
@Field(type = FieldType.Percolator) String percolatorField;
@Nullable
@Field(type = FieldType.Flattened) String flattenedField;
@Field(type = FieldType.Flattened, mappedTypeName = "flat_object") String flattenedField;
@Nullable
@Field(type = FieldType.Search_As_You_Type) String searchAsYouTypeField;
@Nullable
Expand All @@ -862,8 +870,6 @@ private static class EntityWithAllTypes {
@Field(type = FieldType.Rank_Features) String rankFeaturesField;
@Nullable
@Field(type = FieldType.Wildcard) String wildcardField;
@Nullable
@Field(type = FieldType.Dense_Vector, dims = 1) String denseVectorField;
}
// endregion
}

0 comments on commit 20571bf

Please sign in to comment.