mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-17 10:25:15 +00:00
Disable dynamic mapping in testSimpleGetFieldMappingsWithDefaults (#38045)
Since #31140 we no longer require acking on the dynamic mapping of index requests. Thus, a returned mapping from a get mapping request does not necessarily contain the dynamic updates from the index request. This commit replaces the dynamic mapping update with a manual put mapping. Relates #31140 Closes #37928
This commit is contained in:
parent
a8ebe2a217
commit
b8b843476d
@ -147,8 +147,7 @@ public class SimpleGetFieldMappingsIT extends ESIntegTestCase {
|
|||||||
@SuppressWarnings("unchecked")
|
@SuppressWarnings("unchecked")
|
||||||
public void testSimpleGetFieldMappingsWithDefaults() throws Exception {
|
public void testSimpleGetFieldMappingsWithDefaults() throws Exception {
|
||||||
assertAcked(prepareCreate("test").addMapping("type", getMappingForType("type")));
|
assertAcked(prepareCreate("test").addMapping("type", getMappingForType("type")));
|
||||||
|
client().admin().indices().preparePutMapping("test").setType("type").setSource("num", "type=long").get();
|
||||||
client().prepareIndex("test", "type", "1").setSource("num", 1).get();
|
|
||||||
|
|
||||||
GetFieldMappingsResponse response = client().admin().indices().prepareGetFieldMappings()
|
GetFieldMappingsResponse response = client().admin().indices().prepareGetFieldMappings()
|
||||||
.setFields("num", "field1", "obj.subfield").includeDefaults(true).get();
|
.setFields("num", "field1", "obj.subfield").includeDefaults(true).get();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user