mirror of
https://github.com/elastic/elasticsearch.git
synced 2025-06-28 17:34:17 -04:00
DocumentMapper to not implement ToXContent (#68653)
DocumentMapper does not need to implement ToXContent, in fact it is its inner Mapping that needs to and already does. Consumers can switch to calling mapping() and toXContent against it.
This commit is contained in:
parent
8d975d2ae6
commit
0ca6819882
6 changed files with 13 additions and 22 deletions
|
@ -434,7 +434,7 @@ public class AnnotatedTextFieldMapperTests extends MapperTestCase {
|
|||
|
||||
XContentBuilder builder = XContentFactory.jsonBuilder();
|
||||
builder.startObject();
|
||||
mapper.toXContent(builder, new ToXContent.MapParams(Collections.singletonMap("include_defaults", "true")));
|
||||
mapper.mapping().toXContent(builder, new ToXContent.MapParams(Collections.singletonMap("include_defaults", "true")));
|
||||
builder.endObject();
|
||||
|
||||
String mappingString = Strings.toString(builder);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue