mirror of
https://github.com/spring-projects/spring-data-elasticsearch.git
synced 2025-06-21 19:42:10 +00:00
Polishing
This commit is contained in:
parent
06de217ceb
commit
03992ba722
@ -5,6 +5,7 @@
|
||||
== New in Spring Data Elasticsearch 5.4
|
||||
|
||||
* Upgrade to Elasticsearch 8.14.3.
|
||||
* Allow to customize the mapped type name for @InnerField and @Field annotations.
|
||||
|
||||
[[new-features.5-3-0]]
|
||||
== New in Spring Data Elasticsearch 5.3
|
||||
|
@ -241,7 +241,7 @@ public @interface Field {
|
||||
* @since 5.1
|
||||
*/
|
||||
boolean storeEmptyValue() default true;
|
||||
|
||||
|
||||
/**
|
||||
* overrides the field type in the mapping which otherwise will be taken from corresponding {@link FieldType}
|
||||
*
|
||||
|
@ -172,7 +172,7 @@ public @interface InnerField {
|
||||
* @since 5.4
|
||||
*/
|
||||
KnnIndexOptions[] knnIndexOptions() default {};
|
||||
|
||||
|
||||
/**
|
||||
* overrides the field type in the mapping which otherwise will be taken from corresponding {@link FieldType}
|
||||
*
|
||||
|
@ -177,7 +177,8 @@ public class MappingBuilder {
|
||||
var dynamicMapping = docAnnotation != null ? docAnnotation.dynamic() : null;
|
||||
|
||||
final FieldType fieldType = FieldType.Auto;
|
||||
mapEntity(objectNode, entity, true, "", false, fieldType, fieldType.getMappedName(), null, dynamicMapping, runtimeFields);
|
||||
mapEntity(objectNode, entity, true, "", false, fieldType, fieldType.getMappedName(), null, dynamicMapping,
|
||||
runtimeFields);
|
||||
|
||||
if (!excludeFromSource.isEmpty()) {
|
||||
ObjectNode sourceNode = objectNode.putObject(SOURCE);
|
||||
@ -212,7 +213,8 @@ public class MappingBuilder {
|
||||
}
|
||||
|
||||
private void mapEntity(ObjectNode objectNode, @Nullable ElasticsearchPersistentEntity<?> entity,
|
||||
boolean isRootObject, String nestedObjectFieldName, boolean nestedOrObjectField, FieldType fieldType, String fieldTypeMappedName,
|
||||
boolean isRootObject, String nestedObjectFieldName, boolean nestedOrObjectField, FieldType fieldType,
|
||||
String fieldTypeMappedName,
|
||||
@Nullable Field parentFieldAnnotation, @Nullable Dynamic dynamicMapping, @Nullable Document runtimeFields)
|
||||
throws IOException {
|
||||
|
||||
@ -486,6 +488,7 @@ public class MappingBuilder {
|
||||
|
||||
/**
|
||||
* Return the mapping type name to be used for the {@link Field}
|
||||
*
|
||||
* @param field field to return the mapping type name for
|
||||
* @return the mapping type name
|
||||
*/
|
||||
|
Loading…
x
Reference in New Issue
Block a user