1
0
mirror of synced 2026-05-23 04:33:17 +00:00

Compare commits

...

15 Commits

Author SHA1 Message Date
Mark Paluch 4729b9cfdc Release version 5.2.7 (2023.1.7).
See #2912
2024-06-14 10:04:22 +02:00
Mark Paluch aa16c0c5ab Prepare 5.2.7 (2023.1.7).
See #2912
2024-06-14 10:04:05 +02:00
Peter-Josef Meisch 5e507fa163 Fix max dim value for dense vector.
Closes #2911

(cherry picked from commit e997b39f68)
(cherry picked from commit ba9edf8ec8)
2024-05-18 18:27:59 +02:00
Mark Paluch a355537d78 After release cleanups.
See #2895
2024-05-17 11:24:38 +02:00
Mark Paluch 4fbf9f8b5a Prepare next development iteration.
See #2895
2024-05-17 11:24:37 +02:00
Mark Paluch 2cb27c26d7 Release version 5.2.6 (2023.1.6).
See #2895
2024-05-17 11:22:24 +02:00
Mark Paluch c322797eab Prepare 5.2.6 (2023.1.6).
See #2895
2024-05-17 11:22:00 +02:00
Peter-Josef Meisch c81958f62d Fix implementation of explicit refresh policy.
Original Pull Request #2908
Closes #2907

(cherry picked from commit 94a40a7a75)
2024-05-10 09:35:20 +02:00
Peter-Josef Meisch ed18be6f1c Fix parameter in Order constructor.
Closes #2897

