mirror of
https://github.com/spring-projects/spring-data-elasticsearch.git
synced 2025-11-22 09:41:15 +00:00
Upgrade to Elasticsearch 9.2.0
Original Pull Request #3191 Closes: #3190 Signed-off-by: Peter-Josef Meisch <pj.meisch@sothawo.com>
This commit is contained in:
parent
21bc62b78c
commit
828f588f3e
4
pom.xml
4
pom.xml
@ -21,8 +21,8 @@
|
||||
<springdata.commons>4.0.0-SNAPSHOT</springdata.commons>
|
||||
|
||||
<!-- version of the ElasticsearchClient -->
|
||||
<elasticsearch-java>9.1.5</elasticsearch-java>
|
||||
<elasticsearch-rest-client>9.1.5</elasticsearch-rest-client>
|
||||
<elasticsearch-java>9.2.0</elasticsearch-java>
|
||||
<elasticsearch-rest-client>9.2.0</elasticsearch-rest-client>
|
||||
|
||||
<hoverfly>0.20.2</hoverfly>
|
||||
<log4j>2.25.1</log4j>
|
||||
|
||||
@ -6,7 +6,7 @@
|
||||
|
||||
* Upgrade to Spring 7
|
||||
* Switch to jspecify nullability annotations
|
||||
* Upgrade to Elasticsearch 9.1.5
|
||||
* Upgrade to Elasticsearch 9.2.0
|
||||
* Use the new Elasticsearch Rest5Client as default
|
||||
* Add support for SpEL expressions in the `settingPath` parameter of the `@Setting` annotation
|
||||
|
||||
|
||||
@ -6,7 +6,7 @@ The following table shows the Elasticsearch and Spring versions that are used by
|
||||
[cols="^,^,^,^",options="header"]
|
||||
|===
|
||||
| Spring Data Release Train | Spring Data Elasticsearch | Elasticsearch | Spring Framework
|
||||
| 2025.1 (in development) | 6.0.x | 9.1.5 | 7.0.x
|
||||
| 2025.1 (in development) | 6.0.x | 9.2.0 | 7.0.x
|
||||
| 2025.0 | 5.5.x | 8.18.1 | 6.2.x
|
||||
| 2024.1 | 5.4.x | 8.15.5 | 6.1.x
|
||||
| 2024.0 | 5.3.xfootnote:oom[Out of maintenance] | 8.13.4 | 6.1.x
|
||||
|
||||
@ -107,17 +107,15 @@ public @interface Document {
|
||||
*/
|
||||
Alias[] aliases() default {};
|
||||
|
||||
/**
|
||||
/**
|
||||
* Note: the enum value FORCE, which was introduced in 4.4 has been removed
|
||||
* again by Elasticsearch.
|
||||
* @since 4.3
|
||||
*/
|
||||
enum VersionType {
|
||||
INTERNAL("internal"), //
|
||||
EXTERNAL("external"), //
|
||||
EXTERNAL_GTE("external_gte"), //
|
||||
/**
|
||||
* @since 4.4
|
||||
*/
|
||||
FORCE("force");
|
||||
EXTERNAL_GTE("external_gte"); //
|
||||
|
||||
private final String esName;
|
||||
|
||||
|
||||
@ -1992,7 +1992,6 @@ class RequestConverter extends AbstractQueryProcessor {
|
||||
case INTERNAL -> VersionType.Internal;
|
||||
case EXTERNAL -> VersionType.External;
|
||||
case EXTERNAL_GTE -> VersionType.ExternalGte;
|
||||
case FORCE -> VersionType.Force;
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@ -424,7 +424,6 @@ final class TypeUtils {
|
||||
case INTERNAL -> VersionType.Internal;
|
||||
case EXTERNAL -> VersionType.External;
|
||||
case EXTERNAL_GTE -> VersionType.ExternalGte;
|
||||
case FORCE -> VersionType.Force;
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@ -17,6 +17,7 @@ package org.springframework.data.elasticsearch.core.geo;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
import org.jspecify.annotations.NonNull;
|
||||
import org.jspecify.annotations.Nullable;
|
||||
import org.springframework.data.annotation.Id;
|
||||
import org.springframework.data.elasticsearch.annotations.Document;
|
||||
@ -30,31 +31,31 @@ public class GeoJsonEntity {
|
||||
@Nullable
|
||||
@Id private String id;
|
||||
@Nullable private GeoJsonPoint point1;
|
||||
@Nullable private GeoJson<? extends Iterable<?>> point2;
|
||||
@Nullable private GeoJson<? extends @NonNull Iterable<?>> point2;
|
||||
@Nullable private GeoJsonMultiPoint multiPoint1;
|
||||
@Nullable private GeoJson<Iterable<Point>> multiPoint2;
|
||||
@Nullable private GeoJson<@NonNull Iterable<Point>> multiPoint2;
|
||||
@Nullable private GeoJsonLineString lineString1;
|
||||
@Nullable private GeoJson<Iterable<Point>> lineString2;
|
||||
@Nullable private GeoJson<@NonNull Iterable<Point>> lineString2;
|
||||
@Nullable private GeoJsonMultiLineString multiLineString1;
|
||||
@Nullable private GeoJson<Iterable<GeoJsonLineString>> multiLineString2;
|
||||
@Nullable private GeoJson<@NonNull Iterable<GeoJsonLineString>> multiLineString2;
|
||||
@Nullable private GeoJsonPolygon polygon1;
|
||||
@Nullable private GeoJson<Iterable<GeoJsonLineString>> polygon2;
|
||||
@Nullable private GeoJson<@NonNull Iterable<GeoJsonLineString>> polygon2;
|
||||
@Nullable private GeoJsonMultiPolygon multiPolygon1;
|
||||
@Nullable private GeoJson<Iterable<GeoJsonPolygon>> multiPolygon2;
|
||||
@Nullable private GeoJson<@NonNull Iterable<GeoJsonPolygon>> multiPolygon2;
|
||||
@Nullable private GeoJsonGeometryCollection geometryCollection1;
|
||||
@Nullable private GeoJson<Iterable<GeoJson<?>>> geometryCollection2;
|
||||
@Nullable private GeoJson<@NonNull Iterable<GeoJson<?>>> geometryCollection2;
|
||||
|
||||
public GeoJsonEntity() {}
|
||||
|
||||
public GeoJsonEntity(@Nullable String id, @Nullable GeoJsonPoint point1,
|
||||
@Nullable GeoJson<? extends Iterable<?>> point2, @Nullable GeoJsonMultiPoint multiPoint1,
|
||||
@Nullable GeoJson<Iterable<Point>> multiPoint2, @Nullable GeoJsonLineString lineString1,
|
||||
@Nullable GeoJson<Iterable<Point>> lineString2, @Nullable GeoJsonMultiLineString multiLineString1,
|
||||
@Nullable GeoJson<Iterable<GeoJsonLineString>> multiLineString2, @Nullable GeoJsonPolygon polygon1,
|
||||
@Nullable GeoJson<Iterable<GeoJsonLineString>> polygon2, @Nullable GeoJsonMultiPolygon multiPolygon1,
|
||||
@Nullable GeoJson<Iterable<GeoJsonPolygon>> multiPolygon2,
|
||||
@Nullable GeoJsonGeometryCollection geometryCollection1,
|
||||
@Nullable GeoJson<Iterable<GeoJson<?>>> geometryCollection2) {
|
||||
@Nullable GeoJson<? extends @NonNull Iterable<?>> point2, @Nullable GeoJsonMultiPoint multiPoint1,
|
||||
@Nullable GeoJson<@NonNull Iterable<Point>> multiPoint2, @Nullable GeoJsonLineString lineString1,
|
||||
@Nullable GeoJson<@NonNull Iterable<Point>> lineString2, @Nullable GeoJsonMultiLineString multiLineString1,
|
||||
@Nullable GeoJson<@NonNull Iterable<GeoJsonLineString>> multiLineString2, @Nullable GeoJsonPolygon polygon1,
|
||||
@Nullable GeoJson<@NonNull Iterable<GeoJsonLineString>> polygon2, @Nullable GeoJsonMultiPolygon multiPolygon1,
|
||||
@Nullable GeoJson<@NonNull Iterable<GeoJsonPolygon>> multiPolygon2,
|
||||
@Nullable GeoJsonGeometryCollection geometryCollection1,
|
||||
@Nullable GeoJson<@NonNull Iterable<GeoJson<?>>> geometryCollection2) {
|
||||
this.id = id;
|
||||
this.point1 = point1;
|
||||
this.point2 = point2;
|
||||
@ -91,11 +92,11 @@ public class GeoJsonEntity {
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public GeoJson<? extends Iterable<?>> getPoint2() {
|
||||
public GeoJson<? extends @NonNull Iterable<?>> getPoint2() {
|
||||
return point2;
|
||||
}
|
||||
|
||||
public void setPoint2(@Nullable GeoJson<? extends Iterable<?>> point2) {
|
||||
public void setPoint2(@Nullable GeoJson<? extends @NonNull Iterable<?>> point2) {
|
||||
this.point2 = point2;
|
||||
}
|
||||
|
||||
@ -109,11 +110,11 @@ public class GeoJsonEntity {
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public GeoJson<Iterable<Point>> getMultiPoint2() {
|
||||
public GeoJson<@NonNull Iterable<Point>> getMultiPoint2() {
|
||||
return multiPoint2;
|
||||
}
|
||||
|
||||
public void setMultiPoint2(@Nullable GeoJson<Iterable<Point>> multiPoint2) {
|
||||
public void setMultiPoint2(@Nullable GeoJson<@NonNull Iterable<Point>> multiPoint2) {
|
||||
this.multiPoint2 = multiPoint2;
|
||||
}
|
||||
|
||||
@ -127,11 +128,11 @@ public class GeoJsonEntity {
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public GeoJson<Iterable<Point>> getLineString2() {
|
||||
public GeoJson<@NonNull Iterable<Point>> getLineString2() {
|
||||
return lineString2;
|
||||
}
|
||||
|
||||
public void setLineString2(@Nullable GeoJson<Iterable<Point>> lineString2) {
|
||||
public void setLineString2(@Nullable GeoJson<@NonNull Iterable<Point>> lineString2) {
|
||||
this.lineString2 = lineString2;
|
||||
}
|
||||
|
||||
@ -145,11 +146,11 @@ public class GeoJsonEntity {
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public GeoJson<Iterable<GeoJsonLineString>> getMultiLineString2() {
|
||||
public GeoJson<@NonNull Iterable<GeoJsonLineString>> getMultiLineString2() {
|
||||
return multiLineString2;
|
||||
}
|
||||
|
||||
public void setMultiLineString2(@Nullable GeoJson<Iterable<GeoJsonLineString>> multiLineString2) {
|
||||
public void setMultiLineString2(@Nullable GeoJson<@NonNull Iterable<GeoJsonLineString>> multiLineString2) {
|
||||
this.multiLineString2 = multiLineString2;
|
||||
}
|
||||
|
||||
@ -163,11 +164,11 @@ public class GeoJsonEntity {
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public GeoJson<Iterable<GeoJsonLineString>> getPolygon2() {
|
||||
public GeoJson<@NonNull Iterable<GeoJsonLineString>> getPolygon2() {
|
||||
return polygon2;
|
||||
}
|
||||
|
||||
public void setPolygon2(@Nullable GeoJson<Iterable<GeoJsonLineString>> polygon2) {
|
||||
public void setPolygon2(@Nullable GeoJson<@NonNull Iterable<GeoJsonLineString>> polygon2) {
|
||||
this.polygon2 = polygon2;
|
||||
}
|
||||
|
||||
@ -181,11 +182,11 @@ public class GeoJsonEntity {
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public GeoJson<Iterable<GeoJsonPolygon>> getMultiPolygon2() {
|
||||
public GeoJson<@NonNull Iterable<GeoJsonPolygon>> getMultiPolygon2() {
|
||||
return multiPolygon2;
|
||||
}
|
||||
|
||||
public void setMultiPolygon2(@Nullable GeoJson<Iterable<GeoJsonPolygon>> multiPolygon2) {
|
||||
public void setMultiPolygon2(@Nullable GeoJson<@NonNull Iterable<GeoJsonPolygon>> multiPolygon2) {
|
||||
this.multiPolygon2 = multiPolygon2;
|
||||
}
|
||||
|
||||
@ -199,11 +200,11 @@ public class GeoJsonEntity {
|
||||
}
|
||||
|
||||
@Nullable
|
||||
public GeoJson<Iterable<GeoJson<?>>> getGeometryCollection2() {
|
||||
public GeoJson<@NonNull Iterable<GeoJson<?>>> getGeometryCollection2() {
|
||||
return geometryCollection2;
|
||||
}
|
||||
|
||||
public void setGeometryCollection2(@Nullable GeoJson<Iterable<GeoJson<?>>> geometryCollection2) {
|
||||
public void setGeometryCollection2(@Nullable GeoJson<@NonNull Iterable<GeoJson<?>>> geometryCollection2) {
|
||||
this.geometryCollection2 = geometryCollection2;
|
||||
}
|
||||
|
||||
|
||||
@ -115,7 +115,7 @@ abstract class GeoJsonIntegrationTests {
|
||||
));
|
||||
GeoJsonPolygon geoJsonPolygon = GeoJsonPolygon
|
||||
.of(new Point(12, 34), new Point(56, 78), new Point(90, 12), new Point(12, 34))
|
||||
.withInnerRing(new Point(21, 43), new Point(65, 87), new Point(9, 21), new Point(21, 43));
|
||||
.withInnerRing(new Point(35, 35), new Point(65, 30), new Point(55, 50), new Point(35, 35));
|
||||
GeoJsonMultiPolygon geoJsonMultiPolygon = GeoJsonMultiPolygon
|
||||
.of(Arrays.asList(GeoJsonPolygon.of(new Point(12, 34), new Point(56, 78), new Point(90, 12), new Point(12, 34)),
|
||||
GeoJsonPolygon.of(new Point(21, 43), new Point(65, 87), new Point(9, 21), new Point(21, 43))));
|
||||
|
||||
@ -15,7 +15,7 @@
|
||||
#
|
||||
#
|
||||
sde.testcontainers.image-name=docker.elastic.co/elasticsearch/elasticsearch
|
||||
sde.testcontainers.image-version=9.1.5
|
||||
sde.testcontainers.image-version=9.2.0
|
||||
#
|
||||
#
|
||||
# needed as we do a DELETE /* at the end of the tests, will be required from 8.0 on, produces a warning since 7.13
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user