Skip to content

Commit

Permalink
Fix SearchWhileRelocatingIT so that the type of the mapping matches t…
Browse files Browse the repository at this point in the history
…he type of documents.
  • Loading branch information
jpountz committed Dec 15, 2015
1 parent a27c53f commit 5790335
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ protected void checkMappersCompatibility(String type, Collection<ObjectMapper> o

for (FieldMapper fieldMapper : fieldMappers) {
if (fullPathObjectMappers.containsKey(fieldMapper.name())) {
throw new IllegalArgumentException("Field [{}] is defined as a field in mapping [" + fieldMapper.name() + "] but this name is already used for an object in other types");
throw new IllegalArgumentException("Field [" + fieldMapper.name() + "] is defined as a field in mapping [" + type + "] but this name is already used for an object in other types");
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ private void testSearchAndRelocateConcurrently(final int numberOfReplicas) throw
final int numShards = between(1, 20);
client().admin().indices().prepareCreate("test")
.setSettings(settingsBuilder().put("index.number_of_shards", numShards).put("index.number_of_replicas", numberOfReplicas))
.addMapping("type1", "loc", "type=geo_point", "test", "type=string").execute().actionGet();
.addMapping("type", "loc", "type=geo_point", "test", "type=string").execute().actionGet();
ensureGreen();
List<IndexRequestBuilder> indexBuilders = new ArrayList<>();
final int numDocs = between(10, 20);
Expand Down

0 comments on commit 5790335

Please sign in to comment.