(cherry picked from commit ad66510e9e)
2024-04-15 21:11:35 +02:00
Mark Paluch b3a21fbb7c After release cleanups.
See #2873
2024-04-12 10:17:29 +02:00
Mark Paluch d874b9d000 Prepare next development iteration.
See #2873
2024-04-12 10:17:28 +02:00
Mark Paluch 36e6a4b328 Release version 5.2.5 (2023.1.5).
See #2873
2024-04-12 10:15:11 +02:00
Mark Paluch 3710e47abd Prepare 5.2.5 (2023.1.5).
See #2873
2024-04-12 10:14:56 +02:00
Mark Paluch c40abc267b After release cleanups.
See #2850
2024-03-15 10:20:09 +01:00
Mark Paluch b479184d83 Prepare next development iteration.
See #2850
2024-03-15 10:20:08 +01:00
6 changed files with 30 additions and 22 deletions
+3 -3
View File
@@ -5,12 +5,12 @@
<groupId>org.springframework.data</groupId>
<artifactId>spring-data-elasticsearch</artifactId>
<version>5.2.4</version>
<version>5.2.7</version>
<parent>
<groupId>org.springframework.data.build</groupId>
<artifactId>spring-data-parent</artifactId>
<version>3.2.4</version>
<version>3.2.7</version>
</parent>
<name>Spring Data Elasticsearch</name>
@@ -18,7 +18,7 @@
<url>https://github.com/spring-projects/spring-data-elasticsearch</url>
<properties>
<springdata.commons>3.2.4</springdata.commons>
<springdata.commons>3.2.7</springdata.commons>
<!-- version of the ElasticsearchClient -->
<elasticsearch-java>8.11.4</elasticsearch-java>
@@ -169,8 +169,8 @@ public final class MappingParameters {
positiveScoreImpact = field.positiveScoreImpact();
dims = field.dims();
if (type == FieldType.Dense_Vector) {
Assert.isTrue(dims >= 1 && dims <= 2048,
"Invalid required parameter! Dense_Vector value \"dims\" must be between 1 and 2048.");
Assert.isTrue(dims >= 1 && dims <= 4096,
"Invalid required parameter! Dense_Vector value \"dims\" must be between 1 and 4096.");
}
Assert.isTrue(field.enabled() || type == FieldType.Object, "enabled false is only allowed for field type object");
enabled = field.enabled();
@@ -212,8 +212,8 @@ public final class MappingParameters {
positiveScoreImpact = field.positiveScoreImpact();
dims = field.dims();
if (type == FieldType.Dense_Vector) {
Assert.isTrue(dims >= 1 && dims <= 2048,
"Invalid required parameter! Dense_Vector value \"dims\" must be between 1 and 2048.");
Assert.isTrue(dims >= 1 && dims <= 4096,
"Invalid required parameter! Dense_Vector value \"dims\" must be between 1 and 4096.");
}
enabled = true;
eagerGlobalOrdinals = field.eagerGlobalOrdinals();
@@ -70,7 +70,7 @@ public class Order extends Sort.Order {
public Order(Sort.Direction direction, String property, Sort.NullHandling nullHandlingHint, @Nullable Mode mode,
@Nullable String unmappedType) {
this(direction, property, nullHandlingHint, null, unmappedType, null);
this(direction, property, nullHandlingHint, mode, unmappedType, null);
}
public Order(Sort.Direction direction, String property, Sort.NullHandling nullHandlingHint, @Nullable Mode mode,
@@ -453,9 +453,7 @@ public class SimpleElasticsearchRepository<T, ID> implements ElasticsearchReposi
@Nullable
public <R> R executeAndRefresh(OperationsCallback<R> callback, @Nullable RefreshPolicy refreshPolicy) {
R result = callback.doWithOperations(operations.withRefreshPolicy(refreshPolicy));
doRefresh();
return result;
return callback.doWithOperations(operations.withRefreshPolicy(refreshPolicy));
}
// endregion
}
+4 -1
View File
@@ -1,4 +1,4 @@
Spring Data Elasticsearch 5.2.4 (2023.1.4)
Spring Data Elasticsearch 5.2.7 (2023.1.7)
Copyright (c) [2013-2022] Pivotal Software, Inc.
This product is licensed to you under the Apache License, Version 2.0 (the "License").
@@ -22,3 +22,6 @@ conditions of the subcomponent's license, as noted in the LICENSE file.
@@ -70,8 +70,8 @@ public class MappingParametersTest extends MappingContextBaseTests {
}
@Test // #1700
@DisplayName("should not allow dims length greater than 2048 for dense_vector type")
void shouldNotAllowDimsLengthGreaterThan2048ForDenseVectorType() {
@DisplayName("should not allow dims length greater than 4096 for dense_vector type")
void shouldNotAllowDimsLengthGreaterThan4096ForDenseVectorType() {
ElasticsearchPersistentEntity<?> failEntity = elasticsearchConverter.get().getMappingContext()
.getRequiredPersistentEntity(DenseVectorInvalidDimsClass.class);
Annotation annotation = failEntity.getRequiredPersistentProperty("dense_vector").findAnnotation(Field.class);
@@ -90,21 +90,28 @@ public class MappingParametersTest extends MappingContextBaseTests {
}
static class AnnotatedClass {
@Nullable @Field private String field;
@Nullable @MultiField(mainField = @Field,
@Nullable
@Field private String field;
@Nullable
@MultiField(mainField = @Field,
otherFields = { @InnerField(suffix = "test", type = FieldType.Text) }) private String mainField;
@Nullable @Field(type = FieldType.Text, docValues = false) private String docValuesText;
@Nullable @Field(type = FieldType.Nested, docValues = false) private String docValuesNested;
@Nullable @Field(type = Object, enabled = true) private String enabledObject;
@Nullable @Field(type = Object, enabled = false) private String disabledObject;
@Nullable
@Field(type = FieldType.Text, docValues = false) private String docValuesText;
@Nullable
@Field(type = FieldType.Nested, docValues = false) private String docValuesNested;
@Nullable
@Field(type = Object, enabled = true) private String enabledObject;
@Nullable
@Field(type = Object, enabled = false) private String disabledObject;
}
static class InvalidEnabledFieldClass {
@Nullable @Field(type = FieldType.Text, enabled = false) private String disabledObject;
@Nullable
@Field(type = FieldType.Text, enabled = false) private String disabledObject;
}
static class DenseVectorInvalidDimsClass {
@Field(type = Dense_Vector, dims = 2049) private float[] dense_vector;
@Field(type = Dense_Vector, dims = 4097) private float[] dense_vector;
}
static class DenseVectorMissingDimsClass {